Sox command line to downsample Pcm to Flac |
Sox command line to downsample Pcm to Flac |
Nov 18 2012, 23:06
Post
#1
|
|
![]() Group: Members Posts: 84 Joined: 12-May 08 Member No.: 53478 |
Can anyone please tell me the switches needed for downsampling hi-res Pcm (Std_In) to lo-res Flac (Std_Out)?
I am trying the following, but at 192000Hz neither the big nor little endian variety works. CODE sox.exe -q -t raw -s -b24 -c2 -r192000 -L - -t flac -C0 - rate 48000 => outputs distorted audio sox.exe -q -t raw -s -b24 -c2 -r192000 -B - -t flac -C0 - rate 48000 => outputs white noise Whereas (oddly enough) at 96000Hz the little endian works, but the big endian does not. CODE sox.exe -q -t raw -s -b24 -c2 -r96000 -L - -t flac -C0 - rate 48000 => works !! sox.exe -q -t raw -s -b24 -c2 -r96000 -B - -t flac -C0 - rate 48000 => outputs white noise Don't ask me why, but the fact that at 96000Hz an extra byte order flip makes a difference to the success rate, gives me a gut feeling that sox.exe is somehow hitting an internal timing issue or lack of CPU capacity (e.g. thread timing issue?). -------------------- AndrewFG (Whitebear -- http://www.whitebear.ch/mediaserver )
|
|
|
|
![]() |
Nov 19 2012, 20:22
Post
#2
|
|
|
Group: Members Posts: 318 Joined: 26-November 04 Member No.: 18345 |
Are the results (white noise, distorted audio, works) the result of streaming the audio to some particular player or of playing converted files?
|
|
|
|
Nov 19 2012, 23:06
Post
#3
|
|
![]() Group: Members Posts: 84 Joined: 12-May 08 Member No.: 53478 |
Are the results (white noise, distorted audio, works) the result of streaming the audio to some particular player or of playing converted files? Either. Both. If the audio plays wrong when streamed directly, it also plays wrong when saved to a file and played later... -------------------- AndrewFG (Whitebear -- http://www.whitebear.ch/mediaserver )
|
|
|
|
andrewfg Sox command line to downsample Pcm to Flac Nov 18 2012, 23:06
saratoga What format is the PCM you're feeding sox? Nov 19 2012, 00:04
andrewfg QUOTE (saratoga @ Nov 19 2012, 00:04) Wha... Nov 19 2012, 19:08
chi Well, your audio seems to be little-endian, in any... Nov 19 2012, 02:04
andrewfg QUOTE (chi @ Nov 19 2012, 02:04) Well, yo... Nov 19 2012, 19:45
saratoga QUOTE (andrewfg @ Nov 19 2012, 14:45) I s... Nov 19 2012, 20:27
andrewfg QUOTE (saratoga @ Nov 19 2012, 20:27) Per... Nov 19 2012, 23:08
saratoga QUOTE (andrewfg @ Nov 19 2012, 18:08) QUO... Nov 19 2012, 23:12
JJZolx I just tried this out for myself and it worked fin... Nov 20 2012, 02:43
andrewfg QUOTE (JJZolx @ Nov 20 2012, 02:43) I jus... Nov 22 2012, 11:14
chi QUOTE (saratoga @ Nov 19 2012, 21:27) Are... Nov 21 2012, 02:38
andrewfg QUOTE (chi @ Nov 21 2012, 02:38) Is it po... Nov 22 2012, 11:36![]() ![]() |
|
Lo-Fi Version | Time is now: 22nd May 2013 - 06:36 |