[FFmpeg-devel] [PATCH] lcldec: fix decoding of uncompressed rgb24 sample

Michael Niedermayer michaelni at gmx.at
Fri Nov 2 23:03:50 CET 2012


On Fri, Nov 02, 2012 at 09:51:38PM +0000, Paul B Mahol wrote:
> Sample from ticket #1216 does not use any compression but bitstream
> claims it is. Reference decoder decodes sample just fine.
> 
> Fixes #1216.
> 
> Signed-off-by: Paul B Mahol <onemda at gmail.com>
> ---
>  libavcodec/lcldec.c | 4 +++-
>  1 file changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/libavcodec/lcldec.c b/libavcodec/lcldec.c
> index b3b7b52..66db7c7 100644
> --- a/libavcodec/lcldec.c
> +++ b/libavcodec/lcldec.c
> @@ -198,7 +198,9 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
>      case AV_CODEC_ID_MSZH:
>          switch (c->compression) {
>          case COMP_MSZH:
> -            if (c->flags & FLAG_MULTITHREAD) {
> +            if (c->imgtype == IMGTYPE_RGB24 && len == width * height * 3) {
> +                ;
> +            } else if (c->flags & FLAG_MULTITHREAD) {

if thats what the refernce does then ok of course

[..]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

Let us carefully observe those good qualities wherein our enemies excel us
and endeavor to excel them, by avoiding what is faulty, and imitating what
is excellent in them. -- Plutarch
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20121102/c767775c/attachment.asc>


More information about the ffmpeg-devel mailing list