Changes of Revision 10

ffhevc.changes Changed
x
 
1
@@ -1,4 +1,23 @@
2
 -------------------------------------------------------------------
3
+Mon Nov 07 16:25:00 UTC 2016 - neutrino8@opensuse.org
4
+
5
+- Update to version 2.9.5
6
+  * Cosmetics in the code for deinterlacing
7
+  * Instead of skipping FPS conversion if the FPS can't be detected,
8
+    ask the user to provide it
9
+  * Use single brackets instead of double ones in the nosound
10
+    setup code
11
+  * Added license snippet at the top of the script
12
+  * Added support for outputting to additional container formats
13
+  * Do some checking on supported audio codecs for the supported
14
+    containers
15
+  * Check specified container and warn and exit if it's not supported
16
+  * Support setting the FLAC compression level
17
+  * Break out of the if conditionals in the audio code and replace
18
+    them with two case statements
19
+  * Update to the README file
20
+  
21
+-------------------------------------------------------------------
22
 Sun Nov 06 09:52:00 UTC 2016 - neutrino8@opensuse.org
23
 
24
 - Update to version 2.9.4
25
ffhevc.spec Changed
10
 
1
@@ -17,7 +17,7 @@
2
 
3
 
4
 Name:           ffhevc
5
-Version:        2.9.4
6
+Version:        2.9.5
7
 Release:        0
8
 Summary:        A small shell script for encoding to H.265/HEVC with ffmpeg
9
 License:        GPL-2.0+
10
ffhevc-2.9.4.tar.gz/ChangeLog -> ffhevc-2.9.5.tar.gz/ChangeLog Changed
21
 
1
@@ -1,3 +1,19 @@
2
+2016-11-07 - ffhevc 2.9.5
3
+   * Cosmetics in the code for deinterlacing
4
+   * Instead of skipping FPS conversion if the FPS can't be detected,
5
+     ask the user to provide it
6
+   * Use single brackets instead of double ones in the nosound
7
+     setup code
8
+   * Added license snippet at the top of the script
9
+   * Added support for outputting to additional container formats
10
+   * Do some checking on supported audio codecs for the supported
11
+     containers
12
+   * Check specified container and warn and exit if it's not supported
13
+   * Support setting the FLAC compression level
14
+   * Break out of the if conditionals in the audio code and replace
15
+     them with two case statements
16
+   * Update to the README file
17
+   
18
 2016-11-06 - ffhevc 2.9.4
19
    * Bugfix: resampling wasn't working for fdk-aac due to missing
20
      value in the case statement
21
ffhevc-2.9.4.tar.gz/README -> ffhevc-2.9.5.tar.gz/README Changed
9
 
1
@@ -27,6 +27,7 @@
2
 - it supports cover art for the MKV container.
3
 - it supports the x265 presets and tune profiles.
4
 - it supports custom written preset files.
5
+- it can output to more than one container.
6
 
7
 Parameters:
8
 
9
ffhevc-2.9.4.tar.gz/ffhevc -> ffhevc-2.9.5.tar.gz/ffhevc Changed
201
 
1
@@ -2,15 +2,28 @@
2
 #
3
 # Small script to encode to H.265/HEVC video using FFmpeg and libx265.
4
 # Author: Grozdan "microchip" Nikolov <neutrino8@opensuse.org>
5
-# Version: 2.9.4
6
-# Date: 2016-11-06
7
-# License: GNU GPLv2+
8
+# Version: 2.9.5
9
+# Date: 2016-11-07
10
+#
11
+# ffhevc is free software ; you can redistribute it and/or modify
12
+# it under the terms of the GNU General Public License as published by
13
+# the Free Software Foundation ; either version 2 of the License, or
14
+# (at your option) any later version.
15
+#
16
+# ffhevc is distributed in the hope that it will be useful,
17
+# but WITHOUT ANY WARRANTY ; without even the implied warranty of
18
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
19
+# GNU General Public License for more details.
20
+#
21
+# You should have received a copy of the GNU General Public License
22
+# along with this program ; if not, write to the Free Software
23
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
24
 
