[FFmpeg-devel] [PATCH] Electronic Arts TQI decoder

Reimar Döffinger Reimar.Doeffinger
Sun Jan 25 15:49:06 CET 2009

On Sun, Jan 25, 2009 at 11:06:25PM +1100, Peter Ross wrote:
> bitstream-ea32.diff -- yet another bitstream packing technique.

Personally I strongly dislike those special-case bitstreams, esp. since
this one is not particularly fast.
Personally, I'd be in favour of swapping everything in the demuxer, but
I can understand that this is somewhat ugly.
So I'd say please use the same method as mpc7.c:
> bits = av_malloc(((buf_size - 1) & ~3) + FF_INPUT_BUFFER_PADDING_SIZE);
> c->dsp.bswap_buf((uint32_t*)bits, (const uint32_t*)(buf + 4), (buf_size - 4) >> 2);

and the normal bitstream reader. Not that example drops the first for
bytes, you'd have to adjust for that.

Reimar D?ffinger

More information about the ffmpeg-devel mailing list