[FFmpeg-cvslog] lavc/imgconvert: remove pointless switch block from avpicture_fill()

Stefano Sabatini git at videolan.org
Tue Jun 19 01:47:14 CEST 2012


ffmpeg | branch: master | Stefano Sabatini <stefasab at gmail.com> | Sat Jun 16 11:35:38 2012 +0200| [0b2ecf8224cf882033737541cf3bd615dd414625] | committer: Stefano Sabatini

lavc/imgconvert: remove pointless switch block from avpicture_fill()

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=0b2ecf8224cf882033737541cf3bd615dd414625
---

 libavcodec/imgconvert.c |   10 ----------
 1 file changed, 10 deletions(-)

diff --git a/libavcodec/imgconvert.c b/libavcodec/imgconvert.c
index 3111418..495a1d0 100644
--- a/libavcodec/imgconvert.c
+++ b/libavcodec/imgconvert.c
@@ -334,16 +334,6 @@ int avpicture_layout(const AVPicture* src, enum PixelFormat pix_fmt, int width,
         }
     }
 
-    switch (pix_fmt) {
-    case PIX_FMT_RGB8:
-    case PIX_FMT_BGR8:
-    case PIX_FMT_RGB4_BYTE:
-    case PIX_FMT_BGR4_BYTE:
-    case PIX_FMT_GRAY8:
-        // do not include palette for these pseudo-paletted formats
-        return size;
-    }
-
     if (desc->flags & PIX_FMT_PAL) {
         uint32_t *d32 = (unsigned char *)(((size_t)dest + 3) & ~3);
         for (i = 0; i<256; i++)



More information about the ffmpeg-cvslog mailing list