[FFmpeg-devel] [PATCH 04/10] use native zlib decoder for cscd

Reimar Döffinger Reimar.Doeffinger
Thu Jul 19 00:02:21 CEST 2007


Hello,
On Sun, Jul 15, 2007 at 09:12:24PM +0100, Mans Rullgard wrote:
[...]
> @@ -163,15 +160,11 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size,
>              break;
>          }
>          case 1: { // zlib compression
> -#ifdef CONFIG_ZLIB
> -            unsigned long dlen = c->decomp_size;
> -            if (uncompress(c->decomp_buf, &dlen, &buf[2], buf_size - 2) != Z_OK)
> +            unsigned int dlen = c->decomp_size;
> +
> +            if (av_inflate_single(c->decomp_buf, &dlen, buf+2, buf_size-2) < 0)

Ok by me, though as you probably remember from our IRC discussion I am
not sure if this API or the one lzo uses is more sane.
In case someone has a good reason to prefer one I wouldn't mind hearing
it, changing one so both use the same would be somewhat nice, though
probably not quite as useful as I initially though.

Greetings,
Reimar D?ffinger




More information about the ffmpeg-devel mailing list