TooTallNate/node-lame

PCM data as non-interleaved IEEE754 32-bit linear PCM with a nominal range between -1 and +1

Opened this issue · 3 comments

Hi,

Using node-lame, I'd like to be able to get PCM data as non-interleaved IEEE754 32-bit linear PCM with a nominal range between -1 and +1, (in other words 32bits floating point buffer, with each samples between -1.0 and 1.0 - the same used in Web Audio API AudioBuffer).

Is there an easy way to have this representation from the decoder ?

Regards

mdluo commented

A workaround is to use pcm-util to convert the PCM buffer from s16 to f32

mdluo commented

@ouhouhsami

I've forked and implemented setting output format on the decoder:

https://github.com/mdluo/node-addon-mpg123

I will soon submit a PR after some real world testing. See: #86

PR much welcome 👍