Projects
Multimedia
ffx264
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 124
View file
ffx264.changes
Changed
@@ -1,4 +1,15 @@ ------------------------------------------------------------------- +Wed Oct 23 03:15:00 UTC 2019 - neutrino8@opensuse.org + +- Update to version 3.9.6 + * Added support for setting the VBV maxrate and buffer size + * Set default audio codec based on output container format + * Add colr option for MP4Box to the video_colorspace_func() + function and the color primaries code. Only used for MOV + * Add -color_primaries, -color_trc and -colorspace to the + FFmpeg command line options + +------------------------------------------------------------------- Tue Oct 22 04:20:00 UTC 2019 - neutrino8@opensuse.org - Update to version 3.9.5
View file
ffx264.spec
Changed
@@ -17,9 +17,9 @@ Name: ffx264 -Version: 3.9.5 +Version: 3.9.6 Release: 0 -Summary: A small shell script for encoding to H.264 with ffmpeg +Summary: A small shell script for encoding to H.264/AVC with FFmpeg License: GPL-2.0+ Group: Productivity/Multimedia/Video/Editors and Convertors Url: https://ffx264.teambelgium.net @@ -27,13 +27,13 @@ Requires: ffmpeg Requires: bc Requires: MPlayer -Requires: gpac +Requires: gpac >= 0.8.0 BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildArch: noarch %description A small shell script for encoding video files to the H.264/AVC video format -using ffmpeg and libx264. +using FFmpeg and libx264. %prep %setup -q
View file
ffx264-3.9.5.tar.gz/ChangeLog -> ffx264-3.9.6.tar.gz/ChangeLog
Changed
@@ -1,3 +1,11 @@ +2019-10-23 - ffx264 3.9.6 + * Added support for setting the VBV maxrate and buffer size + * Set default audio codec based on output container format + * Add colr option for MP4Box to the video_colorspace_func() + function and the color primaries code. Only used for MOV + * Add -color_primaries, -color_trc and -colorspace to the + FFmpeg command line options + 2019-10-22 - ffx264 3.9.5 * Add support for SRT/SSA/AAS subtitles for the MOV container * Add color characteristics to MP4Box if output is MOV
View file
ffx264-3.9.5.tar.gz/ffx264 -> ffx264-3.9.6.tar.gz/ffx264
Changed
@@ -2,8 +2,8 @@ # # Small script to encode to H.264/AVC video using FFmpeg and libx264. # Author: Grozdan "microchip" Nikolov <neutrino8@opensuse.org> -# Version: 3.9.5 -# Date: 2019-10-22 +# Version: 3.9.6 +# Date: 2019-10-23 # # ffx264 is free software ; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -24,7 +24,7 @@ brown() { echo -e "\e[0;33m$1\e[0;39;49m"; } error() { echo -e "\e[1;31m$1\e[0;39;49m"; } -version="3.9.5" +version="3.9.6" CFG="$HOME/.ffx264" cfgversion="40" @@ -718,6 +718,17 @@ ;; esac +printf "Set the VBV Maxrate/Buffer Size? [y/N]: " +read vbv +if [ "$vbv" = "y" -o "$vbv" = "Y" ]; then + printf "Specify the VBV Maxrate in kbps [press 'Enter' to skip]: " + read vbv_max + test ! -z "$vbv_max" && vbv_maxrate=":vbv_maxrate=$vbv_max" + printf "Specify the VBV Buffer Size in kbps [press 'Enter' to skip]: " + read vbv_buf + test ! -z "$vbv_buf" && vbv_bufsize=":vbv_bufsize=$vbv_buf" +fi + video_denoise_func() { printf "Denoise the Input File? [y/N]: " read dn @@ -1181,21 +1192,38 @@ printf "Is the Input 10- or 12-bits? [10/12 - default is 10]: " read indepth case "$indepth" in - 10|"") ztrans="bt2020-10" ;; - 12) ztrans="bt2020-12" ;; + 10|"") ztrans="bt2020-10"; trc="bt2020_10bit"; tc="14" ;; + 12) ztrans="bt2020-12"; trc="bt2020_12bit"; tc="15" ;; *) error "-> Unsupported value!" exit 1 ;; esac + printf "Use SMPTE-2084 Transfer? [y/N]: " + read smpte2084 + if [ "$smpte2084" = "y" -o "$smpte2084" = "Y" ]; then + trc="smpte2084" + ztrans="smpte2084" + tc="16" + fi zscale="zscale=transfer=$ztrans" colorprim=":transfer=$ztrans:colorprim=${VCHARS[4]}:colormatrix=${VCHARS[2]}" + coloroptions="-color_primaries ${VCHARS[4]} -color_trc $trc -colorspace ${VCHARS[2]}" colcopy="1" + case "${VCHARS[4]}" in + bt709) colchar="1,1,1" ;; + bt470bg) colchar="5,5,5" ;; + smpte170m) colchar="6,6,6" ;; + bt470m) colchar="4,4,6" ;; + bt2020) colchar="9,$tc,9" ;; + *) colchar="2,2,2" ;; + esac + colr=":colr=nclc,$colchar" fi ;; - 1) zscale="zscale=transfer=bt709"; colorspace="colormatrix=bt2020:bt709,colorspace=all=bt709:dither=fsb"; colorprim=":transfer=bt709:colorprim=bt709:colormatrix=bt709" ;; - 2) zscale="zscale=transfer=bt470bg"; colorspace="colormatrix=bt2020:bt470bg,colorspace=all=bt470bg:dither=fsb"; colorprim=":transfer=bt470bg:colorprim=bt470bg:colormatrix=bt470bg" ;; - 3) zscale="zscale=transfer=smpte170m"; colorspace="colormatrix=bt2020:smpte170m,colorspace=all=smpte170m:dither=fsb"; colorprim=":transfer=smpte170m:colorprim=smpte170m:colormatrix=smpte170m" ;; + 1) zscale="zscale=transfer=bt709"; colorspace="colormatrix=bt2020:bt709,colorspace=all=bt709:dither=fsb"; colorprim=":transfer=bt709:colorprim=bt709:colormatrix=bt709"; coloroptions="-color_primaries bt709 -color_trc bt709 -colorspace bt709"; colr=":colr=nclc,1,1,1" ;; + 2) zscale="zscale=transfer=bt470bg"; colorspace="colormatrix=bt2020:bt470bg,colorspace=all=bt470bg:dither=fsb"; colorprim=":transfer=bt470bg:colorprim=bt470bg:colormatrix=bt470bg"; coloroptions="-color_primaries bt470bg -color_trc gamma28 -colorspace bt470bg"; colr=":colr=nclc,5,5,5" ;; + 3) zscale="zscale=transfer=smpte170m"; colorspace="colormatrix=bt2020:smpte170m,colorspace=all=smpte170m:dither=fsb"; colorprim=":transfer=smpte170m:colorprim=smpte170m:colormatrix=smpte170m"; coloroptions="-color_primaries smpte170m -color_trc smpte170m -colorspace smpte170m"; colr=":colr=nclc,6,6,6" ;; *) error "-> Invalid option!" exit 1 @@ -1246,8 +1274,8 @@ printf "Use 10- or 12-bits BT2020 Transfer? [default is 10]: " read bdepth case "$bdepth" in - 10|"") bd="-10" ;; - 12) bd="-12" ;; + 10|"") bd="-10"; bd2="_10bit"; trsr="14" ;; + 12) bd="-12"; bd2="_12bit"; trsr="15" ;; *) error "-> Invalid value!" exit 1 @@ -1256,8 +1284,8 @@ printf "Use Constant or Non-Constant Matrix? [c/n - default is n]: " read mtype case "$mtype" in - n|N|"") cm="nc" ;; - c|C) cm="c" ;; + n|N|"") cm="nc"; cmatrix="9" ;; + c|C) cm="c"; cmatrix="10" ;; *) error "-> Invalid value!" exit 1 @@ -1298,90 +1326,130 @@ 1) cspace="iall=bt470m:ispace=bt470m:itrc=bt470m:iprimaries=bt470m:irange=$irange:all=smpte170m:space=smpte170m:trc=smpte170m:primaries=smpte170m:range=$orange:dither=fsb" colorprim=":colormatrix=smpte170m:colorprim=smpte170m:transfer=smpte170m" + coloroptions="-color_primaries smpte170m -color_trc smpte170m -colorspace smpte170m" + colr=":colr=nclc,6,6,6" ;; 2) cspace="iall=bt470m:ispace=bt470m:itrc=bt470m:iprimaries=bt470m:irange=$irange:all=bt470bg:space=bt470bg:trc=bt470bg:primaries=bt470bg:range=$orange:dither=fsb" colorprim=":colormatrix=bt470bg:colorprim=bt470bg:transfer=bt470bg" + coloroptions="-color_primaries bt470bg -color_trc gamma28 -colorspace bt470bg" + colr=":colr=nclc,5,5,5" ;; 3) cspace="iall=bt470m:ispace=bt470m:itrc=bt470m:iprimaries=bt470m:irange=$irange:all=bt709:space=bt709:trc=bt709:primaries=bt709:range=$orange:dither=fsb" colorprim=":colormatrix=bt709:colorprim=bt709:transfer=bt709" + coloroptions="-color_primaries bt709 -color_trc bt709 -colorspace bt709" + colr=":colr=nclc,1,1,1" ;; 4) video_csmisc_func cspace="iall=bt470m:ispace=bt470m:itrc=bt470m:iprimaries=bt470m:irange=$irange:all=bt2020:space=bt2020ncl:trc=bt2020$bd:primaries=bt2020:range=$orange:dither=fsb" colorprim=":colormatrix=bt2020$cm:colorprim=bt2020:transfer=bt2020$bd" + coloroptions="-color_primaries bt2020 -color_trc bt2020$bd2 -colorspace bt2020$cm" + colr=":colr=nclc,9,$trsr,$cmatrix" ;; 5) cspace="iall=smpte170m:ispace=smpte170m:itrc=smpte170m:iprimaries=smpte170m:irange=$irange:all=bt470m:space=bt470m:trc=bt470m:primaries=bt470m:range=$orange:dither=fsb" colorprim=":colormatrix=smpte170m:colorprim=bt470m:transfer=bt470m" + coloroptions="-color_primaries bt470m -color_trc gamma22 -colorspace smpte170m" + colr=":colr=nclc,4,4,6" ;; 6) cspace="iall=smpte170m:ispace=smpte170m:itrc=smpte170m:iprimaries=smpte170m:irange=$irange:all=bt470bg:space=bt470bg:trc=bt470bg:primaries=bt470bg:range=$orange:dither=fsb" colorprim=":colormatrix=bt470bg:colorprim=bt470bg:transfer=bt470bg" + coloroptions="-color_primaries bt470bg -color_trc gamma28 -colorspace bt470bg" + colr=":colr=nclc,5,5,5" ;; 7) cspace="iall=smpte170m:ispace=smpte170m:itrc=smpte170m:iprimaries=smpte170m:irange=$irange:all=bt709:space=bt709:trc=bt709:primaries=bt709:range=$orange:dither=fsb" colorprim=":colormatrix=bt709:colorprim=bt709:transfer=bt709" + coloroptions="-color_primaries bt709 -color_trc bt709 -colorspace bt709" + colr=":colr=nclc,1,1,1" ;; 8) video_csmisc_func cspace="iall=smpte170m:ispace=smpte170m:itrc=smpte170m:iprimaries=smpte170m:irange=$irange:all=bt2020:space=bt2020ncl:trc=bt2020$bd:primaries=bt2020:range=$orange:dither=fsb" colorprim=":colormatrix=bt2020$cm:colorprim=bt2020:transfer=bt2020$bd" + coloroptions="-color_primaries bt2020 -color_trc bt2020$bd2 -colorspace bt2020$cm" + colr=":colr=nclc,9,$trsr,$cmatrix" ;; 9) cspace="iall=bt470bg:ispace=bt470bg:itrc=bt470bg:iprimaries=bt470bg:irange=$irange:all=bt470m:space=bt470m:trc=bt470m:primaries=bt470m:range=$orange:dither=fsb" colorprim=":colormatrix=smpte170m:colorprim=bt470m:transfer=bt470m" + coloroptions="-color_primaries bt470m -color_trc gamma22 -colorspace smpte170m" + colr=":colr=nclc,4,4,6" ;; 10) cspace="iall=bt470bg:ispace=bt470bg:itrc=bt470bg:iprimaries=bt470bg:irange=$irange:all=smpte170m:space=smpte170m:trc=smpte170m:primaries=smpte170m:range=$orange:dither=fsb" colorprim=":colormatrix=smpte170m:colorprim=smpte170m:transfer=smpte170m" + coloroptions="-color_primaries smpte170m -color_trc smpte170m -colorspace smpte170m" + colr=":colr=nclc,6,6,6" ;; 11) cspace="iall=bt470bg:ispace=bt470bg:itrc=bt470bg:iprimaries=bt470bg:irange=$irange:all=bt709:space=bt709:trc=bt709:primaries=bt709:range=$orange:dither=fsb" colorprim=":colormatrix=bt709:colorprim=bt709:transfer=bt709" + coloroptions="-color_primaries bt709 -color_trc bt709 -colorspace bt709" + colr=":colr=nclc,1,1,1" ;; 12) video_csmisc_func cspace="iall=bt470bg:ispace=bt470bg:itrc=bt470bg:iprimaries=bt470bg:irange=$irange:all=bt2020:space=bt2020ncl:trc=bt2020$bd:primaries=bt2020:range=$orange:dither=fsb" colorprim=":colormatrix=bt2020$cm:colorprim=bt2020:transfer=bt2020$bd" + coloroptions="-color_primaries bt2020 -color_trc bt2020$bd2 -colorspace bt2020$cm" + colr=":colr=nclc,9,$trsr,$cmatrix" ;; 13) cspace="iall=bt709:ispace=bt709:itrc=bt709:iprimaries=bt709:irange=$irange:all=bt470m:space=bt470m:trc=bt470m:primaries=bt470m:range=$orange:dither=fsb" colorprim=":colormatrix=smpte170m:colorprim=bt470m:transfer=bt470m" + coloroptions="-color_primaries bt470m -color_trc gamma22 -colorspace smpte170m" + colr=":colr=nclc,4,4,6" ;; 14) cspace="iall=bt709:ispace=bt709:itrc=bt709:iprimaries=bt709:irange=$irange:all=smpte170m:space=smpte170m:trc=smpte170m:primaries=smpte170m:range=$orange:dither=fsb" colorprim=":colormatrix=smpte170m:colorprim=smpte170m:transfer=smpte170m" + coloroptions="-color_primaries smpte170m -color_trc smpte170m -colorspace smpte170m" + colr=":colr=nclc,6,6,6" ;; 15) cspace="iall=bt709:ispace=bt709:itrc=bt709:iprimaries=bt709:irange=$irange:all=bt470bg:space=bt470bg:trc=bt470bg:primaries=bt470bg:range=$orange:dither=fsb" colorprim=":colormatrix=bt470bg:colorprim=bt470bg:transfer=bt470bg" + coloroptions="-color_primaries bt470bg -color_trc gamma28 -colorspace bt470bg" + colr=":colr=nclc,5,5,5" ;; 16) video_csmisc_func cspace="iall=bt709:ispace=bt709:itrc=bt709:iprimaries=bt709:irange=$irange:all=bt2020:space=bt2020ncl:trc=bt2020$bd:primaries=bt2020:range=$orange:dither=fsb" colorprim=":colormatrix=bt2020$cm:colorprim=bt2020:transfer=bt2020$bd" + coloroptions="-color_primaries bt2020 -color_trc bt2020$bd2 -colorspace bt2020$cm" + colr=":colr=nclc,9,$trsr,$cmatrix" ;; 17) video_csmisc_func cspace="iall=bt2020:ispace=bt2020ncl:itrc=bt2020$bd:iprimaries=bt2020:irange=$irange:all=bt470m:space=bt470m:trc=bt470m:primaries=bt470m:range=$orange:dither=fsb" colorprim=":colormatrix=smpte170m:colorprim=bt470m:transfer=bt470m" + coloroptions="-color_primaries bt470m -color_trc gamma22 -colorspace smpte170m" + colr=":colr=nclc,4,4,6" ;; 18) video_csmisc_func cspace="iall=bt2020:ispace=bt2020ncl:itrc=bt2020$bd:iprimaries=bt2020:irange=$irange:all=smpte170m:space=smpte170m:trc=smpte170m:primaries=smpte170m:range=$orange:dither=fsb" colorprim=":colormatrix=smpte170m:colorprim=smpte170m:transfer=smpte170m" + coloroptions="-color_primaries smpte170m -color_trc smpte170m -colorspace smpte170m" + colr=":colr=nclc,6,6,6" ;; 19) video_csmisc_func cspace="iall=bt2020:ispace=bt2020ncl:itrc=bt2020$bd:iprimaries=bt2020:irange=$irange:all=bt470bg:space=bt470bg:trc=bt470bg:primaries=bt470bg:range=$orange:dither=fsb" colorprim=":colormatrix=bt470bg:colorprim=bt470bg:transfer=bt470bg" + coloroptions="-color_primaries bt470bg -color_trc gamma28 -colorspace bt470bg" + colr=":colr=nclc,5,5,5" ;; 20) video_csmisc_func cspace="iall=bt2020:ispace=bt2020ncl:itrc=bt2020$bd:iprimaries=bt2020:irange=$irange:all=bt709:space=bt709:trc=bt709:primaries=bt709:range=$orange:dither=fsb" colorprim=":colormatrix=bt709:colorprim=bt709:transfer=bt709" + coloroptions="-color_primaries bt709 -color_trc bt709 -colorspace bt709" + colr=":colr=nclc,1,1,1" ;; "") true ;; *) @@ -1679,14 +1747,14 @@ printf "Specify the Color Primaries [default is 8]: " read cpopt case "$cpopt" in - 0) matrix="smpte170m"; prim="bt470m"; transfer="bt470m" ;; - 1) matrix="smpte170m"; prim="smpte170m"; transfer="smpte170m" ;; - 2) matrix="bt470bg"; prim="bt470bg"; transfer="bt470bg" ;; - 3) matrix="bt709"; prim="bt709"; transfer="bt709" ;; - 4) matrix="bt2020nc"; prim="bt2020"; transfer="bt2020-10" ;; - 5) matrix="bt2020nc"; prim="bt2020"; transfer="bt2020-12" ;; - 6) matrix="bt2020c"; prim="bt2020"; transfer="bt2020-10" ;; - 7) matrix="bt2020c"; prim="bt2020"; transfer="bt2020-12" ;; + 0) matrix="smpte170m"; prim="bt470m"; transfer="bt470m"; coloroptions="-color_primaries bt470m -color_trc gamma22 -colorspace smpte170m" ;; + 1) matrix="smpte170m"; prim="smpte170m"; transfer="smpte170m"; coloroptions="-color_primaries smpte170m -color_trc smpte170m -colorspace smpte170m" ;; + 2) matrix="bt470bg"; prim="bt470bg"; transfer="bt470bg"; coloroptions="-color_primaries bt470bg -color_trc gamma28 -colorspace bt470bg" ;; + 3) matrix="bt709"; prim="bt709"; transfer="bt709"; coloroptions="-color_primaries bt709 -color_trc bt709 -colorspace bt709" ;; + 4) matrix="bt2020nc"; prim="bt2020"; transfer="bt2020-10"; coloroptions="-color_primaries bt2020 -color_trc bt2020_10bit -colorspace bt2020nc" ;; + 5) matrix="bt2020nc"; prim="bt2020"; transfer="bt2020-12"; coloroptions="-color_primaries bt2020 -color_trc bt2020_12bit -colorspace bt2020nc" ;; + 6) matrix="bt2020c"; prim="bt2020"; transfer="bt2020-10"; coloroptions="-color_primaries bt2020 -color_trc bt2020_10bit -colorspace bt2020c" ;; + 7) matrix="bt2020c"; prim="bt2020"; transfer="bt2020-12"; coloroptions="-color_primaries bt2020 -color_trc bt2020_12bit -colorspace bt2020c" ;; 8|"") matrix="undef"; prim="undef"; transfer="undef" ;; *) error "-> Invalid option!" @@ -1699,16 +1767,33 @@ read smpte if [ "$smpte" = "y" -o "$smpte" = "Y" ]; then transfer="smpte2084" + trans="16" + coloroptions="$(echo "$coloroptions" | sed "s|bt2020_.*|$transfer|")" + else + case "$cpopt" in + 4|6) trans="14" ;; + 5|7) trans="15" ;; + esac fi ;; esac colorprim=":colormatrix=$matrix:colorprim=$prim:transfer=$transfer" # For MP4Box mov output + # + # 1st value: color primary + # 2nd value: transfer + # 3rd value: matrix + # See: ISO/IEC 23001-8 paper case "$cpopt" in - 0|1|2) colr=":colr=nclc,2,2,2" ;; + 0) colr=":colr=nclc,4,4,6" ;; + 1) colr=":colr=nclc,6,6,6" ;; + 2) colr=":colr=nclc,5,5,5" ;; 3) colr=":colr=nclc,1,1,1" ;; - [4-7) colr=":colr=nclc,3,3,3" ;; - *) true ;; + 4) colr=":colr=nclc,9,$trans,9" ;; + 5) colr=":colr=nclc,9,$trans,9" ;; + 6) colr=":colr=nclc,9,$trans,10" ;; + 7) colr=":colr=nclc,9,$trans,10" ;; + *) colr=":colr=nclc,2,2,2" ;; esac fi fi @@ -2321,14 +2406,21 @@ auddispo[i]="-disposition:a:${audindex[i]} $adispo" if [ -z "$DEFAULT_AUD_CODEC" ]; then - printf "Track $i: Specify the Audio Codec [default is AC3]: " + case "${OUTPUT##*.}" in + mp4|m4v|mov) defacodec[i]="AAC" ;; + avi|flv) defacodec[i]="MP3" ;; + wmv) defacodec[i]="WMAv2" ;; + *) defacodec[i]="AC3" ;; + esac + printf "Track $i: Specify the Audio Codec [default is ${defacodec[i]}]: " read acodec[i] else acodec[i]="$DEFAULT_AUD_CODEC" fi + test -z "${acodec[i]}" && acodec[i]="${defacodec[i]}" acodec[i]="$(echo "${acodec[i]}" | tr '[:upper:]' '[:lower:]')" case "${acodec[i]}" in - ac3|"") + ac3) acdc[i]="ac3" ameta[i]="AC-3" abropts[i]="192/384/448/640" @@ -2484,7 +2576,7 @@ ;; flv) case "${acodec[i]}" in - ac3|eac3|dts|vorbis|flac|libopus|opus|truehd|alac|wmav1|wmav2|"") conerror_func ;; + ac3|eac3|dts|vorbis|flac|libopus|opus|truehd|alac|wmav1|wmav2) conerror_func ;; esac ;; esac @@ -2541,7 +2633,7 @@ esac case "${acodec[i]}" in - ac3|eac3|"") chanrange[i]="1-6"; defchan[i]="6" ;; + ac3|eac3) chanrange[i]="1-6"; defchan[i]="6" ;; aac|libopus|vorbis|flac|alac|pcm) chanrange[i]="1-8"; defchan[i]="8" ;; mp3|opus|wmav1|wmav2) chanrange[i]="1-2"; defchan[i]="2" ;; truehd) chanrange[i]="2/5/6"; defchan[i]="6" ;; @@ -2558,7 +2650,7 @@ read achan[i] test -z "${achan[i]}" && ach[i]="${defchan[i]}" || ach[i]="${achan[i]}" case "${acodec[i]}" in - ac3|eac3|"") + ac3|eac3) case "${ach[i]}" in [1-6]) true ;; *) @@ -2637,7 +2729,7 @@ brown " Audio Channel Layouts" brown " ~~~~~~~~~~~~~~~~~~~~~" case "${acodec[i]}" in - ac3|eac3|"") + ac3|eac3) echo " 0 -> Mono 4 -> Quad 8 --> 5.0" echo " 1 -> Stereo 5 -> Quad(side) 9 --> 5.0(side)" echo " 2 -> 3.0 6 -> 4.0 10 -> 5.1" @@ -2910,7 +3002,7 @@ esac case "${acodec[i]}" in - ac3|eac3|"") + ac3|eac3) printf "Track $i: Specify the Dialog Level Normalization in dB [-31 to -1 - default is -31]: " read adn[i] test -z "${adn[i]}" && auddialnorm[i]="-dialnorm:a:${audindex[i]} -31" || auddialnorm[i]="-dialnorm:a:${audindex[i]} ${adn[i]}" @@ -2967,7 +3059,7 @@ ;; esac ;; - ac3|eac3|"") + ac3|eac3) echo " 0 -> 32000 Hz" echo " 1 -> 44100 Hz" echo " 2 -> 48000 Hz" @@ -3358,12 +3450,12 @@ test ! -z "$vidfilters" && vfilters="-vf $vidfilters" -test ! -z "$vpreset" && X264PARAMS=":force-cfr=1:threads=auto$colorprim$interlaced$min_keyint$max_keyint$chromaloc $vpreset $vtune" || X264PARAMS=":$X264PARAMS$colorprim$interlaced$min_keyint$max_keyint$chromaloc" +test ! -z "$vpreset" && X264PARAMS=":force-cfr=1:threads=auto$colorprim$interlaced$min_keyint$max_keyint$chromaloc$vbv_maxrate$vbv_bufsize $vpreset $vtune" || X264PARAMS=":$X264PARAMS$colorprim$interlaced$min_keyint$max_keyint$chromaloc$vbv_maxrate$vbv_bufsize" test ! -z "$COMMENT" && METACOMMENT="-metadata comment=\"$COMMENT\"" encoder_func() { - VIDOPTS="${EXTSUBS[*]} $vidmap -disposition:v:0 default $aspect $ofps $annexb $METADATA $CHAPS $METATITLE $METAGENRE $METAYEAR $METACOMMENT $vfilters" + VIDOPTS="${EXTSUBS[*]} $vidmap -disposition:v:0 default $aspect $ofps $annexb $METADATA $CHAPS $METATITLE $METAGENRE $METAYEAR $METACOMMENT $vfilters $coloroptions" case "$1" in 1p|crf) test "$encmode" = "1p" && passone="bitrate=$vbitrate" || passone="crf=$CRF" @@ -3430,9 +3522,9 @@ case "$CONFMT" in mp4|m4v|mov) if [ ! -z "$MP4COVER" ]; then - if [ "$CONFMT" = "mov" ]; then - color="$colr" - fi + case "$CONFMT" in + mov) color="$colr" ;; + esac echo "echo" >> "$OUTFILE" echo "green \"-> Adding cover image...\"" >> "$OUTFILE" echo "$MP4BOX -add \"$OUTPUT\"$color -itags cover=\"$(readlink -e "$cover")\":name=\"$(basename "${OUTPUT%.*}")\":genre=\"$genre\":created=\"$year\":comment=\"$COMMENT\" -mpeg4 -new \"${OUTPUT%.*}_COVER_$$.$CONFMT\" >/dev/null 2>&1" >> "$OUTFILE" @@ -3476,7 +3568,7 @@ ;; esac fi - echo "$FFMPEG $vflags1 -i \"$OUTPUT\" -map 0 -c:v copy -c:a copy $suboption $vflags2 $strict $MKVCOVER2 $CHAPS $METATITLE $METAGENRE $METAYEAR $METACOMMENT ${audmeta[*]} ${audlang[*]} ${sublang[*]} ${sublng[*]} \"${OUTPUT%.*}.$i\" >/dev/null 2>&1" >> "$OUTFILE" + echo "$FFMPEG $vflags1 -i \"$OUTPUT\" -map 0 -c:v copy -c:a copy $suboption $vflags2 $coloroptions $strict $MKVCOVER2 $CHAPS $METATITLE $METAGENRE $METAYEAR $METACOMMENT ${audmeta[*]} ${audlang[*]} ${sublang[*]} ${sublng[*]} \"${OUTPUT%.*}.$i\" >/dev/null 2>&1" >> "$OUTFILE" echo "test \"\$?\" = \"0\" && green \"-> Done\" || red \"-> Failed!\"" >> "$OUTFILE" case "$i" in mp4|m4v|mov)
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.