Projects
Multimedia
ffx264
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 117
View file
ffx264.changes
Changed
@@ -1,4 +1,16 @@ ------------------------------------------------------------------- +Sun Oct 20 04:39:00 UTC 2019 - neutrino8@opensuse.org + +- Update to version 3.9.2 +* Added support for embedding of SRT/SSA/ASS subtitles + in the MP4/M4V containers +* Moved back to MP4Box for adding cover art to MP4/M4V/MOV. + Apparently, after lots of testing, atomicparsley + creates files that hang during playback +* Cosmetics +* Updated the man page + +------------------------------------------------------------------- Sat Oct 19 07:16:00 UTC 2019 - neutrino8@opensuse.org - Update to version 3.9.1
View file
ffx264.spec
Changed
@@ -17,7 +17,7 @@ Name: ffx264 -Version: 3.9.1 +Version: 3.9.2 Release: 0 Summary: A small shell script for encoding to H.264 with ffmpeg License: GPL-2.0+ @@ -27,7 +27,7 @@ Requires: ffmpeg Requires: bc Requires: MPlayer -Requires: AtomicParsley +Requires: gpac BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildArch: noarch
View file
ffx264-3.9.1.tar.gz/ChangeLog -> ffx264-3.9.2.tar.gz/ChangeLog
Changed
@@ -1,3 +1,12 @@ +2019-10-20 - ffx264 3.9.2 + * Added support for embedding of SRT/SSA/ASS subtitles + in the MP4/M4V containers + * Moved back to MP4Box for adding cover art to MP4/M4V/MOV. + Apparently, after lots of testing, atomicparsley + creates files that hang during playback + * Cosmetics + * Updated the man page + 2019-10-19- ffx264 3.9.1 * Use atomicparsley to add cover art for the mp4/m4v containers. This removes dependence on MP4Box and
View file
ffx264-3.9.1.tar.gz/ffx264 -> ffx264-3.9.2.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.1 -# Date: 2019-10-19 +# Version: 3.9.2 +# Date: 2019-10-20 # # 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,10 +24,10 @@ 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.1" +version="3.9.2" CFG="$HOME/.ffx264" -cfgversion="38" +cfgversion="39" genconfig_func() { cat<<EOF>>"$CFG" @@ -123,7 +123,7 @@ FFMPEG="" FFPROBE="" MPLAYER="" -ATOMICPARSLEY="" +MP4BOX="" # Add a custom comment to your encodes # Leave empty to disable/ask each time @@ -385,17 +385,17 @@ fi fi -if [ ! -z "$ATOMICPARSLEY" ]; then - if [ ! -x "$ATOMICPARSLEY" ]; then - error "-> atomicparsley is missing from your system!" +if [ ! -z "$MP4BOX" ]; then + if [ ! -x "$MP4BOX" ]; then + error "-> MP4Box is missing from your system!" error "-> Check the config in '$CFG'" echo exit 1 fi else - ATOMICPARSLEY="$(which atomicparsley 2>/dev/null)" - if [ ! -x "$ATOMICPARSLEY" ]; then - error "-> atomicparsley is missing from your system!" + MP4BOX="$(which MP4Box 2>/dev/null)" + if [ ! -x "$MP4BOX" ]; then + error "-> MP4Box is missing from your system!" echo exit 1 fi @@ -664,7 +664,7 @@ fi case "$CONFMT" in - mkv|mp4|m4v) + mkv|mp4|m4v|mov) printf "Specify a Cover Image in JPG/PNG format [press 'Enter' to skip]: " read -e cover if [ ! -z "$cover" ]; then @@ -682,7 +682,7 @@ esac case "$CONFMT" in mkv) MKVCOVER="-attach \"$(readlink -e "$cover")\" -metadata:s:t mimetype=\"image/$img\"" ;; - mp4|m4v) MP4COVER="1" ;; + mp4|m4v|mov) MP4COVER="1" ;; esac fi fi @@ -2023,6 +2023,14 @@ exit 1 ;; esac + case "$CONFMT" in + mkv|mp4|m4v|m2ts|mts|ts) true ;; + *) + error "-> The $CONFMT container doesn't support SRT/SSA/ASS subtitles!" + error "-> Supported containers are: mkv, mp4, m4v, m2ts, mts and ts" + exit 1 + ;; + esac if [ "$SUBCP" != "0" ]; then for i in $(eval echo "{1..$SUBCP}"); do subindex[i]="$(($i-1))" @@ -2036,7 +2044,11 @@ # where in some cases it flags subsequent tracks # as default. test "$i" = "1" && sdis="default" || sdis="none" - subcopy[i]="-map ${subnr[i]} -c:s:${subindex[i]} copy ${sublang[i]} -disposition:s:${subindex[i]} $sdis" + case "$CONFMT" in + mp4|m4v) submuxer_in="mov_text" ;; + *) submuxer_in="copy" ;; + esac + subcopy[i]="-map ${subnr[i]} -c:s:${subindex[i]} $submuxer_in ${sublang[i]} -disposition:s:${subindex[i]} $sdis" else error "-> No value given!" exit 1 @@ -2047,22 +2059,22 @@ ;; ext) case "$CONFMT" in - mkv|m2ts|mts|ts) true ;; + mkv|mp4|m4v|m2ts|mts|ts) true ;; *) - error "-> The $CONFMT container doesn't support srt/ssa subtitles!" - error "-> Supported containers are: mkv, m2ts, mts and ts" + error "-> The $CONFMT container doesn't support SRT/SSA/ASS subtitles!" + error "-> Supported containers are: mkv, mp4, m4v, m2ts, mts and ts" exit 1 ;; esac if [ ! -z "$remuxcon" ]; then for i in $remuxcon; do case "$i" in - mkv|m2ts|mts|ts) true ;; + mkv|mp4|m4v|m2ts|mts|ts) true ;; *) echo error "-> Warning: One or more chosen additional container" - error " doesn't support srt/ssa subtitles!" - error "-> Remuxing will most likely fail!" + error " doesn't support SRT/SSA/ASS subtitles!" + error "-> Subtitles will be ignored during remuxing!" echo break ;; @@ -2097,8 +2109,12 @@ else test "$i" = "1" && sdispo="default" || sdispo="none" fi - EXTSUBS[i]="-i \"${subfile[i]}\"" - subcpy[i]="-map $i:0 -c:s:${subidx[i]} copy ${sublng[i]} -disposition:s:${subidx[i]} $sdispo" + case "$CONFMT" in + mp4|m4v) submuxer_ext="mov_text" ;; + *) submuxer_ext="copy" ;; + esac + EXTSUBS[i]="-i \"$(readlink -e "${subfile[i]}")\"" + subcpy[i]="-map $i:0 -c:s:${subidx[i]} $submuxer_ext ${sublng[i]} -disposition:s:${subidx[i]} $sdispo" fi done fi @@ -2124,10 +2140,10 @@ echo brown " Subtitles" brown " ~~~~~~~~~" - echo " 0 -> Copy subtitles from the input file" - echo " 1 -> Add external subtitle files (SRT/SSA only!)" - echo " 2 -> Copy subs from input file + add external ones (SRT/SSA only!)" - echo " 3 -> Hardcode a subtitle (text-based subs only!)" + echo " 0 -> Copy subtitles from the input file (SRT/SSA/ASS only!)" + echo " 1 -> Add external subtitle files (SRT/SSA/ASS only!)" + echo " 2 -> Copy subs from input file + add external ones (SRT/SSA/ASS only!)" + echo " 3 -> Hardcode a subtitle (SRT/SSA/ASS only!)" echo printf "Specify the Subtitle Option [press 'Enter' to skip]: " read subopt @@ -2158,8 +2174,8 @@ ;; 3) echo - echo " 0 -> Hardcode an External Subtitle (text-based subs only!)" - echo " 1 -> Hardcode an Embedded Subtitle (text-based subs only!)" + echo " 0 -> Hardcode an External Subtitle (SRT/SSA/ASS only!)" + echo " 1 -> Hardcode an Embedded Subtitle (SRT/SSA/ASS only!)" echo printf "Specify the Subtitle Option [press 'Enter' to skip]: " read sub @@ -3386,12 +3402,16 @@ encoder_func $encmode >> "$OUTFILE" echo "" >> "$OUTFILE" case "$CONFMT" in - mp4|m4v) + mp4|m4v|mov) if [ ! -z "$MP4COVER" ]; then echo "echo" >> "$OUTFILE" echo "green \"-> Adding cover image...\"" >> "$OUTFILE" - echo "$ATOMICPARSLEY \"$OUTPUT\" --artwork \"$(readlink -e "$cover")\" --overWrite >/dev/null 2>&1" >> "$OUTFILE" - echo "test \"\$?\" = \"0\" && green \"-> Done\" || red \"-> Failed!\"" >> "$OUTFILE" + echo "$MP4BOX -add \"$OUTPUT\" -itags cover=\"$(readlink -e "$cover")\":name=\"$(basename "${OUTPUT%.*}")\":genre=\"$genre\":created=\"$year\":comment=\"$COMMENT\" -mpeg4 -new \"${OUTPUT%.*}_COVER_$$.$CONFMT\" >/dev/null 2>&1" >> "$OUTFILE" + echo "RET=\$?" >> "$OUTFILE" + echo "test \"\$RET\" = \"0\" && green \"-> Done\" || red \"-> Failed!\"" >> "$OUTFILE" + echo "if [ \"\$RET\" = \"0\" ]; then" >> "$OUTFILE" + echo "mv -f \"${OUTPUT%.*}_COVER_$$.$CONFMT\" \"${OUTPUT%.*}.$CONFMT\"" >> "$OUTFILE" + echo "fi" >> "$OUTFILE" echo "echo" >> "$OUTFILE" echo "" >> "$OUTFILE" fi @@ -3414,16 +3434,32 @@ ;; *) vflags1=""; vflags2=""; MKVCOVER2="" ;; esac - echo "$FFMPEG $vflags1 -i \"$OUTPUT\" -map 0 -c copy $vflags2 $strict $MKVCOVER2 $METATITLE $METAGENRE $METAYEAR $METACOMMENT ${audmeta[*]} ${audlang[*]} ${sublang[*]} ${sublng[*]} \"${OUTPUT%.*}.$i\" >/dev/null 2>&1" >> "$OUTFILE" + if [ "$subparams" != "-sn" ]; then + case "$i" in + mp4|m4v) suboption="-c:s mov_text" ;; + mov|avi|flv|wmv) suboption="-sn" ;; + *) + case "$(basename "${OUTPUT##*.}")" in + mp4|m4v) suboption="-c:s srt" ;; + *) suboption="-c:s copy" ;; + esac + ;; + esac + fi + echo "$FFMPEG $vflags1 -i \"$OUTPUT\" -map 0 -c:v copy -c:a copy $suboption $vflags2 $strict $MKVCOVER2 $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) - if [ ! -z "$MKVCOVER" ]; then + mp4|m4v|mov) + if [ ! -z "$MKVCOVER" -o ! -z "$MP4COVER" ]; then echo "" >> "$OUTFILE" echo "echo" >> "$OUTFILE" echo "green \"-> Adding cover image...\"" >> "$OUTFILE" - echo "$ATOMICPARSLEY \"${OUTPUT%.*}.$i\" --artwork \"$(readlink -e "$cover")\" --overWrite >/dev/null 2>&1" >> "$OUTFILE" - echo "test \"\$?\" = \"0\" && green \"-> Done\" || red \"-> Failed!\"" >> "$OUTFILE" + echo "$MP4BOX -add \"${OUTPUT%.*}.$i\" -itags cover=\"$(readlink -e "$cover")\":name=\"$(basename "${OUTPUT%.*}")\":genre=\"$genre\":created=\"$year\":comment=\"$COMMENT\" -mpeg4 -new \"${OUTPUT%.*}_COVER_$$.$i\" >/dev/null 2>&1" >> "$OUTFILE" + echo "RET=\$?" >> "$OUTFILE" + echo "test \"\$RET\" = \"0\" && green \"-> Done\" || red \"-> Failed!\"" >> "$OUTFILE" + echo "if [ \"\$RET\" = \"0\" ]; then" >> "$OUTFILE" + echo "mv -f \"${OUTPUT%.*}_COVER_$$.$i\" \"${OUTPUT%.*}.$i\"" >> "$OUTFILE" + echo "fi" >> "$OUTFILE" fi ;; esac
View file
ffx264-3.9.1.tar.gz/ffx264.1 -> ffx264-3.9.2.tar.gz/ffx264.1
Changed
@@ -3,7 +3,7 @@ .de IPs .IP "\\$1" .. -.TH ffx264 1 "Oct 19, 2019" +.TH ffx264 1 "Oct 20, 2019" .SH NAME ffx264 @@ -30,7 +30,7 @@ .br - MPlayer (for crop preview only) .br -- atomicparsley, version 0.9.2 or higher (for mp4 cover art only) +- MP4Box from GPAC (for mp4/m4v/mov cover art only) .br - bc
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
.