diff options
author | James Monteath <james@blender.org> | 2021-06-01 16:07:46 +0300 |
---|---|---|
committer | Jeroen Bakker <jeroen@blender.org> | 2021-06-01 16:18:11 +0300 |
commit | 8a63466ca3380479a92a65b670a074277d9a8671 (patch) | |
tree | ce89d6a394431a36770de9bb4421a41962862194 /source/blender/sequencer/intern/strip_add.c | |
parent | ee54a8ace753a56236f5d1d647da7a40904af6b3 (diff) | |
parent | 6899dcab5339d1f17dd2ea665a38e4ab28ab23fc (diff) |
BuildBot: Cleanup
Removing scripts that were placed in the source tree that would drive
the old buildbot. With the new buildbot in place these scripts aren't
being used anymore.
The buildbit is currently driven by
`build_files/config/pipeline_config.json`. In the near future make
update would also use this config.
Overview of the new buildbot: https://wiki.blender.org/wiki/Infrastructure/BuildBot
Work done by James Monteath.
Diffstat (limited to 'source/blender/sequencer/intern/strip_add.c')
-rw-r--r-- | source/blender/sequencer/intern/strip_add.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/source/blender/sequencer/intern/strip_add.c b/source/blender/sequencer/intern/strip_add.c index 5ec2269b993..64671aeb265 100644 --- a/source/blender/sequencer/intern/strip_add.c +++ b/source/blender/sequencer/intern/strip_add.c @@ -548,15 +548,25 @@ Sequence *SEQ_add_movie_strip(Main *bmain, Scene *scene, ListBase *seqbase, SeqL seq->blend_mode = SEQ_TYPE_CROSS; /* so alpha adjustment fade to the strip below */ + float video_fps = 0.0f; + if (anim_arr[0] != NULL) { seq->anim_preseek = IMB_anim_get_preseek(anim_arr[0]); seq->len = IMB_anim_get_duration(anim_arr[0], IMB_TC_RECORD_RUN); IMB_anim_load_metadata(anim_arr[0]); + short fps_denom; + float fps_num; + + IMB_anim_get_fps(anim_arr[0], &fps_denom, &fps_num, true); + + video_fps = fps_denom / fps_num; + /* Adjust scene's frame rate settings to match. */ if (load_data->flags & SEQ_LOAD_MOVIE_SYNC_FPS) { - IMB_anim_get_fps(anim_arr[0], &scene->r.frs_sec, &scene->r.frs_sec_base, true); + scene->r.frs_sec = fps_denom; + scene->r.frs_sec_base = fps_num; } /* Set initial scale based on load_data->fit_method. */ @@ -577,6 +587,7 @@ Sequence *SEQ_add_movie_strip(Main *bmain, Scene *scene, ListBase *seqbase, SeqL strip->stripdata = se = MEM_callocN(sizeof(StripElem), "stripelem"); strip->stripdata->orig_width = orig_width; strip->stripdata->orig_height = orig_height; + strip->stripdata->orig_fps = video_fps; BLI_split_dirfile(load_data->path, strip->dir, se->name, sizeof(strip->dir), sizeof(se->name)); seq_add_set_view_transform(scene, seq, load_data); |