Skip to main content
Topic: Sample formats: fltp (lossy) to s16p or s32p (ALAC) (Read 7060 times) previous topic - next topic
0 Members and 1 Guest are viewing this topic.

Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Hello,

because of compatibility problems I need to convert some DTS, DTS-HD HR, AC-3 and E-AC-3 audio streams to ALAC.
The lossy formats are stored as fltp (depth: 32 bit).

So my question is:

To preserve all information, should I convert them to s16p-ALAC or better s32p-ALAC (although mediainfo sometimes tells me bit depth of lossy stream is 16 bit).

Best regards,
Felix

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #1
I didn't think ALAC supported s32 samples? Assuming it does, that would be lossless, whereas 16 bit would lose some tiny bit of information.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #2
I've never used ALAC so I don't know what the options are...

But, just some reference points -

"CD quality" (16/44.1) is "better than human hearing".

The "pro studio standard" seems to be 24/96 (with the software using floating-point "internally"...  There a couple of good reasons for using floating-point for audio editing/processing/DSP).

I think one company makes a 32-bit DAC chip.  I'm not aware of any floating-point audio DACs.    And, from what I've read most 24-bit DACs (and ADCs) are only accurate to around 20-bits.   So, you can't directly-play a 32-bit or floating-point file.

Quote
although mediainfo sometimes tells me bit depth of lossy stream is 16 bit
Most lossy formats don't store integer samples so there is no bit depth.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #3
24 bit depth is more than enough.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #4
I think s32p for ALAC is 24 bit.
ffmpeg output:  Stream #0:0: Audio: alac (alac / 0x63616C61), 48000 Hz, 7.1(wide), s32p (24 bit), 128 kb/s

So again for stupid me.
fltp --> s16p: losing tiny bit of information; but I lose information.
fltp --> s32p: no lose of information.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #5
I only want to preserve the possibility to get back to the beginnig condition.
And I‘m not sure about the in-depth technics and algorithm the encoders use.

But when ffmpeg shows me a depth of 32 bit for the floating point algorithm and for the s32p algorithm also 32 bit. I see with my limited knowledge to stick with the s32p algorithm should be the best.
Am I right?

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #6
ALAC should support 24 bit
"I hear it when I see it."


Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #8
After intense googeling I found this: https://community.roonlabs.com/t/acc-mp3-lossy-output-24bit/45690/4

I'll use 24 instead of 16 bit.

The reasoning in that post is poor. The choice of output format is not logically connected to the fact that most decoders use floating point precision, nor is dither relevant.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #9
Okay, so what would the experts in this forum advice me?

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #10
If you have to ask you should be using 16 bit.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #11
Could you please technically explain why I should use 16 bit?

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #12
because of compatibility problems I need to convert some DTS, DTS-HD HR, AC-3 and E-AC-3 audio streams to ALAC.
The lossy formats are stored as fltp (depth: 32 bit).

I'm a bit confused, a device or software which can play ALAC but not AC-3?

Quote
To preserve all information, should I convert them to s16p-ALAC or better s32p-ALAC (although mediainfo sometimes tells me bit depth of lossy stream is 16 bit).

If you don't want to lose anything the new format should be as close to the old ones as possible. For example in XLD when I chose ALAC, the default setting is to use bit depth and frequency from the source file.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #13
because of compatibility problems I need to convert some DTS, DTS-HD HR, AC-3 and E-AC-3 audio streams to ALAC.
The lossy formats are stored as fltp (depth: 32 bit).

I'm a bit confused, a device or software which can play ALAC but not AC-3?
ATV supports AC-3. But I have more than 500 BluRays and don't want to differentiate. I convert all to ALAC.

To preserve all information, should I convert them to s16p-ALAC or better s32p-ALAC (although mediainfo sometimes tells me bit depth of lossy stream is 16 bit).

If you don't want to lose anything the new format should be as close to the old ones as possible. For example in XLD when I chose ALAC, the default setting is to use bit depth and frequency from the source file.

Lossy audios don't have a bit depth, it is embedded in the meta information. But sometime this information is missing.

I read this: http://duc.avid.com/showthread.php?t=71916
So 24 bit should be the best.
The only disadvantage from 16 bit (if source was 16 bit lossless) is the space.
And with lossy from 24 bit lossless I'm save.

If that's wrong please tell me and explain me why.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #14
Could you please technically explain why I should use 16 bit?

There is no real world difference, so the only reason to use 24 would be if you were doing something unusual, in which case you would know why you needed 24. 

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #15
Just some text from this interesting thread: https://forum.doom9.org/showthread.php?t=145096
Quote
Though you won't get the "original" bits back, AC-3 can store a far greater dynamic range than can be represented in 16-bits.

It can happily store a sound peaking at 0dB FS one moment, and then one of -120dB FS the next. The latter sound would be lost in the dither noise (or rounded / truncated out of existence without dither) with 16-bits.


Just because you don't get the original 24-bits back doesn't mean it can't make some use of 24-bits.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #16
You won't hear -120 dB FS signal anyway.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #17
You won't hear -120 dB FS signal anyway.

You mean -144 dBFS.
And why I won’t hear that?
Okay maybe I‘ll be deaf if I do.

But I don’t think the mastering engineers put such on a BluRay.

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #18
Maybe this would be the best solution:

Convert lossy audio to 24 bit flac.
Check if last 8 bits are used:
If so —> 24-bit ALAC
If not —> 16-bit ALAC

What do you say?


Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #20
You won't hear -120 dB FS signal anyway.

You mean -144 dBFS.
And why I won’t hear that?

Because you don't have a sound system that can produce that dynamic range. 

But 112 db (Sound pressure 86 dB; amplifier 210 W; 2 speaker 2 meter distance).

 

Re: Sample formats: fltp (lossy) to s16p or s32p (ALAC)

Reply #21
You won't hear -120 dB FS signal anyway.

You mean -144 dBFS.
And why I won’t hear that?

Because you don't have a sound system that can produce that dynamic range. 

But 112 db (Sound pressure 86 dB; amplifier 210 W; 2 speaker 2 meter distance).

From context I'm assuming you really mean loudness, and that "112 dB" is probably 112dBSPL. Loudness and dynamic range are different things. If yours speakers go up to 112 dbspl, you probably have something like 80-85dB dynamic range, and can produce something like 14 bits.

 
SimplePortal 1.0.0 RC1 © 2008-2019