Blender V5.3
strip_time.cc
Go to the documentation of this file.
1/* SPDX-FileCopyrightText: 2001-2002 NaN Holding BV. All rights reserved.
2 * SPDX-FileCopyrightText: 2003-2009 Blender Authors
3 * SPDX-FileCopyrightText: 2005-2006 Peter Schlaile <peter [at] schlaile [dot] de>
4 *
5 * SPDX-License-Identifier: GPL-2.0-or-later */
6
10
11#include <algorithm>
12
13#include "DNA_scene_types.h"
14#include "DNA_sequence_types.h"
15
16#include "BLI_listbase.hh"
17#include "BLI_math_base_c.hh"
18
19#include "BKE_movieclip.hh"
20#include "BKE_sound.hh"
21
22#include "DNA_sound_types.h"
23
24#include "MOV_read.hh"
25
26#include "SEQ_animation.hh"
27#include "SEQ_channels.hh"
28#include "SEQ_effects.hh"
29#include "SEQ_iterator.hh"
30#include "SEQ_render.hh"
31#include "SEQ_retiming.hh"
32#include "SEQ_sequencer.hh"
33#include "SEQ_time.hh"
34#include "SEQ_transform.hh"
35
37#include "sequencer.hh"
38#include "strip_time.hh"
39
40namespace blender {
41namespace seq {
42
43float give_frame_index(const Scene *scene, const Strip *strip, float timeline_frame)
44{
45 float frame_index;
46 float sta = strip->content_start();
47 float end = strip->is_effect() ? strip->right_handle(scene) : strip->content_end(scene) - 1;
48
49 if (end < sta) {
50 return -1;
51 }
52
53 if (strip->type == STRIP_TYPE_IMAGE && transform_single_image_check(strip)) {
54 return 0;
55 }
56
57 if (strip->flag & SEQ_REVERSE_FRAMES) {
58 frame_index = end - timeline_frame;
59 }
60 else {
61 frame_index = timeline_frame - sta;
62 }
63
64 frame_index = max_ff(frame_index, 0);
65
66 const float scene_fps = float(scene->r.frs_sec) / float(scene->r.frs_sec_base);
67 frame_index *= strip->media_playback_rate_factor(scene_fps);
68
69 if (retiming_has_keys(strip)) {
70 const float retiming_factor = strip_retiming_evaluate(strip, frame_index);
71 /* Retiming maps frame index from 0 up to `strip->len`, because key is positioned at the end of
72 * last frame. Otherwise the last frame could not be retimed. */
73 frame_index = retiming_factor * strip->content_length();
74 }
75 /* Clamp frame index to strip content frame range. */
76 float frame_index_max = strip->is_effect() ? end - sta : strip->content_length() - 1;
77 frame_index = clamp_f(frame_index, 0, frame_index_max);
78
79 if (strip->strobe > 1.0f) {
80 frame_index -= fmodf(double(frame_index), double(strip->strobe));
81 }
82
83 return frame_index;
84}
85
86static int metastrip_start_get(Strip *strip_meta)
87{
88 return strip_meta->start + strip_meta->startofs;
89}
90
91static int metastrip_end_get(Strip *strip_meta)
92{
93 return strip_meta->start + strip_meta->content_length() - strip_meta->end_offset();
94}
95
97 Strip *strip_meta,
98 int start,
99 int end)
100{
101 /* For sound we go over full meta tree to update bounds of the sound strips,
102 * since sound is played outside of evaluating the image-buffers (#ImBuf). */
103 for (Strip &strip : strip_meta->seqbase) {
104 if (strip.type == STRIP_TYPE_META) {
106 &strip,
107 max_ii(start, metastrip_start_get(&strip)),
108 min_ii(end, metastrip_end_get(&strip)));
109 }
110 else if (ELEM(strip.type, STRIP_TYPE_SOUND, STRIP_TYPE_SCENE)) {
111 if (strip.runtime->scene_sound) {
112 int startofs = strip.startofs;
113 int endofs = strip.end_offset();
114 if (strip.startofs + strip.start < start) {
115 startofs = start - strip.start;
116 }
117
118 if (strip.start + strip.content_length() - strip.end_offset() > end) {
119 endofs = strip.start + strip.content_length() - end;
120 }
121
122 double offset_time = 0.0f;
123 if (strip.sound != nullptr) {
124 offset_time = strip.sound->offset_time + strip.sound_offset;
125 }
126
128 strip.runtime->scene_sound,
129 strip.start + startofs,
130 strip.start + strip.content_length() - endofs,
131 startofs + strip.anim_startofs,
132 offset_time);
133 }
134 }
135 }
136}
137
138void strip_update_sound_bounds_recursive(const Scene *scene, Strip *strip_meta)
139{
141 scene, strip_meta, metastrip_start_get(strip_meta), metastrip_end_get(strip_meta));
142}
143
144void time_update_meta_strip_range(const Scene *scene, Strip *strip_meta)
145{
146 if (strip_meta == nullptr) {
147 return;
148 }
149
150 if (strip_meta->seqbase.is_empty()) {
151 return;
152 }
153
154 const int strip_start = strip_meta->left_handle();
155 const int strip_end = strip_meta->right_handle(scene);
156
157 int min = MAXFRAME * 2;
158 int max = -MAXFRAME * 2;
159 for (Strip &strip : strip_meta->seqbase) {
160 min = min_ii(strip.left_handle(), min);
161 max = max_ii(strip.right_handle(scene), max);
162 }
163
164 strip_meta->start = min + strip_meta->anim_startofs;
165 strip_meta->content_length_set(max - strip_meta->anim_endofs - strip_meta->start);
166
167 /* Functions `SEQ_time_*_handle_frame_set()` can not be used here, because they are clamped, so
168 * change must be done at once. */
169 strip_meta->startofs = strip_start - strip_meta->start;
170 strip_meta->startdisp = strip_start; /* Only to make files usable in older versions. */
171 strip_meta->end_offset_set(strip_meta->start + strip_meta->length(scene) - strip_end);
172 strip_meta->enddisp = strip_end; /* Only to make files usable in older versions. */
173
174 strip_update_sound_bounds_recursive(scene, strip_meta);
175 Span<Strip *> effects = lookup_effects_by_strip(scene->ed, strip_meta);
177 time_update_meta_strip_range(scene, lookup_meta_by_strip(scene->ed, strip_meta));
178}
179
181 const Strip *input1,
182 const Strip *input2)
183{
184 const int first_start = input1->left_handle();
185 const int second_start = input2->left_handle();
186 return (first_start > second_start) ||
187 (first_start == second_start &&
188 input1->right_handle(scene) > input2->right_handle(scene));
189}
190
191void strip_time_effect_range_set(const Scene *scene, Strip *strip)
192{
193 if (strip->input1 == nullptr && strip->input2 == nullptr) {
194 return;
195 }
196
197 if (strip->input1 && strip->input2) { /* 2 - input effect. */
198 strip->startdisp = max_ii(strip->input1->left_handle(), strip->input2->left_handle());
199 strip->enddisp = min_ii(strip->input1->right_handle(scene),
200 strip->input2->right_handle(scene));
201
202 /* Sort by timeline frame so 2-input transitions go "from" earlier "to" later. */
203 if (effect_is_transition(strip->type) &&
204 transition_inputs_have_wrong_order(scene, strip->input1, strip->input2))
205 {
206 std::swap(strip->input1, strip->input2);
207 }
208 }
209 else if (strip->input1) { /* Single input effect. */
210 strip->startdisp = strip->input1->right_handle(scene);
211 strip->enddisp = strip->input1->left_handle();
212 }
213 else if (strip->input2) { /* Strip may be missing one of inputs. */
214 strip->startdisp = strip->input2->right_handle(scene);
215 strip->enddisp = strip->input2->left_handle();
216 }
217
218 if (strip->startdisp > strip->enddisp) {
219 std::swap(strip->startdisp, strip->enddisp);
220 }
221
222 /* Values unusable for effects, these should be always 0. */
223 strip->startofs = strip->anim_startofs = strip->anim_endofs = 0;
224 strip->end_offset_set(0);
225 strip->start = strip->startdisp;
226 strip->content_length_set(strip->enddisp - strip->startdisp);
227}
228
230{
231 /* First pass: Update length of immediate effects. */
232 for (Strip *strip : effects) {
233 strip_time_effect_range_set(scene, strip);
234 }
235
236 /* Second pass: Recursive call to update effects in chain and in order, so they inherit length
237 * correctly. */
238 for (Strip *strip : effects) {
239 Span<Strip *> effects_recurse = lookup_effects_by_strip(scene->ed, strip);
240 strip_time_update_effects_strip_range(scene, effects_recurse);
241 }
242}
243
245 int timeline_frame,
246 const Side side,
247 const bool do_skip_mute,
248 const bool do_center,
249 const bool do_unselected)
250{
251 Editing *ed = editing_get(scene);
252 ListBaseT<SeqTimelineChannel> *channels = channels_displayed_get(ed);
253
254 int dist, best_dist, best_frame = timeline_frame;
255 int strip_frames[2], strip_frames_tot;
256
257 /* In case where both is passed,
258 * frame just finds the nearest end while frame_left the nearest start. */
259
260 best_dist = MAXFRAME * 2;
261
262 if (ed == nullptr) {
263 return timeline_frame;
264 }
265
266 for (Strip &strip : *ed->current_strips()) {
267 int i;
268
269 if (do_skip_mute && render_is_muted(channels, &strip)) {
270 continue;
271 }
272
273 if (do_unselected && (strip.flag & SEQ_SELECT)) {
274 continue;
275 }
276
277 if (do_center) {
278 strip_frames[0] = (strip.left_handle() + strip.right_handle(scene)) / 2;
279 strip_frames_tot = 1;
280 }
281 else {
282 strip_frames[0] = strip.left_handle();
283 strip_frames[1] = strip.right_handle(scene);
284
285 strip_frames_tot = 2;
286 }
287
288 for (i = 0; i < strip_frames_tot; i++) {
289 const int strip_frame = strip_frames[i];
290
291 dist = MAXFRAME * 2;
292
293 switch (side) {
294 case Side::Left:
295 if (strip_frame < timeline_frame) {
296 dist = timeline_frame - strip_frame;
297 }
298 break;
299 case Side::Right:
300 if (strip_frame > timeline_frame) {
301 dist = strip_frame - timeline_frame;
302 }
303 break;
304 case Side::Both:
305 dist = abs(strip_frame - timeline_frame);
306 break;
307 default:
308 break;
309 }
310
311 if (dist < best_dist) {
312 best_frame = strip_frame;
313 best_dist = dist;
314 }
315 }
316 }
317
318 return best_frame;
319}
320
321void timeline_init_boundbox(const Scene *scene, rctf *r_rect)
322{
323 r_rect->xmin = scene->r.sfra;
324 r_rect->xmax = scene->r.efra + 1;
325 r_rect->ymin = 1.0f; /* The first strip is drawn at y == 1.0f */
326 r_rect->ymax = 8.0f;
327}
328
329void timeline_expand_boundbox(const Scene *scene, const ListBaseT<Strip> *seqbase, rctf *rect)
330{
331 if (seqbase == nullptr) {
332 return;
333 }
334
335 for (Strip &strip : *seqbase) {
336 rect->xmin = std::min<float>(rect->xmin, strip.left_handle() - 1);
337 rect->xmax = std::max<float>(rect->xmax, strip.right_handle(scene) + 1);
338 /* We do +1 here to account for the channel thickness. Channel n has range of <n, n+1>. */
339 rect->ymax = std::max(rect->ymax, strip.channel + 1.0f);
340 }
341}
342
343void timeline_boundbox(const Scene *scene, const ListBaseT<Strip> *seqbase, rctf *r_rect)
344{
345 timeline_init_boundbox(scene, r_rect);
346 timeline_expand_boundbox(scene, seqbase, r_rect);
347}
348
349static bool strip_exists_at_frame(const Scene *scene,
350 Span<Strip *> strips,
351 const int timeline_frame)
352{
353 for (Strip *strip : strips) {
354 if (strip->intersects_frame(scene, timeline_frame)) {
355 return true;
356 }
357 }
358 return false;
359}
360
361void seq_time_gap_info_get(const Scene *scene,
362 ListBaseT<Strip> *seqbase,
363 const int initial_frame,
364 GapInfo *r_gap_info)
365{
366 rctf rectf;
367 /* Get first and last frame. */
368 timeline_boundbox(scene, seqbase, &rectf);
369 const int sfra = int(rectf.xmin);
370 const int efra = int(rectf.xmax);
371 int timeline_frame = initial_frame;
372 r_gap_info->gap_exists = false;
373
374 VectorSet strips = query_all_strips(seqbase);
375
376 if (!strip_exists_at_frame(scene, strips, initial_frame)) {
377 /* Search backward for gap_start_frame. */
378 for (; timeline_frame >= sfra; timeline_frame--) {
379 if (strip_exists_at_frame(scene, strips, timeline_frame)) {
380 break;
381 }
382 }
383 r_gap_info->gap_start_frame = timeline_frame + 1;
384 timeline_frame = initial_frame;
385 }
386 else {
387 /* Search forward for gap_start_frame. */
388 for (; timeline_frame <= efra; timeline_frame++) {
389 if (!strip_exists_at_frame(scene, strips, timeline_frame)) {
390 r_gap_info->gap_start_frame = timeline_frame;
391 break;
392 }
393 }
394 }
395 /* Search forward for gap_end_frame. */
396 for (; timeline_frame <= efra; timeline_frame++) {
397 if (strip_exists_at_frame(scene, strips, timeline_frame)) {
398 const int gap_end_frame = timeline_frame;
399 r_gap_info->gap_length = gap_end_frame - r_gap_info->gap_start_frame;
400 r_gap_info->gap_exists = true;
401 break;
402 }
403 }
404}
405
406static void strip_time_slip_strip_ex(const Scene *scene,
407 Strip *strip,
408 int delta,
409 float subframe_delta,
410 bool slip_keyframes,
411 bool recursed)
412{
413 if (strip->type == STRIP_TYPE_SOUND && subframe_delta != 0.0f) {
414 strip->sound_offset += subframe_delta / scene->frames_per_second();
415 }
416
417 if (delta == 0 && (!slip_keyframes || subframe_delta == 0.0f)) {
418 return;
419 }
420
421 /* Skip effect strips where the length is dependent on another strip,
422 * as they are calculated with #strip_time_update_effects_strip_range. */
423 if (strip->input1 != nullptr || strip->input2 != nullptr) {
424 return;
425 }
426
427 /* Effects only have a start frame and a length, so unless we're inside
428 * a meta strip, there's no need to do anything. */
429 if (!recursed && strip->is_effect()) {
430 return;
431 }
432
433 /* Move strips inside meta strip. */
434 if (strip->type == STRIP_TYPE_META) {
435 /* If the meta strip has no contents, don't do anything. */
436 if (strip->seqbase.is_empty()) {
437 return;
438 }
439
440 for (Strip &strip_child : strip->seqbase) {
441 /* The keyframes of strips inside meta strips should always be moved. */
442 strip_time_slip_strip_ex(scene, &strip_child, delta, subframe_delta, true, true);
443 }
444 }
445
446 strip->start = strip->start + delta;
447
448 if (slip_keyframes) {
449 float anim_offset = delta;
450 if (strip->type == STRIP_TYPE_SOUND) {
451 anim_offset += subframe_delta;
452 }
453 offset_animdata(scene, strip, anim_offset);
454 }
455
456 if (!recursed) {
457 strip->startofs = strip->startofs - delta;
458 strip->end_offset_set(strip->end_offset() + delta);
459 }
460
461 /* Only to make files usable in older versions. */
462 strip->startdisp = strip->left_handle();
463 strip->enddisp = strip->right_handle(scene);
464
465 Span<Strip *> effects = lookup_effects_by_strip(scene->ed, strip);
467}
468
470 const Scene *scene, Strip *strip, int frame_delta, float subframe_delta, bool slip_keyframes)
471{
472 strip_time_slip_strip_ex(scene, strip, frame_delta, subframe_delta, slip_keyframes, false);
473}
474
475} // namespace seq
476
477float Strip::media_playback_rate_factor(float scene_fps) const
478{
479 if ((this->flag & SEQ_AUTO_PLAYBACK_RATE) == 0) {
480 return 1.0f;
481 }
482 if (this->media_playback_rate == 0.0f) {
483 return 1.0f;
484 }
485 return this->media_playback_rate / scene_fps;
486}
487
488float Strip::media_fps(Scene *scene)
489{
490 switch (this->type) {
491 case STRIP_TYPE_MOVIE: {
492 seq::MovieReaderAccessor reader = seq::movie_reader_cache_acquire_any(*scene, *this);
493 if (!reader) {
494 return 0.0f;
495 }
496 return MOV_get_fps(reader.reader());
497 }
499 if (this->clip != nullptr) {
500 return BKE_movieclip_get_fps(this->clip);
501 }
502 break;
503 case STRIP_TYPE_SCENE:
504 if (this->scene != nullptr) {
505 return float(this->scene->r.frs_sec) / this->scene->r.frs_sec_base;
506 }
507 break;
508 default:
509 break;
510 }
511 return 0.0f;
512}
513
514float Strip::content_start() const
515{
516 return this->start;
517}
518
519void Strip::content_start_set(const Scene *scene, int timeline_frame)
520{
521 this->start = timeline_frame;
522 Span<Strip *> effects = seq::lookup_effects_by_strip(scene->ed, this);
525}
526
527float Strip::content_end(const Scene *scene) const
528{
529 return this->content_start() + this->length(scene);
530}
531
532int Strip::length(const Scene *scene) const
533{
534 const float scene_fps = float(scene->r.frs_sec) / float(scene->r.frs_sec_base);
535 if (seq::retiming_has_keys(this)) {
536 const int last_key_frame = seq::retiming_key_frame_get(
537 scene, this, seq::retiming_last_key_get(this));
538 /* Last key is mapped to last frame index. Numbering starts from 0. */
539 const int sound_offset = this->rounded_sound_offset(scene_fps);
540 return last_key_frame - this->content_start() - sound_offset;
541 }
542
543 return this->content_length() / this->media_playback_rate_factor(scene_fps);
544}
545
546int Strip::rounded_sound_offset(float scene_fps) const
547{
548 if (this->type == STRIP_TYPE_SOUND && this->sound != nullptr) {
549 return round_fl_to_int((this->sound->offset_time + this->sound_offset) * scene_fps);
550 }
551 return 0;
552}
553
554int Strip::left_handle() const
555{
556 if (this->input1 || this->input2) {
557 return this->startdisp;
558 }
559
560 return this->start + this->startofs;
561}
562
563int Strip::right_handle(const Scene *scene) const
564{
565 if (this->input1 || this->input2) {
566 return this->enddisp;
567 }
568
569 return this->content_end(scene) - this->end_offset();
570}
571
572void Strip::left_handle_set(const Scene *scene, int timeline_frame)
573{
574 const float right_handle_orig_frame = this->right_handle(scene);
575
576 if (timeline_frame >= right_handle_orig_frame) {
577 timeline_frame = right_handle_orig_frame - 1;
578 }
579
580 float offset = timeline_frame - this->content_start();
581
583 /* This strip has only 1 frame of content that is always stretched to the whole strip length.
584 * Move strip start left and adjust end offset to be negative (rightwards past the 1 frame). */
585 this->content_start_set(scene, timeline_frame);
586 this->end_offset_set(this->end_offset() + offset);
587 }
588 else {
589 this->startofs = offset;
590 }
591
592 this->startdisp = timeline_frame; /* Only to make files usable in older versions. */
593
594 Span<Strip *> effects = seq::lookup_effects_by_strip(scene->ed, this);
597}
598
599void Strip::right_handle_set(const Scene *scene, int timeline_frame)
600{
601 const float left_handle_orig_frame = this->left_handle();
602
603 if (timeline_frame <= left_handle_orig_frame) {
604 timeline_frame = left_handle_orig_frame + 1;
605 }
606
607 this->end_offset_set(this->content_end(scene) - timeline_frame);
608 this->enddisp = timeline_frame; /* Only to make files usable in older versions. */
609
610 Span<Strip *> effects = seq::lookup_effects_by_strip(scene->ed, this);
613}
614
615void Strip::handles_set(const Scene *scene, int left_frame, int right_frame)
616{
617 BLI_assert(left_frame < right_frame);
618
619 if (left_frame >= this->right_handle(scene)) {
620 /* Move right handle first to avoid clamping. */
621 this->right_handle_set(scene, right_frame);
622 this->left_handle_set(scene, left_frame);
623 }
624 else {
625 this->left_handle_set(scene, left_frame);
626 this->right_handle_set(scene, right_frame);
627 }
628}
629
630void Strip::channel_set(int channel)
631{
632 this->channel = math::clamp(channel, 1, seq::MAX_CHANNELS);
633}
634
635bool Strip::intersects_frame(const Scene *scene, const int timeline_frame) const
636{
637 return (this->left_handle() <= timeline_frame) && (this->right_handle(scene) > timeline_frame);
638}
639
640int Strip::content_length() const
641{
642 if (this->scene && this->type == STRIP_TYPE_SCENE) {
643 float new_length = this->scene->r.efra - this->scene->r.sfra + 1 - this->anim_startofs -
644 this->anim_endofs;
645 return max_ff(new_length, 0);
646 }
647 return this->len;
648}
649
650float Strip::end_offset() const
651{
652 if (this->type == STRIP_TYPE_SCENE) {
653 return this->content_length() - (this->len - this->endofs);
654 }
655 return this->endofs;
656}
657
658void Strip::content_length_set(int new_length)
659{
660 this->len = new_length;
661}
662
663void Strip::end_offset_set(float new_end_offset)
664{
665 if (this->type == STRIP_TYPE_SCENE) {
666 this->len = this->content_length();
667 }
668 this->endofs = new_end_offset;
669}
670
671} // namespace blender
#define MAXFRAME
#define BLI_assert(a)
#define ELEM(...)
btScalar max
SIMD_FORCE_INLINE btScalar length() const
Return the length of the vector.
Definition btVector3.h:257
#define fmodf(x, y)
#define abs
ccl_device_inline dual1 len(const ccl_private dual< T > &a)
Definition math_dual.h:263
T clamp(const T &a, const T &min, const T &max)
Strip * lookup_meta_by_strip(Editing *ed, const Strip *key)
int time_find_next_prev_edit(Scene *scene, int timeline_frame, const Side side, const bool do_skip_mute, const bool do_center, const bool do_unselected)
void seq_time_gap_info_get(const Scene *scene, ListBaseT< Strip > *seqbase, const int initial_frame, GapInfo *r_gap_info)
static int metastrip_end_get(Strip *strip_meta)
Definition strip_time.cc:91
float give_frame_index(const Scene *scene, const Strip *strip, float timeline_frame)
Definition strip_time.cc:43
bool render_is_muted(const ListBaseT< SeqTimelineChannel > *channels, const Strip *strip)
Definition render.cc:2241
Editing * editing_get(const Scene *scene)
Definition sequencer.cc:304
MovieReaderAccessor movie_reader_cache_acquire_any(const Scene &scene, const Strip &strip)
void timeline_boundbox(const Scene *scene, const ListBaseT< Strip > *seqbase, rctf *r_rect)
bool effect_is_transition(StripType type)
Definition effects.cc:381
int retiming_key_frame_get(const Scene *scene, const Strip *strip, const SeqRetimingKey *key)
void offset_animdata(const Scene *scene, Strip *strip, float ofs)
Definition animation.cc:42
VectorSet< Strip * > query_all_strips(ListBaseT< Strip > *seqbase)
Definition iterator.cc:155
static bool transition_inputs_have_wrong_order(const Scene *scene, const Strip *input1, const Strip *input2)
bool transform_single_image_check(const Strip *strip)
void strip_time_update_effects_strip_range(const Scene *scene, const Span< Strip * > effects)
constexpr int MAX_CHANNELS
void time_update_meta_strip_range(const Scene *scene, Strip *strip_meta)
void time_slip_strip(const Scene *scene, Strip *strip, int frame_delta, float subframe_delta, bool slip_keyframes)
Span< Strip * > lookup_effects_by_strip(Editing *ed, const Strip *key)
bool retiming_has_keys(const Strip *strip)
void strip_update_sound_bounds_recursive(const Scene *scene, Strip *strip_meta)
static void strip_time_slip_strip_ex(const Scene *scene, Strip *strip, int delta, float subframe_delta, bool slip_keyframes, bool recursed)
void timeline_init_boundbox(const Scene *scene, rctf *r_rect)
void timeline_expand_boundbox(const Scene *scene, const ListBaseT< Strip > *seqbase, rctf *rect)
static void strip_update_sound_bounds_recursive_impl(const Scene *scene, Strip *strip_meta, int start, int end)
Definition strip_time.cc:96
static int metastrip_start_get(Strip *strip_meta)
Definition strip_time.cc:86
static bool strip_exists_at_frame(const Scene *scene, Span< Strip * > strips, const int timeline_frame)
ListBaseT< SeqTimelineChannel > * channels_displayed_get(const Editing *ed)
Definition channels.cc:26
SeqRetimingKey * retiming_last_key_get(const Strip *strip)
float strip_retiming_evaluate(const Strip *strip, const float frame_index)
void strip_time_effect_range_set(const Scene *scene, Strip *strip)
BMesh Iterators.
MINLINE int round_fl_to_int(float a)
void BKE_sound_move_scene_sound(const Scene *scene, AUD_SequenceEntry handle, int startframe, int endframe, int frameskip, double audio_offset)
MINLINE int max_ii(int a, int b)
float BKE_movieclip_get_fps(MovieClip *clip)
MINLINE float max_ff(float a, float b)
float MOV_get_fps(const MovieReader *anim)
MINLINE int min_ii(int a, int b)
MINLINE float clamp_f(float value, float min, float max)
KERNEL_FEATURE_LIGHT_PASSES KERNEL_FEATURE_PATH_GUIDING float
#define min(a, b)
Definition sort.cc:38
struct Editing * ed
struct RenderData r