dtas-all
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH] splitfx: fix typo for dither application


From: Eric Wong
Subject: [PATCH] splitfx: fix typo for dither application
Date: Sun, 10 May 2015 08:52:04 +0000

We do not need to dither unless we output to 16-bit or less.
This bug caused us to unnecessarily apply dither on 24-bit
output files.  Oops!
---
 lib/dtas/splitfx.rb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/lib/dtas/splitfx.rb b/lib/dtas/splitfx.rb
index 6271fb0..208ff67 100644
--- a/lib/dtas/splitfx.rb
+++ b/lib/dtas/splitfx.rb
@@ -184,7 +184,7 @@ class DTAS::SplitFX # :nodoc:
     # add noise-shaped dither for 16-bit (sox manual seems to recommend this)
     if opts[:no_dither]
       env["SOX_OPTS"] = "#{ENV["SOX_OPTS"]} -D"
-    else outfmt.bits && outfmt.bits <= 16
+    elsif outfmt.bits && outfmt.bits <= 16
       env["DITHERFX"] = "dither -s"
     end
     comments = Tempfile.new(%W(dtas-splitfx-#{t.comments["TRACKNUMBER"]} .txt))
-- 
EW




reply via email to

[Prev in Thread] Current Thread [Next in Thread]