Projects
Multimedia
ffx264
Sign Up
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Changes of Revision 85
View file
ffx264.changes
Changed
@@ -1,4 +1,12 @@ ------------------------------------------------------------------- +Tue Jul 23 11:15:00 UTC 2019 - neutrino8@opensuse.org + +- Update to version 3.7.2 + * Added support for crop preview using MPlayer when + autocrop is enabled in the config file. This was + ported over from my h264enc script + +------------------------------------------------------------------- Thu Jun 13 02:30:00 UTC 2019 - neutrino8@opensuse.org - Update to version 3.7.1
View file
ffx264.spec
Changed
@@ -17,7 +17,7 @@ Name: ffx264 -Version: 3.7.1 +Version: 3.7.2 Release: 0 Summary: A small shell script for encoding to H.264 with ffmpeg License: GPL-2.0+ @@ -26,6 +26,7 @@ Source0: %{name}-%{version}.tar.gz Requires: ffmpeg Requires: bc +Requires: MPlayer BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildArch: noarch
View file
ffx264-3.7.1.tar.gz/ChangeLog -> ffx264-3.7.2.tar.gz/ChangeLog
Changed
@@ -1,3 +1,8 @@ +2019-07-23 - ffx264 3.7.2 + * Added support for crop preview using MPlayer when + autocrop is enabled in the config file. This was + ported over from my h264enc script + 2019-06-13 - ffx264 3.7.1 * Added support for the bm3d denoise filter
View file
ffx264-3.7.1.tar.gz/ffx264 -> ffx264-3.7.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.7.1 -# Date: 2019-06-13 +# Version: 3.7.2 +# Date: 2019-07-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,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.7.1" +version="3.7.2" CFG="$HOME/.ffx264" -cfgversion="34" +cfgversion="35" genconfig_func() { cat<<EOF>>"$CFG" @@ -115,10 +115,11 @@ # to fit your needs X264PARAMS="force-cfr=1:bframes=6:keyint=240:min-keyint=24:ref=4:trellis=2:merange=24:direct-pred=auto:chroma-me=1:mbtree=1:me=umh:subme=10:b-adapt=2:aq-mode=1:aq-strength=1.05:psy=1:psy-rd=1.05,0.15:rc-lookahead=60:weightb=1:weightp=2:mixed-refs=1:b-pyramid=normal:fast-pskip=0:deblock=-1,-1:8x8dct=1:cabac=1:partitions=p8x8,b8x8,i8x8,i4x4:threads=auto" -# Leave empty to auto-detect ffmpeg/ffprobe or -# set your custom ones (eg, /path/to/bin/ffmpeg) +# Leave empty to auto-detect ffmpeg/ffprobe/mplayer +# or set your custom ones (eg, /path/to/bin/ffmpeg) FFMPEG="" FFPROBE="" +MPLAYER="" # Add a custom comment to your encodes # Leave empty to disable/ask each time @@ -364,6 +365,22 @@ fi fi +if [ ! -z "$MPLAYER" ]; then + if [ ! -x "$MPLAYER" ]; then + error "-> MPlayer is missing from your system!" + error "-> Check the config in '$CFG'" + echo + exit 1 + fi +else + MPLAYER="$(which mplayer 2>/dev/null)" + if [ ! -x "$MPLAYER" ]; then + error "-> MPlayer is missing from your system!" + echo + exit 1 + fi +fi + BC="$(which bc 2>/dev/null)" if [ ! -x "$BC" ]; then error "-> Utility 'bc' is missing from your system!" @@ -1363,16 +1380,44 @@ CDEF="???" fi echo - printf "Specify the Crop Values [default is $CROPVAL$CDEF]: " - read cropval - if [ ! -z "$CDEF" -a -z "$cropval" ]; then - echo - error "-> No crop values provided!" - error "-> Skipping!" - echo - else - test -z "$cropval" && crop="crop=$CROPVAL," || crop="crop=$cropval," - fi + CROPDETERMINED="n" + while [ "$CROPDETERMINED" != "y" -o "$CROPDETERMINED" = "Y" ]; do + if [ -z "$cropval" ]; then + printf "Specify the Crop Values [default is $CROPVAL]: " + else + printf "Specify the Crop Values [last try: "$cropval"]: " + fi + read cropval + if [ -z "$cropval" -a "$CDEF" = "???" ]; then + crop= + echo + error "-> Crop values not specified!" + error "-> Skipping!" + echo + else + if [ -z "$cropval" ]; then + crop="crop=$CROPVAL," + crop_preview="$CROPVAL" + else + crop="crop=$cropval," + crop_preview="$cropval" + fi + printf "Preview the Crop Values for 10 seconds? [y/N]: " + read precrop + if [ "$precrop" = "y" -o "$precrop" = "Y" ]; then + printf "Specify the Start Position in hour:min:sec [default is 0:02:00]: " + read timepos + if [ -z "$timepos" ]; then + startpos="0:02:00" + else + startpos="$timepos" + fi + $MPLAYER "$input" -vf rectangle=$crop_preview -noconfig all -nocache -ao null -ss $startpos -endpos 10 >/dev/null 2>&1 + fi + fi + printf "Are you Satisfied with the Crop Area? [y/N]: " + read CROPDETERMINED + done fi else printf "Specify the Crop Values [press 'Enter' to skip]: "
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
.