add file size toggle icons, ff_lut3d icon, fullscrn clk2play fix, timebar endpt curso...
[goodguy/history.git] / cinelerra-5.1 / cinelerra / preferencesthread.C
index 3e4ac56fb2617970d324142d6b7fe469ee65286c..bf921724d531bee53da724ae209c508aa9aae89b 100644 (file)
@@ -211,12 +211,24 @@ int PreferencesThread::apply_settings()
                (*this_aconfig != *aconfig) || (*this_vconfig != *vconfig) ||
                !preferences->brender_asset->equivalent(*mwindow->preferences->brender_asset, 0, 1, edl);
 
+       if( preferences->yuv_color_space != mwindow->preferences->yuv_color_space ||
+           preferences->yuv_color_range != mwindow->preferences->yuv_color_range ) {
+               YUV::yuv.yuv_set_colors(
+                       preferences->yuv_color_space,
+                       preferences->yuv_color_range);
+               rerender = 1;
+       }
+
        if( preferences->highlight_inverse != mwindow->preferences->highlight_inverse ) {
                mwindow->gui->lock_window("PreferencesThread::apply_settings 0");
                mwindow->gui->hide_cursor(0);
                mwindow->gui->unlock_window();
                redraw_overlays = 1;
        }
+       PreferencesWindow *window = (PreferencesWindow*)get_gui();
+       if( window ) window->unlock_window();
+       mwindow->init_brender();
+       if( window ) window->lock_window("PreferencesThread::apply_settings 5");
 
        if( strcmp(preferences->theme, mwindow->preferences->theme) != 0 )
                mwindow->restart_status = -1; // reload, need new bcresources
@@ -225,7 +237,6 @@ int PreferencesThread::apply_settings()
 
        mwindow->edl->copy_session(edl, 1);
        mwindow->preferences->copy_from(preferences);
-       mwindow->init_brender();
 
        BC_Signals::set_catch_segv(mwindow->preferences->trap_sigsegv);
        BC_Signals::set_catch_intr(mwindow->preferences->trap_sigintr);
@@ -240,7 +251,7 @@ int PreferencesThread::apply_settings()
        }
 
        mwindow->reset_android_remote();
-       int ffmpeg_early_probe = mwindow->preferences->get_file_probe_armed("FFPMEG_Early");
+       int ffmpeg_early_probe = mwindow->preferences->get_file_probe_armed("FFMPEG_Early");
        mwindow->gui->ffmpeg_toggle->update(ffmpeg_early_probe);
        mwindow->gui->ffmpeg_toggle->set_tooltip(ffmpeg_early_probe ?
                FFMPEG_EARLY_TIP : FFMPEG_LATE_TIP);
@@ -317,10 +328,7 @@ int PreferencesThread::apply_settings()
 //printf("PreferencesThread::apply_settings 1\n");
 // This doesn't stop and restart, only reloads the assets before
 // the next play command.
-               mwindow->cwindow->playback_engine->que->send_command(CURRENT_FRAME,
-                       CHANGE_ALL,
-                       mwindow->edl,
-                       1);
+               mwindow->cwindow->refresh_frame(CHANGE_ALL, mwindow->edl);
 //printf("PreferencesThread::apply_settings 10\n");
        }