Skip to main content

Notice

Please note that most of the software linked on this forum is likely to be safe to use. If you are unsure, feel free to ask in the relevant topics, or send a private message to an administrator or moderator. To help curb the problems of false positives, or in the event that you do find actual malware, you can contribute through the article linked here.
Topic: Error by converting from 24bit/192khz FLAC file (Read 4801 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Error by converting from 24bit/192khz FLAC file

I own a SONOS multi-room system. My media library ist send to SONOS by a Subsonic media server.
Unfortunately SONOS can't play 24bit/192khz audio files. So my 24bit/192khz FLAC files can't be played too.

The solution can be the subsonic build in flac-transcoder.

To not loose a lot of quality i plan to convert all the 24bit/192khz audio files on the media server by the flac-transcoder on the fly by the following 2 commands:

1. decoding the 24bit/192khz flac files into raw format:

>> flac -d --force-raw-format --endian=little --sign=signed file.flac -o file.raw

2. encoding the raw files into 16bit/48000khz flac files:

>> flac --fast --force-raw-format --endian=little --sign=signed --channels=2 --bps=16 --sample-rate=48000 file.raw -f -o file.converted.flac

Unfortunatelly i get only a noise flac output at 16bit/48khz. On the other hand, when ich do this conversation not with 24bit/192khz but with 16bit/44,1khz FLAC files i succeed the get 16bit/48khz.

Maybe this is a FLAC bug? Or have i a brain error...? 

Can you please help me out? Thank you in advance...

Error by converting from 24bit/192khz FLAC file

Reply #1
2. encoding the raw files into 16bit/48000khz flac files:

>> flac --fast --force-raw-format --endian=little --sign=signed --channels=2 --bps=16 --sample-rate=48000 file.raw -f -o file.converted.flac

Unfortunatelly i get only a noise flac output at 16bit/48khz.

You do not convert here. You ask flac to treat data in 24bit/192kHz format AS IF they were in 16bit/44.1kHz format. Of course it doesn't work.


On the other hand, when ich do this conversation not with 24bit/192khz but with 16bit/44,1khz FLAC files i succeed the get 16bit/48khz.

But such 'conversion' increases pitch and reduces duration of a track.

You need to resample the audio to 44.1 kHz and reduce its bit depth to 16 bits.

Error by converting from 24bit/192khz FLAC file

Reply #2
@Nordstern
flac alone does not help here because it has no build in resampler, SoX should be able to do what you want.

Edit: I have to admit i don't know much about the subsonic server you use so SoX may be no option. On my Logitech media server SoX transcoding can be configured for the streamers.
Is troll-adiposity coming from feederism?
With 24bit music you can listen to silence much louder!

Error by converting from 24bit/192khz FLAC file

Reply #3
You do not convert here. You ask flac to treat data in 24bit/192kHz format AS IF they were in 16bit/44.1kHz format. Of course it doesn't work.


That's they Point i did not see...    Thank you! I have to think about another way to do this, as no other lossless converter is available in the system (QNAP).

Error by converting from 24bit/192khz FLAC file

Reply #4
QNAP supports DLNA
If SONOS supports DLNA too, it will probably  handle the conversion on the fly
TheWellTemperedComputer.com

Error by converting from 24bit/192khz FLAC file

Reply #5
That's they Point i did not see...    Thank you! I have to think about another way to do this, as no other lossless converter is available in the system (QNAP).


Is your issue with the bit-depth or the sample-rate?
lossyWAV -q X -a 4 -s h -A --feedback 2 --limit 15848 --scale 0.5 | FLAC -5 -e -p -b 512 -P=4096 -S- (having set foobar to output 24-bit PCM; scaling by 0.5 gives the ANS headroom to work)