25
 green() { echo -e "\e[1;32m$1\e[0;39;49m"; }
26
 brown() { echo -e "\e[0;33m$1\e[0;39;49m"; }
27
 error() { echo -e "\e[1;31m$1\e[0;39;49m"; }
28
 
29
-version="2.9.4"
30
+version="2.9.5"
31
 
32
 CFG="$HOME/.ffhevc"
33
 cfgversion="28"
34
@@ -355,11 +368,55 @@
35
        read confmt
36
        test -z "$confmt" && CON="mkv" || CON="$confmt"
37
    fi
38
+   
39
    CON="$(echo "$CON" | tr '[:upper:]' '[:lower:]')"
40
+   
41
    case "$CON" in
42
-       mp4|m4v|mov)    movflags="-movflags +faststart" ;;
43
+       mp4)    movflags="-movflags +faststart" ;;
44
+       mkv)    true ;;
45
+       *)
46
+       error "-> HEVC video not supported by chosen container!"
47
+       error "-> Supported containers are: mkv and mp4"
48
+       error "-> Check your config file, if needed, in '$CFG'"
49
+       exit 1
50
+       ;;
51
    esac
52
    
53
+   printf "Output to Additional Container Formats? [y/N]: "
54
+   read acf
55
+   if [ "$acf" = "y" -o "$acf" = "Y" ]; then
56
+       printf "Specify the Container Formats [example: mp4,mkv - press 'Enter' to skip]: "
57
+       read econ
58
+       test ! -z "$econ" && extracon="$(echo "$econ" | sed 's|,| |g' | tr '[:upper:]' '[:lower:]')"
59
+       if [ ! -z "$extracon" ]; then
60
+           for i in $extracon; do
61
+               if [ "$i" = "$CON" ]; then
62
+                   error "-> Additional container matches the main output container!"
63
+                   exit 1
64
+               fi
65
+               case "$i" in
66
+                   mkv|mp4) true ;;
67
+                   *)
68
+                   error "-> HEVC video not supported by the $i container!"
69
+                   error "-> Supported containers are: mkv and mp4"
70
+                   exit 1
71
+                   ;;
72
+               esac
73
+               echo
74
+               case "$i" in
75
+                   mkv)
76
+                   green "-> Note: additional container $i supports all the audio codecs"
77
+                   ;;
78
+                   mp4)
79
+                   green "-> Note: additional container $i supports the following audio codecs:"
80
+                   green "-> ac3|eac3|dts|aac|fdk-aac|mp3|vorbis|copy|nosound"
81
+                   ;;
82
+               esac
83
+           done
84
+           echo
85
+       fi
86
+   fi
87
+   
88
    OUTPUT="$OUTPUT.$CON"
89
    
90
    test -e "$OUTPUT" && mv -f "$OUTPUT" "$OUTPUT.old"
91
@@ -528,8 +585,8 @@
92
    esac
93
    green "-> Detected $fparity Parity"
94
    if [ "$fp" = "progressive" ]; then
95
-       error "-> Your file appears to be progressive but"
96
-       error "   this may be a misdetection!"
97
+       error "-> The video stream appears to be progressive"
98
+       error "   but this may be a misdetection!"
99
    elif [ "$fp" = "???" ]; then
100
        error "-> Could not detect the Field Parity!"
101
    fi
102
@@ -576,16 +633,15 @@
103
            video_fps_func
104
            if [ ! -z "$GETFPS" ]; then
105
                FPS1="$(echo "$GETFPS" | awk -F/ '{print $1}')"
106
-               FPS2="$(echo "$GETFPS"| awk -F/ '{print $2}')"
107
+               FPS2="$(echo "$GETFPS" | awk -F/ '{print $2}')"
108
                OFPS="$(($FPS1*2))/$FPS2"
109
                green "-> Detected: $FPS1/$FPS2 FPS"
110
                green "-> Setting output FPS to: $OFPS"
111
-               echo
112
                ofps="-r $OFPS"
