diff options
author | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2010-01-16 11:08:16 +0000 |
---|---|---|
committer | Stefano Sabatini <stefano.sabatini-lala@poste.it> | 2010-01-16 11:08:16 +0000 |
commit | 3e906f4cfb15738b4c0cb56bad64531620af4818 (patch) | |
tree | 2ccd902c01f92b3e9594e9fa98c12532befab6f2 /libswscale/swscale.c | |
parent | 006aa1a4c2307209ad11c3ad0ad1d888c8df98fe (diff) | |
download | ffmpeg-3e906f4cfb15738b4c0cb56bad64531620af4818.tar.gz |
Simplify reset_ptr(): employ usePal() macro rather than enumerating
all the paletted formats.
Originally committed as revision 30317 to svn://svn.mplayerhq.hu/mplayer/trunk/libswscale
Diffstat (limited to 'libswscale/swscale.c')
-rw-r--r-- | libswscale/swscale.c | 8 |
1 files changed, 2 insertions, 6 deletions
diff --git a/libswscale/swscale.c b/libswscale/swscale.c index 15071ea218..71786b817a 100644 --- a/libswscale/swscale.c +++ b/libswscale/swscale.c @@ -2935,12 +2935,8 @@ static void reset_ptr(const uint8_t* src[], int format) src[3]=NULL; if(!isPlanarYUV(format)) { src[3]=src[2]=NULL; - if( format != PIX_FMT_PAL8 - && format != PIX_FMT_RGB8 - && format != PIX_FMT_BGR8 - && format != PIX_FMT_RGB4_BYTE - && format != PIX_FMT_BGR4_BYTE - ) + + if (!usePal(format)) src[1]= NULL; } } |