GST_DEBUG_CATEGORY_EXTERN (sdl_debug);
#define GST_CAT_DEFAULT sdl_debug
-/* These macros are adapted from videotestsrc.c
+/* These macros are adapted from videotestsrc.c
* and/or gst-plugins/gst/games/gstvideoimage.c */
#define I420_Y_ROWSTRIDE(width) (GST_ROUND_UP_4(width))
#define I420_U_ROWSTRIDE(width) (GST_ROUND_UP_8(width)/2)
"Ronald Bultje <rbultje@ronald.bitfreak.net>, "
"Edgard Lima <edgard.lima@indt.org.br>, "
"Jan Schmidt <thaytan@mad.scientist.com>");
+ gst_caps_unref(capslist);
}
static void
return result;
}
-/* SDL Video sink and X overlay:
+/* SDL Video sink and X overlay:
*
* SDL supports creating an Xv window/overlay within an existing X window
* through the horrible mechanism of setting the WINDOWID environment
* that information. The only way to get it would be to do what X[v]imagesink
* does and retrieve it using X11 calls, and linking to Xlib. That would
* defeat the whole purpose of using the SDL abstraction and plugin entirely
- * however.
+ * however.
*
* I have no nice solution to this problem for you, dear readers.
*/
* For each stream listed in the SDP a new stream_\%u pad will be created
* with caps derived from the SDP media description. This is a caps of mime type
* "application/x-rtp" that can be connected to any available RTP depayloader
- * element.
- *
+ * element.
+ *
* sdpdemux will internally instantiate an RTP session manager element
* that will handle the RTCP messages to and from the server, jitter removal,
- * packet reordering along with providing a clock for the pipeline.
- *
- * sdpdemux acts like a live element and will therefore only generate data in the
+ * packet reordering along with providing a clock for the pipeline.
+ *
+ * sdpdemux acts like a live element and will therefore only generate data in the
* PLAYING state.
- *
+ *
* <refsect2>
* <title>Example launch line</title>
* |[
/*
* Mapping of caps to and from SDP fields:
*
- * m=<media> <UDP port> RTP/AVP <payload>
+ * m=<media> <UDP port> RTP/AVP <payload>
* a=rtpmap:<payload> <encoding_name>/<clock_rate>[/<encoding_params>]
* a=fmtp:<payload> <param>[=<value>];...
*/
/* not very fatal, we just won't be able to send RTCP */
GST_WARNING_OBJECT (demux, "could not get session RTCP pad");
}
-
+ gst_object_unref(pad);
return TRUE;
{&CLSID_CWMVDecMediaObject, &DMOCATEGORY_VIDEO_DECODER}, {0}
};
-static const GUID CLSID_AVI_DECOMPRESSOR =
- {0xCF49D4E0, 0x1115, 0x11CE,
+static const GUID CLSID_AVI_DECOMPRESSOR =
+ {0xCF49D4E0, 0x1115, 0x11CE,
{0xB0, 0x3A, 0x00, 0x20, 0xAF, 0x0B, 0xA7, 0x70}};
static PreferredFilter preferred_cinepack_filters[] = {
{&CLSID_AVI_DECOMPRESSOR}, {0}
static PreferredFilter preferred_mp43_filters[] = {
{&CLSID_CMpeg43DecMediaObject, &DMOCATEGORY_VIDEO_DECODER}, {0}};
-static const GUID CLSID_MPEG_VIDEO_DECODER =
- {0xFEB50740, 0x7BEF, 0x11CE,
+static const GUID CLSID_MPEG_VIDEO_DECODER =
+ {0xFEB50740, 0x7BEF, 0x11CE,
{0x9B, 0xD9, 0x00, 0x00, 0xE2, 0x02, 0x59, 0x9C}};
static PreferredFilter preferred_mpeg1_filters[] = {
{&CLSID_MPEG_VIDEO_DECODER}, {0}
GUID_MEDIATYPE_VIDEO, GUID_MEDIASUBTYPE_YUY2,
GST_VIDEO_CAPS_MAKE("YUY2"),
preferred_mpeg1_filters},
-
+
{"dshowvdec_mpeg4", "MPEG-4 Video",
GST_MAKE_FOURCC ('M', 'P', 'G', '4'),
GUID_MEDIATYPE_VIDEO, GUID_MEDIASUBTYPE_MPG4,
gst_buffer_map(buf, &map, GST_MAP_WRITE);
if (strstr (klass->entry->srccaps, "rgb")) {
- /* FOR RGB directshow decoder will return bottom-up BITMAP
+ /* FOR RGB directshow decoder will return bottom-up BITMAP
* There is probably a way to get top-bottom video frames from
* the decoder...
*/
description = g_strdup_printf ("DirectShow %s Decoder Wrapper",
tmp->element_longname);
- gst_element_class_set_metadata(element_class, longname, "Codec/Decoder/Video", description,
+ gst_element_class_set_metadata(element_class, longname, "Codec/Decoder/Video", description,
"Sebastien Moutte <sebastien@moutte.net>");
g_free (longname);
gst_element_class_add_pad_template (element_class, src);
gst_element_class_add_pad_template (element_class, sink);
+
+ gst_caps_unref(sinkcaps);
+ gst_caps_unref(srccaps);
}
static void
"framerate", GST_TYPE_FRACTION, vdec->fps_n, vdec->fps_d, NULL);
}
- gst_caps_set_simple (caps_out,
+ gst_caps_set_simple (caps_out,
"pixel-aspect-ratio", GST_TYPE_FRACTION, vdec->par_n, vdec->par_d, NULL);
if (!gst_pad_set_caps (vdec->srcpad, caps_out)) {
enum_mediatypes->Reset();
while (hres =
enum_mediatypes->Next(1, &mediatype, &fetched),
- hres == S_OK)
+ hres == S_OK)
{
VIDEOINFOHEADER *video_info;
GstCaps *mediacaps = NULL;
enum_mediatypes->Reset();
while (hres =
enum_mediatypes->Next(1, &mediatype, &fetched),
- hres == S_OK)
+ hres == S_OK)
{
if (IsEqualGUID (mediatype->subtype, subtype) &&
IsEqualGUID (mediatype->formattype, FORMAT_VideoInfo))