From d1c0b1246b02c5232b059f6f753585b3e0c011e7 Mon Sep 17 00:00:00 2001 From: Good Guy Date: Tue, 26 Dec 2017 19:35:12 -0700 Subject: [PATCH] youtube formats, make race conditions, capture colormodel for ffmpeg --- cinelerra-5.1/cinelerra/fileffmpeg.C | 1 + cinelerra-5.1/ffmpeg/audio/stereo_with_h264.youtube | 4 ++++ cinelerra-5.1/ffmpeg/video/hd_h264.youtube | 8 ++++++++ cinelerra-5.1/ffmpeg/video/sd_h264.youtube | 8 ++++++++ cinelerra-5.1/ffmpeg/video/uhd_h264.youtube | 8 ++++++++ cinelerra-5.1/plugins/Makefile | 2 +- cinelerra-5.1/plugins/freeverb/Makefile | 2 +- 7 files changed, 31 insertions(+), 2 deletions(-) create mode 100644 cinelerra-5.1/ffmpeg/audio/stereo_with_h264.youtube create mode 100644 cinelerra-5.1/ffmpeg/video/hd_h264.youtube create mode 100644 cinelerra-5.1/ffmpeg/video/sd_h264.youtube create mode 100644 cinelerra-5.1/ffmpeg/video/uhd_h264.youtube diff --git a/cinelerra-5.1/cinelerra/fileffmpeg.C b/cinelerra-5.1/cinelerra/fileffmpeg.C index 82a810d6..1faa7567 100644 --- a/cinelerra-5.1/cinelerra/fileffmpeg.C +++ b/cinelerra-5.1/cinelerra/fileffmpeg.C @@ -354,6 +354,7 @@ int FileFFMPEG::get_best_colormodel(Asset *asset, int driver) { switch(driver) { // the direct X11 color model requires scaling in the codec + case SCREENCAPTURE: case PLAYBACK_X11: case PLAYBACK_X11_GL: return BC_RGB888; case PLAYBACK_X11_XV: return BC_YUV420P; diff --git a/cinelerra-5.1/ffmpeg/audio/stereo_with_h264.youtube b/cinelerra-5.1/ffmpeg/audio/stereo_with_h264.youtube new file mode 100644 index 00000000..d084baf5 --- /dev/null +++ b/cinelerra-5.1/ffmpeg/audio/stereo_with_h264.youtube @@ -0,0 +1,4 @@ +mp4 libfdk_aac +# Recommended sample rates: 48000Hz or 96000Hz +# Stereo is 384k; change to 128k for mono, 512k for 5.1 +b=384k diff --git a/cinelerra-5.1/ffmpeg/video/hd_h264.youtube b/cinelerra-5.1/ffmpeg/video/hd_h264.youtube new file mode 100644 index 00000000..612d9c4c --- /dev/null +++ b/cinelerra-5.1/ffmpeg/video/hd_h264.youtube @@ -0,0 +1,8 @@ +mp4 libx264 +# YOUTUBE High Definition; for resolution of 1920x1080; +# 24/25/30 fps. Change audio to: stereo_with_h264. +b=10000k +profile=high +# use framerate for 1 keyframe/sec, needed for seeks +keyint_min=24 +x264opts keyint=24 diff --git a/cinelerra-5.1/ffmpeg/video/sd_h264.youtube b/cinelerra-5.1/ffmpeg/video/sd_h264.youtube new file mode 100644 index 00000000..007eb43d --- /dev/null +++ b/cinelerra-5.1/ffmpeg/video/sd_h264.youtube @@ -0,0 +1,8 @@ +mp4 libx264 +# YOUTUBE Standard Definition; for resolution of 640×480; +# 24/25/30 fps. Change audio to: stereo_with_h264. +b=2500k +profile=high +# use framerate for 1 keyframe/sec, needed for seeks +keyint_min=24 +x264opts keyint=24 diff --git a/cinelerra-5.1/ffmpeg/video/uhd_h264.youtube b/cinelerra-5.1/ffmpeg/video/uhd_h264.youtube new file mode 100644 index 00000000..5d83b5f7 --- /dev/null +++ b/cinelerra-5.1/ffmpeg/video/uhd_h264.youtube @@ -0,0 +1,8 @@ +mp4 libx264 +# YOUTUBE Ultra High Definition; for resolution 3840x2160; +# 50 or 60 fps. Change audio to: stereo_with_h264. +b=80000k +profile=high +# use framerate for 1 keyframe/sec, needed for seeks +keyint_min=24 +x264opts keyint=24 diff --git a/cinelerra-5.1/plugins/Makefile b/cinelerra-5.1/plugins/Makefile index a492ca86..07abd5f1 100644 --- a/cinelerra-5.1/plugins/Makefile +++ b/cinelerra-5.1/plugins/Makefile @@ -181,7 +181,7 @@ $(LADSPA_DIR): # parallel compilation of all directories .PHONY: $(DIRS) -$(DIRS): +$(DIRS): $(PLUGIN_DIR) $(MAKE) -C $@ clean: diff --git a/cinelerra-5.1/plugins/freeverb/Makefile b/cinelerra-5.1/plugins/freeverb/Makefile index 054a07cf..df988215 100644 --- a/cinelerra-5.1/plugins/freeverb/Makefile +++ b/cinelerra-5.1/plugins/freeverb/Makefile @@ -16,7 +16,7 @@ include ../../plugin_config $(FREEVERBOBJS): $(CC) -c `cat $(OBJDIR)/c_flags` $(subst $(OBJDIR)/,, $*.cpp) -o $*.o -$(OUTPUT): $(DIRS) +$(FREEVERBOBJS): $(DIRS) $(OUTPUT): $(FREEVERBOBJS) $(DIRS): -- 2.26.2