[FFmpeg-devel] [PATCH 06/10 rev2] spdifenc: fix byte order on big-endian systems

Reimar Döffinger Reimar.Doeffinger
Sat Jan 1 10:38:59 CET 2011

On 1 jan 2011, at 06:38, Anssi Hannula <anssi.hannula at iki.fi> wrote:

> The preamble and final odd byte were outputted in the wrong byte order
> on big-endian systems.
> ---
> I'm wondering if this patch would be a better choice. All our audio
> decoders output native-endian samples. As this muxer is usually used in
> place of an encoder, it would be logical for it to have its output in
> native-endian as well.
> However, this would cause (AFAIK) the muxer to be the only one that has
> different output depending on system endianness.. Don't know if that is
> very big an issue, though.

It is completely unacceptable, it makes it untestable.
You could create two muxers, one for each endianness, which is a good idea since AFAIK e.g. OSX expects the big-endian format even on x86.
If you really want you can also add a third one that outputs in native endianness, it's not a big issue if we don't/can't (easily) test that one.

More information about the ffmpeg-devel mailing list