[FFmpeg-devel] resolved vfwcap with compression type "MJPG"

Nash Tsai nash.tsai
Tue Feb 23 11:32:39 CET 2010


Please check attached diff, my MacBook Pro's WebCam (running dual boot
to Windows) is having biCompression type as "MJPG" and reported an
error, therefore I've tried to fixed it as included diff attachment
and it just worked, would you mind patch it to SVN trunk?

-------------- next part --------------
Index: libavdevice/vfwcap.c
--- libavdevice/vfwcap.c	(revision 21992)
+++ libavdevice/vfwcap.c	(working copy)
@@ -74,6 +74,9 @@
     switch(biCompression) {
     case MKTAG('d', 'v', 's', 'd'):
         return CODEC_ID_DVVIDEO;
+    case MKTAG('M', 'J', 'P', 'G'):
+    case MKTAG('m', 'j', 'p', 'g'):
+        return CODEC_ID_MJPEG;
     return CODEC_ID_NONE;

More information about the ffmpeg-devel mailing list