Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/source
diff options
context:
space:
mode:
authorRichard Antalik <richardantalik@gmail.com>2022-01-25 19:05:33 +0300
committerRichard Antalik <richardantalik@gmail.com>2022-01-25 19:07:11 +0300
commiteab066cbf2da1fdb8162d9ed814a9491f9acf02d (patch)
tree67e38132c4bd19410bfea1442ecfd576aeb88d64 /source
parent2ed73fc97e7f9b0a0c9783933177b4c566acf6a0 (diff)
VSE: Use timecodes by default
Movies with variable frame rate can cause mismatch of displayed frame when proxies are used. Since proxies are not used for rendering, this means, that output may be different than expected. This problem can be avoided when timecodes are used. Set used timecode to Record Run. Timecodes are built with proxies at the same time, therefore if proxies are built and used this will resolve possible mismatch of output. Record run is chosen, because it will show frames based on time they were encoded by encoder and should match behavior as if movie was played back at normal speed. This change is done only for new strips in order to not overwrite user defined settings. Other minor changes: - When proxies are enabled, size 25% is no longer set by default. It was mostly annoying anyway. - Silence warning when timecode file is not present. This was introduced in 4adbe31e2fc98f982aed3d97505513750ec348d4. Previously use of timecodes was hard-coded in sequencer and this error would spam console if timecodes would be enabled by default and proxies would be never built. ref: T95093 Reviewed By: sergey Differential Revision: https://developer.blender.org/D13905
Diffstat (limited to 'source')
-rw-r--r--source/blender/imbuf/intern/indexer.c1
-rw-r--r--source/blender/sequencer/intern/proxy.c5
-rw-r--r--source/blender/sequencer/intern/sequencer.c9
-rw-r--r--source/blender/sequencer/intern/sequencer.h3
4 files changed, 12 insertions, 6 deletions
diff --git a/source/blender/imbuf/intern/indexer.c b/source/blender/imbuf/intern/indexer.c
index 6cd87e29c9d..7aeee2740c0 100644
--- a/source/blender/imbuf/intern/indexer.c
+++ b/source/blender/imbuf/intern/indexer.c
@@ -170,7 +170,6 @@ struct anim_index *IMB_indexer_open(const char *name)
int i;
if (!fp) {
- fprintf(stderr, "Couldn't open indexer file: %s\n", name);
return NULL;
}
diff --git a/source/blender/sequencer/intern/proxy.c b/source/blender/sequencer/intern/proxy.c
index 2cb2ba13fb5..cc0ea0634a3 100644
--- a/source/blender/sequencer/intern/proxy.c
+++ b/source/blender/sequencer/intern/proxy.c
@@ -601,10 +601,7 @@ void SEQ_proxy_set(struct Sequence *seq, bool value)
if (value) {
seq->flag |= SEQ_USE_PROXY;
if (seq->strip->proxy == NULL) {
- seq->strip->proxy = MEM_callocN(sizeof(struct StripProxy), "StripProxy");
- seq->strip->proxy->quality = 50;
- seq->strip->proxy->build_tc_flags = SEQ_PROXY_TC_ALL;
- seq->strip->proxy->build_size_flags = SEQ_PROXY_IMAGE_SIZE_25;
+ seq->strip->proxy = seq_strip_proxy_alloc();
}
}
else {
diff --git a/source/blender/sequencer/intern/sequencer.c b/source/blender/sequencer/intern/sequencer.c
index f0a45355143..1c7fe927381 100644
--- a/source/blender/sequencer/intern/sequencer.c
+++ b/source/blender/sequencer/intern/sequencer.c
@@ -66,6 +66,15 @@
/** \name Allocate / Free Functions
* \{ */
+StripProxy *seq_strip_proxy_alloc(void)
+{
+ StripProxy *strip_proxy = MEM_callocN(sizeof(struct StripProxy), "StripProxy");
+ strip_proxy->quality = 50;
+ strip_proxy->build_tc_flags = SEQ_PROXY_TC_ALL;
+ strip_proxy->tc = SEQ_PROXY_TC_RECORD_RUN;
+ return strip_proxy;
+}
+
static Strip *seq_strip_alloc(int type)
{
Strip *strip = MEM_callocN(sizeof(Strip), "strip");
diff --git a/source/blender/sequencer/intern/sequencer.h b/source/blender/sequencer/intern/sequencer.h
index 7d7ecbc8178..2a82f966f02 100644
--- a/source/blender/sequencer/intern/sequencer.h
+++ b/source/blender/sequencer/intern/sequencer.h
@@ -29,12 +29,13 @@ extern "C" {
struct Scene;
struct Sequence;
-
+struct StripProxy;
/**
* Cache must be freed before calling this function
* since it leaves the seqbase in an invalid state.
*/
void seq_free_sequence_recurse(struct Scene *scene, struct Sequence *seq, bool do_id_user);
+struct StripProxy *seq_strip_proxy_alloc(void);
#ifdef __cplusplus
}