Package: jack / 3.1.1+cvs20050801-31

24_vbr_before_otf.patch Patch series | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
Check for the availability of VBR before OTF so it's possible to fall back
to fixed bitrate OTF encoding; thanks, Robert Millan.  Debian: #320093.

diff -urN jack-3.1.1~/jack_checkopts.py jack-3.1.1/jack_checkopts.py
--- jack-3.1.1~/jack_checkopts.py	2005-07-26 23:01:54.740757664 +0100
+++ jack-3.1.1/jack_checkopts.py	2005-07-26 23:06:30.786792288 +0100
@@ -178,15 +178,15 @@
         warning("disabling on-the-fly operation as we're reading from image.")
         cf.rupdate({'otf': {'val': 0}}, "check")
 
+    if cf['_vbr'] and not jack_helpers.helpers[cf['_encoder']].has_key('vbr-cmd'):
+        warning("disabling VBR because " + cf['_encoder'] + " doesn't support it.")
+        cf.rupdate({'vbr': {'val': 0}}, "check")
+
     if cf['_otf']:
         for i in (cf['_ripper'], cf['_encoder']):
             if not jack_helpers.helpers[i].has_key(('vbr-' * cf['_vbr'] * (i == cf['_encoder'])) + 'otf-cmd'):
                 error("can't do on-the-fly because " + jack_helpers.helpers[i]['type'] + " " + i + " doesn't support it.")
 
-    if cf['_vbr'] and not jack_helpers.helpers[cf['_encoder']].has_key('vbr-cmd'):
-        warning("disabling VBR because " + cf['_encoder'] + " doesn't support it.")
-        cf.rupdate({'vbr': {'val': 0}}, "check")
-
     if not cf['_vbr'] and not jack_helpers.helpers[cf['_encoder']].has_key('cmd'):
         error("can't do CBR because " + cf['encoder']['val'] + " doesn't support it. Use -v")