113
            else
114
                error "-> Could not detect the FPS value!"
115
-               echo
116
            fi
117
+           echo
118
            video_deinterlace_func bob
119
            bob="1"
120
            ;;
121
@@ -750,7 +806,7 @@
122
            sleep 1
123
            video_fps_func
124
            if [ ! -z "$GETFPS" ]; then
125
-               green "-> Detected: $GETFPS FPS"
126
+               green "-> Detected $GETFPS FPS"
127
            else
128
                error "-> Could not detect the FPS value!"
129
            fi
130
@@ -760,141 +816,147 @@
131
                echo
132
                error "-> Detected FPS is not supported yet!"
133
                error "-> Supported FPS are: 24/1, 25/1, 24000/1001 and 30000/1001"
134
-               error "-> Skipping FPS conversion!"
135
-               skipfps="1"
136
+               echo
137
+               printf "Specify the FPS value of the Input File [no default!]: "
138
+               read infps
139
+               case "$infps" in
140
+                   24/1|25/1|24000/1001|30000/1001) true ;;
141
+                   ""|*)
142
+                   error "-> No value or unsupported value given!"
143
+                   exit 1
144
+                   ;;
145
+               esac
146
                ;;
147
            esac
148
            echo
149
-           if [ -z "$skipfps" ]; then
150
-               brown " FPS Conversion Filters"
151
-               brown " ~~~~~~~~~~~~~~~~~~~~~~"
152
-               echo " 0 -> fps (converts by duplicating/dropping of frames)"
153
-               echo " 1 -> setpts + atempo (converts by PTS + audio speedup/down)"
154
-               echo
155
-               printf "Specify the FPS conversion method [default is 0]: "
156
-               read fcm
157
+           brown " FPS Conversion Filters"
158
+           brown " ~~~~~~~~~~~~~~~~~~~~~~"
159
+           echo " 0 -> fps (converts by duplicating/dropping of frames)"
160
+           echo " 1 -> setpts + atempo (converts by PTS + audio speedup/down)"
161
+           echo
162
+           printf "Specify the FPS conversion method [default is 0]: "
163
+           read fcm
164
+           case "$fcm" in
165
+               0|1|"") true ;;
166
+               *)
167
+               error "-> Invalid option!"
168
+               exit 1
169
+               ;;
170
+           esac
171
+           echo
172
+           brown " NTSC <-> PAL and NTSC <-> NTSC FPS Conversion"
173
+           brown " ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~"
174
+           echo " 0 --> 23.976 FPS (24000/1001) to 24 FPS"
175
+           echo " 1 --> 23.976 FPS (24000/1001) to 25 FPS"
176
+           echo " 2 --> 23.976 FPS (24000/1001) to 29.970 FPS"
177
+           echo
178
+           echo " 3 --> 24 FPS to 23.976 FPS (24000/1001)"
179
+           echo " 4 --> 24 FPS to 25 FPS"
180
+           echo " 5 --> 24 FPS to 29.970 FPS (30000/1001)"
181
+           echo
182
+           echo " 6 --> 25 FPS to 23.976 FPS (24000/1001)"
183
+           echo " 7 --> 25 FPS to 24 FPS"
184
+           echo " 8 --> 25 FPS to 29.970 FPS (30000/1001)"
185
+           echo
186
+           echo " 9 --> 29.970 FPS (30000/1001) to 23.976 FPS (24000/1001)"
187
+           echo " 10 -> 29.970 FPS (30000/1001) to 24 FPS"
188
+           echo " 11 -> 29.970 FPS (30000/1001) to 25 FPS"
189
+           echo
190
+           printf "Specify the FPS Conversion option [press 'Enter' to skip]: "
191
+           read fpsopt
192
+           case "$fpsopt" in
193
+               0)
194
                case "$fcm" in
195
-                   0|1|"") true ;;
196
-                   *)
197
-                   error "-> Invalid option!"
198
-                   exit 1
199
-                   ;;
200
+                   0|"")   fps="fps=fps=24," ;;
201