# HG changeset patch # User arpi_esp # Date 987384944 0 # Node ID e53a9edbee987be5e32a3253ef0b29faa02b21cc # Parent c7c03bf70bb765b2843b29aa29425513a4e2de39 fixed yuvhack diff -r c7c03bf70bb7 -r e53a9edbee98 dll_init.c --- a/dll_init.c Mon Apr 16 01:26:08 2001 +0000 +++ b/dll_init.c Mon Apr 16 01:35:44 2001 +0000 @@ -146,6 +146,7 @@ case IMGFMT_I420: case IMGFMT_IYUV: sh_video->o_bih.biBitCount=12; + break; /* packed format */ case IMGFMT_YUY2: @@ -188,11 +189,8 @@ sh_video->o_bih.biHeight=-sh_video->bih->biHeight; // flip image! } - // this looks suspicious :-) - if(!(outfmt == IMGFMT_YUY2 && (sh_video->codec->outflags[sh_video->outfmtidx] & CODECS_FLAG_YUVHACK)) - && (outfmt & IMGFMT_RGB_MASK) != IMGFMT_RGB && (outfmt & IMGFMT_BGR_MASK ) != IMGFMT_BGR) { + if(!(sh_video->codec->outflags[sh_video->outfmtidx] & CODECS_FLAG_YUVHACK)) sh_video->o_bih.biCompression = outfmt; - } if(verbose) { printf("Starting decompression, format:\n"); @@ -246,7 +244,7 @@ return 0; } - if(outfmt==IMGFMT_YUY2 && (sh_video->codec->outflags[sh_video->outfmtidx]&CODECS_FLAG_YUVHACK)) + if(sh_video->codec->outflags[sh_video->outfmtidx] & CODECS_FLAG_YUVHACK) sh_video->o_bih.biCompression = mmioFOURCC('Y','U','Y','2'); // avi_header.our_in_buffer=malloc(avi_header.video.dwSuggestedBufferSize); // FIXME!!!!