Projects
Multimedia
ffhevc
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 172
View file
ffhevc.changes
Changed
@@ -1,4 +1,14 @@ ------------------------------------------------------------------- +Sun Oct 27 07:28:00 UTC 2019 - neutrino8@opensuse.org + +- Update to version 4.0.0 + * Use 16 bits as bit depth metadata when encoding to TrueHD audio + * Removed an unneeded if conditional in the audio bit depth code + * Add director and cast metadata for the MKV container + * Reorder some code for the output shell file + * Cosmetics + +------------------------------------------------------------------- Sat Oct 26 07:05:00 UTC 2019 - neutrino8@opensuse.org - Update to version 3.9.9
View file
ffhevc.spec
Changed
@@ -17,7 +17,7 @@ Name: ffhevc -Version: 3.9.9 +Version: 4.0.0 Release: 0 Summary: A small shell script for encoding to H.265/HEVC with FFmpeg License: GPL-2.0+
View file
ffhevc-3.9.9.tar.gz/ChangeLog -> ffhevc-4.0.0.tar.gz/ChangeLog
Changed
@@ -1,3 +1,10 @@ +2019-10-27 - ffhevc 4.0.0 + * Use 16 bits as bit depth metadata when encoding to TrueHD audio + * Removed an unneeded if conditional in the audio bit depth code + * Add director and cast metadata for the MKV container + * Reorder some code for the output shell file + * Cosmetics + 2019-10-26 - ffhevc 3.9.9 * Renamed audio variable aid[i] to aidx[i] and moved it outside of the if conditional that decides the audio codec. This
View file
ffhevc-3.9.9.tar.gz/ffhevc -> ffhevc-4.0.0.tar.gz/ffhevc
Changed
@@ -2,8 +2,8 @@ # # Small script to encode to H.265/HEVC video using FFmpeg and libx265. # Author: Grozdan "microchip" Nikolov <neutrino8@opensuse.org> -# Version: 3.9.9 -# Date: 2019-10-26 +# Version: 4.0.0 +# Date: 2019-10-27 # # ffhevc 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.9" +version="4.0.0" CFG="$HOME/.ffhevc" cfgversion="50" @@ -664,6 +664,25 @@ test ! -z "$comment" && COMMENT="$comment" fi +for i in $CONFMT $remuxcon; do + case "$i" in + mkv) + printf "Specify the Director of the Content [press 'Enter' to skip]: " + read director + test ! -z "$director" && METADIRECTOR="-metadata director=\"$director\"" + printf "Specify the Cast of the Content [press 'Enter' to skip]: " + read cast + test ! -z "$cast" && METACAST="-metadata cast=\"$cast\"" + ;; + *) + # Have to find a way how to add these tags + # to mp4/mov as well + METADIRECTOR="" + METACAST="" + ;; + esac +done + case "$CONFMT" in mkv|mp4|mov) printf "Specify a Cover Image in JPG/PNG format [press 'Enter' to skip]: " @@ -2437,7 +2456,7 @@ if [ ! -z "$batchmode" ]; then echo error "-> Due to current codebase limitations, automatic audio metadata" - error " will be that of the first input file provided. If all input files" + error " will be that of the first provided input file. If all input files" error " have the same audio properties (bit depth, sample rate, etc)" error " this won't be an issue. Usually, complete seasons of film series" error " have the same audio properties." @@ -2670,12 +2689,15 @@ test "${aidx[i]}" = "-1" && aidx[i]="0" if [ "${acodec[i]}" != "copy" ]; then - GETAUDBD[i]="$($FFPROBE -i "$input" -v quiet -select_streams a:${aidx[i]} -show_entries stream=bits_per_raw_sample -of default=noprint_wrappers=1:nokey=1 | tail -1)" - if [ ! -z "${GETAUDBD[i]}" ]; then + case "${acodec[i]}" in + truehd) abdmeta[i]=", 16 bits" ;; + *) + GETAUDBD[i]="$($FFPROBE -i "$input" -v quiet -select_streams a:${aidx[i]} -show_entries stream=bits_per_raw_sample -of default=noprint_wrappers=1:nokey=1 | tail -1)" case "${GETAUDBD[i]}" in [1-9]*) abdmeta[i]=", ${GETAUDBD[i]} bits input" ;; esac - fi + ;; + esac case "${acodec[i]}" in fdk*) printf "Track $i: Which AAC Profile to Use? [LC/HE/HEv2/LD - default is LC]: " @@ -3357,6 +3379,7 @@ test ! -z "${afilters[i]}" && audfilters[i]="-filter:a:${audindex[i]} ${afilters[i]}" else GETAUDCDC[i]="$($FFPROBE -i "$input" -v quiet -select_streams a:${aidx[i]} -show_entries stream=codec_name -of default=noprint_wrappers=1:nokey=1 | tail -1)" + if [ ! -z "${GETAUDCDC[i]}" ]; then GETAUDBTR[i]="$($FFPROBE -i "$input" -v quiet -select_streams a:${aidx[i]} -show_entries stream=bit_rate -of default=noprint_wrappers=1:nokey=1 | tail -1)" GETAUDBD[i]="$($FFPROBE -i "$input" -v quiet -select_streams a:${aidx[i]} -show_entries stream=bits_per_raw_sample -of default=noprint_wrappers=1:nokey=1 | tail -1)" @@ -3566,7 +3589,7 @@ test ! -z "$COMMENT" && METACOMMENT="-metadata comment=\"$COMMENT\"" encoder_func() { - VIDOPTS="${EXTSUBS[*]} $vidmap -disposition:v:0 default $aspect $ofps $METADATA $CHAPS $METATITLE $METAGENRE $METAYEAR $METACOMMENT $ffvbv_maxrate $ffvbv_bufsize $vfilters $coloroptions" + VIDOPTS="${EXTSUBS[*]} $vidmap -disposition:v:0 default $aspect $ofps $METADATA $CHAPS $METATITLE $METAGENRE $METAYEAR $METADIRECTOR $METACAST $METACOMMENT $ffvbv_maxrate $ffvbv_bufsize $vfilters $coloroptions" case "$1" in 1p|crf) test "$encmode" = "1p" && passone="bitrate=$vbitrate" || passone="crf=$CRF" @@ -3634,25 +3657,6 @@ fi encoder_func $encmode >> "$OUTFILE" echo "" >> "$OUTFILE" -case "$CONFMT" in - mp4|mov) - if [ ! -z "$MP4COVER" ]; then - 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\" -tmp \"$(dirname "$OUTPUT")\" -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 - ;; -esac if [ ! -z "$remuxcon" ]; then for i in $remuxcon; do echo "" >> "$OUTFILE" @@ -3678,14 +3682,14 @@ ;; esac fi - echo "$FFMPEG -i \"$OUTPUT\" -map 0 -c:v copy -c:a copy $suboption $strict $coloroptions $MKVCOVER2 $CHAPS $METATITLE $METAGENRE $METAYEAR $METACOMMENT ${audmeta[*]} ${audlang[*]} ${sublang[*]} ${sublng[*]} \"${OUTPUT%.*}.$i\" >/dev/null 2>&1" >> "$OUTFILE" + echo "$FFMPEG -i \"$OUTPUT\" -map 0 -c:v copy -c:a copy $suboption $strict $coloroptions $MKVCOVER2 $CHAPS $METATITLE $METAGENRE $METAYEAR $METADIRECTOR $METACAST $METACOMMENT ${audmeta[*]} ${audlang[*]} ${sublang[*]} ${sublng[*]} \"${OUTPUT%.*}.$i\" >/dev/null 2>&1" >> "$OUTFILE" echo "test \"\$?\" = \"0\" && green \"-> Done\" || red \"-> Failed!\"" >> "$OUTFILE" case "$i" in mp4|mov) if [ ! -z "$MKVCOVER" -o ! -z "$MP4COVER" ]; then echo "" >> "$OUTFILE" echo "echo" >> "$OUTFILE" - echo "green \"-> Adding cover image...\"" >> "$OUTFILE" + echo "green \"-> Adding cover image to $i...\"" >> "$OUTFILE" echo "$MP4BOX -add \"${OUTPUT%.*}.$i\"$color -itags cover=\"$(readlink -e "$cover")\":name=\"$(basename "${OUTPUT%.*}")\":genre=\"$genre\":created=\"$year\":comment=\"$COMMENT\" -tmp \"$(dirname "$OUTPUT")\" -mpeg4 -new \"${OUTPUT%.*}_COVER_$$.$i\" >/dev/null 2>&1" >> "$OUTFILE" echo "RET=\$?" >> "$OUTFILE" echo "test \"\$RET\" = \"0\" && green \"-> Done\" || red \"-> Failed!\"" >> "$OUTFILE" @@ -3698,6 +3702,25 @@ done echo "echo" >> "$OUTFILE" fi +case "$CONFMT" in + mp4|mov) + if [ ! -z "$MP4COVER" ]; then + case "$CONFMT" in + mov) color="$colr" ;; + esac + echo "echo" >> "$OUTFILE" + echo "green \"-> Adding cover image to $CONFMT...\"" >> "$OUTFILE" + echo "$MP4BOX -add \"$OUTPUT\"$color -itags cover=\"$(readlink -e "$cover")\":name=\"$(basename "${OUTPUT%.*}")\":genre=\"$genre\":created=\"$year\":comment=\"$COMMENT\" -tmp \"$(dirname "$OUTPUT")\" -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 + ;; +esac if [ ! -z "$batchmode" ]; then echo "$CHKFILE_END" >> "$OUTFILE" echo "$FORLOOP_END" >> "$OUTFILE"
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
.