ext/ffmpeg/gstffmpegcodecmap.c: Change caps of MJPEGB to not interfere with MJPEG/JPEG.

Original commit message from CVS:
* ext/ffmpeg/gstffmpegcodecmap.c: (gst_ffmpeg_codecid_to_caps),
(gst_ffmpeg_caps_to_codecid):
Change caps of MJPEGB to not interfere with MJPEG/JPEG.
* ext/ffmpeg/gstffmpegdec.c: (gst_ffmpegdec_register):
Remove rank for SP5X, no clue what that is...
This commit is contained in:
Ronald S. Bultje 2005-02-03 11:12:34 +00:00
parent 385671eb80
commit 1b6e6aee2d
3 changed files with 19 additions and 1 deletions

View file

@ -1,3 +1,11 @@
2005-02-02 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
* ext/ffmpeg/gstffmpegcodecmap.c: (gst_ffmpeg_codecid_to_caps),
(gst_ffmpeg_caps_to_codecid):
Change caps of MJPEGB to not interfere with MJPEG/JPEG.
* ext/ffmpeg/gstffmpegdec.c: (gst_ffmpegdec_register):
Remove rank for SP5X, no clue what that is...
2005-02-01 Ronald S. Bultje <rbultje@ronald.bitfreak.net> 2005-02-01 Ronald S. Bultje <rbultje@ronald.bitfreak.net>
* ext/ffmpeg/gstffmpegdec.c: (gst_ffmpegdec_frame): * ext/ffmpeg/gstffmpegdec.c: (gst_ffmpegdec_frame):

View file

@ -242,12 +242,15 @@ gst_ffmpeg_codecid_to_caps (enum CodecID codec_id,
* between those in GStreamer. Should we (at least between MJPEG, * between those in GStreamer. Should we (at least between MJPEG,
* MJPEG-B and sp5x decoding...)? */ * MJPEG-B and sp5x decoding...)? */
case CODEC_ID_MJPEG: case CODEC_ID_MJPEG:
case CODEC_ID_MJPEGB:
case CODEC_ID_LJPEG: case CODEC_ID_LJPEG:
case CODEC_ID_SP5X: case CODEC_ID_SP5X:
caps = GST_FF_VID_CAPS_NEW ("image/jpeg", NULL); caps = GST_FF_VID_CAPS_NEW ("image/jpeg", NULL);
break; break;
case CODEC_ID_MJPEGB:
caps = GST_FF_VID_CAPS_NEW ("video/x-mjpeg-b", NULL);
break;
case CODEC_ID_MPEG4: case CODEC_ID_MPEG4:
if (encode && context != NULL) { if (encode && context != NULL) {
/* I'm not exactly sure what ffmpeg outputs... ffmpeg itself uses /* I'm not exactly sure what ffmpeg outputs... ffmpeg itself uses
@ -1437,6 +1440,9 @@ gst_ffmpeg_caps_to_codecid (const GstCaps * caps, AVCodecContext * context)
} else if (!strcmp (mimetype, "image/jpeg")) { } else if (!strcmp (mimetype, "image/jpeg")) {
id = CODEC_ID_MJPEG; /* A... B... */ id = CODEC_ID_MJPEG; /* A... B... */
video = TRUE; video = TRUE;
} else if (!strcmp (mimetype, "video/x-jpeg-b")) {
id = CODEC_ID_MJPEGB;
video = TRUE;
} else if (!strcmp (mimetype, "video/x-wmv")) { } else if (!strcmp (mimetype, "video/x-wmv")) {
gint wmvversion = 0; gint wmvversion = 0;

View file

@ -1058,6 +1058,10 @@ gst_ffmpegdec_register (GstPlugin * plugin)
default: default:
rank = GST_RANK_MARGINAL; rank = GST_RANK_MARGINAL;
break; break;
/* what's that? */
case CODEC_ID_SP5X:
rank = GST_RANK_NONE;
break;
} }
if (!gst_element_register (plugin, type_name, rank, type)) { if (!gst_element_register (plugin, type_name, rank, type)) {
g_free (type_name); g_free (type_name);