Skip to content

Seems to be cutting binary words in two. #31

Description

@joelle-o-world

Sometimes when decoding a wav file stream (32-bit Float PCM little endian) I find I'm getting Buffers which have a length (in bytes) that is not a multiple of four. I don't understand why this is happening as 32 bit floats are each 4 bytes long.

I've tried ignoring these chunks and I have also tried cutting off the remainder bytes and prepending them to the next chunk. Either way I get very strange results further down the pipe-line, sometimes an entire file appears to be silent.

Note: I am first using fluent-ffmpeg to transcode mp3's into WAV format (as a stream), then using this library to strip the wav headers. Afterwards I use Float32Array's to view the PCM data for each audio chunk. Hence how I have noticed the bug.

I have now found I can use FFMPEG to strip the wav headers, which solves the problem. But I thought I should also flag it here.

All best,
Joel

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions