forked from bartvdbraak/blender
Cleanup "Sync Mode" (i.e. Av Sync/Framedropping) stuff
* Remove the "sync_mode" dropdown from timeline header, and move it into the Playback menu instead. * Remove the confusing "Frame Dropping" and "AV Sync" entries from the Playback menu. These were supposed to be mutually exclusive (or else, the "sync_mode" menu would break). * Turn AV Sync on by default * Commented out the Frame Dropping and Av Sync RNA Properties too. THere doesn't seem to be any valid reason for these to exist?
This commit is contained in:
parent
8c49e6f99e
commit
20185a8681
@ -77,8 +77,6 @@ class TIME_HT_editor_buttons(Header):
|
||||
row.operator("screen.keyframe_jump", text="", icon='NEXT_KEYFRAME').next = True
|
||||
row.operator("screen.frame_jump", text="", icon='FF').end = True
|
||||
|
||||
layout.prop(scene, "sync_mode", text="")
|
||||
|
||||
layout.separator()
|
||||
|
||||
row = layout.row(align=True)
|
||||
@ -218,10 +216,9 @@ class TIME_MT_playback(Menu):
|
||||
layout.prop(screen, "use_follow")
|
||||
layout.separator()
|
||||
|
||||
layout.prop(scene, "use_frame_drop", text="Frame Dropping")
|
||||
layout.prop(scene, "use_audio_sync", text="AV-sync", icon='SPEAKER')
|
||||
layout.prop(scene, "use_audio")
|
||||
layout.prop(scene, "use_audio_scrub")
|
||||
layout.prop_menu_enum(scene, "sync_mode")
|
||||
|
||||
|
||||
class TIME_MT_autokey(Menu):
|
||||
|
@ -717,6 +717,7 @@ void BKE_scene_init(Scene *sce)
|
||||
sce->audio.doppler_factor = 1.0f;
|
||||
sce->audio.speed_of_sound = 343.3f;
|
||||
sce->audio.volume = 1.0f;
|
||||
sce->audio.flag = AUDIO_SYNC;
|
||||
|
||||
BLI_strncpy(sce->r.pic, U.renderdir, sizeof(sce->r.pic));
|
||||
|
||||
|
@ -210,6 +210,11 @@ void BLO_update_defaults_startup_blend(Main *bmain)
|
||||
}
|
||||
|
||||
scene->r.ffcodecdata.audio_mixrate = 48000;
|
||||
|
||||
/* set av sync by default */
|
||||
printf("setting new default audio\n");
|
||||
scene->audio.flag |= AUDIO_SYNC;
|
||||
scene->flag &= ~SCE_FRAME_DROP;
|
||||
}
|
||||
|
||||
for (FreestyleLineStyle *linestyle = bmain->linestyle.first; linestyle; linestyle = linestyle->id.next) {
|
||||
|
@ -5864,14 +5864,17 @@ void RNA_def_scene(BlenderRNA *brna)
|
||||
RNA_def_property_update(prop, NC_SPACE | ND_SPACE_GRAPH, NULL);
|
||||
|
||||
/* Frame dropping flag for playback and sync enum */
|
||||
#if 0 /* XXX: Is this actually needed? */
|
||||
prop = RNA_def_property(srna, "use_frame_drop", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "flag", SCE_FRAME_DROP);
|
||||
RNA_def_property_ui_text(prop, "Frame Dropping", "Play back dropping frames if frame display is too slow");
|
||||
RNA_def_property_update(prop, NC_SCENE, NULL);
|
||||
#endif
|
||||
|
||||
prop = RNA_def_property(srna, "sync_mode", PROP_ENUM, PROP_NONE);
|
||||
RNA_def_property_enum_funcs(prop, "rna_Scene_sync_mode_get", "rna_Scene_sync_mode_set", NULL);
|
||||
RNA_def_property_enum_items(prop, sync_mode_items);
|
||||
RNA_def_property_enum_default(prop, AUDIO_SYNC);
|
||||
RNA_def_property_ui_text(prop, "Sync Mode", "How to sync playback");
|
||||
RNA_def_property_update(prop, NC_SCENE, NULL);
|
||||
|
||||
@ -6007,11 +6010,13 @@ void RNA_def_scene(BlenderRNA *brna)
|
||||
RNA_def_property_ui_text(prop, "Audio Muted", "Play back of audio from Sequence Editor will be muted");
|
||||
RNA_def_property_update(prop, NC_SCENE, NULL);
|
||||
|
||||
#if 0 /* XXX: Is this actually needed? */
|
||||
prop = RNA_def_property(srna, "use_audio_sync", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "audio.flag", AUDIO_SYNC);
|
||||
RNA_def_property_ui_text(prop, "Audio Sync",
|
||||
"Play back and sync with audio clock, dropping frames if frame display is too slow");
|
||||
RNA_def_property_update(prop, NC_SCENE, NULL);
|
||||
#endif
|
||||
|
||||
prop = RNA_def_property(srna, "use_audio_scrub", PROP_BOOLEAN, PROP_NONE);
|
||||
RNA_def_property_boolean_sdna(prop, NULL, "audio.flag", AUDIO_SCRUB);
|
||||
|
Loading…
Reference in New Issue
Block a user