Print error message for unsupported mode (RGB planar,CMYK,YCrCb)
authorKostya Shishkov <kostya.shishkov@gmail.com>
Mon, 13 Nov 2006 11:20:50 +0000 (11:20 +0000)
committerKostya Shishkov <kostya.shishkov@gmail.com>
Mon, 13 Nov 2006 11:20:50 +0000 (11:20 +0000)
Originally committed as revision 7006 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavcodec/tiff.c

index 7d1ea80580ed8f18331101914964499e1f883051..423023cf26b6155a60eeb7bf35fb511c8704f362 100644 (file)
@@ -387,6 +387,12 @@ static int tiff_decode_tag(TiffContext *s, uint8_t *start, uint8_t *buf, uint8_t
         case 1:
             s->invert = 0;
             break;
+        case 2:
+        case 3:
+            break;
+        default:
+            av_log(s->avctx, AV_LOG_ERROR, "Color mode %d is not supported\n", value);
+            return -1;
         }
         break;
     case TIFF_PAL: