| OLD | NEW |
| 1 /* | 1 /* |
| 2 * VFW capture interface | 2 * VFW capture interface |
| 3 * Copyright (c) 2006-2008 Ramiro Polla | 3 * Copyright (c) 2006-2008 Ramiro Polla |
| 4 * | 4 * |
| 5 * This file is part of FFmpeg. | 5 * This file is part of FFmpeg. |
| 6 * | 6 * |
| 7 * FFmpeg is free software; you can redistribute it and/or | 7 * FFmpeg is free software; you can redistribute it and/or |
| 8 * modify it under the terms of the GNU Lesser General Public | 8 * modify it under the terms of the GNU Lesser General Public |
| 9 * License as published by the Free Software Foundation; either | 9 * License as published by the Free Software Foundation; either |
| 10 * version 2.1 of the License, or (at your option) any later version. | 10 * version 2.1 of the License, or (at your option) any later version. |
| (...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 67 } | 67 } |
| 68 } | 68 } |
| 69 return PIX_FMT_NONE; | 69 return PIX_FMT_NONE; |
| 70 } | 70 } |
| 71 | 71 |
| 72 static enum CodecID vfw_codecid(DWORD biCompression) | 72 static enum CodecID vfw_codecid(DWORD biCompression) |
| 73 { | 73 { |
| 74 switch(biCompression) { | 74 switch(biCompression) { |
| 75 case MKTAG('d', 'v', 's', 'd'): | 75 case MKTAG('d', 'v', 's', 'd'): |
| 76 return CODEC_ID_DVVIDEO; | 76 return CODEC_ID_DVVIDEO; |
| 77 case MKTAG('M', 'J', 'P', 'G'): |
| 78 case MKTAG('m', 'j', 'p', 'g'): |
| 79 return CODEC_ID_MJPEG; |
| 77 } | 80 } |
| 78 return CODEC_ID_NONE; | 81 return CODEC_ID_NONE; |
| 79 } | 82 } |
| 80 | 83 |
| 81 #define dstruct(pctx, sname, var, type) \ | 84 #define dstruct(pctx, sname, var, type) \ |
| 82 av_log(pctx, AV_LOG_DEBUG, #var":\t%"type"\n", sname->var) | 85 av_log(pctx, AV_LOG_DEBUG, #var":\t%"type"\n", sname->var) |
| 83 | 86 |
| 84 static void dump_captureparms(AVFormatContext *s, CAPTUREPARMS *cparms) | 87 static void dump_captureparms(AVFormatContext *s, CAPTUREPARMS *cparms) |
| 85 { | 88 { |
| 86 av_log(s, AV_LOG_DEBUG, "CAPTUREPARMS\n"); | 89 av_log(s, AV_LOG_DEBUG, "CAPTUREPARMS\n"); |
| (...skipping 333 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 420 AVInputFormat vfwcap_demuxer = { | 423 AVInputFormat vfwcap_demuxer = { |
| 421 "vfwcap", | 424 "vfwcap", |
| 422 NULL_IF_CONFIG_SMALL("VFW video capture"), | 425 NULL_IF_CONFIG_SMALL("VFW video capture"), |
| 423 sizeof(struct vfw_ctx), | 426 sizeof(struct vfw_ctx), |
| 424 NULL, | 427 NULL, |
| 425 vfw_read_header, | 428 vfw_read_header, |
| 426 vfw_read_packet, | 429 vfw_read_packet, |
| 427 vfw_read_close, | 430 vfw_read_close, |
| 428 .flags = AVFMT_NOFILE, | 431 .flags = AVFMT_NOFILE, |
| 429 }; | 432 }; |
| OLD | NEW |