diff options
author | Wim Taymans <wim.taymans@gmail.com> | 2007-04-25 09:47:48 +0000 |
---|---|---|
committer | Wim Taymans <wim.taymans@gmail.com> | 2007-04-25 09:47:48 +0000 |
commit | 24c5812d65e45f630edd172ce493ab9fac6df887 (patch) | |
tree | e6e532be7522238565734287de46f875c0a0ac78 /gst/rtp/gstrtpmp2tdepay.c | |
parent | 1beeda3ff2859372cecbea4542a4da8dc05960d6 (diff) |
gst/rtp/: Make sure we configure the clock_rate in the baseclass in the setcaps function. Fixes #431282.
Original commit message from CVS:
* gst/rtp/gstrtpL16depay.c: (gst_rtp_L16_depay_set_property):
* gst/rtp/gstrtpamrdepay.c: (gst_rtp_amr_depay_init),
(gst_rtp_amr_depay_setcaps), (gst_rtp_amr_depay_process):
* gst/rtp/gstrtpgsmdepay.c: (gst_rtp_gsm_depay_init),
(gst_rtp_gsm_depay_setcaps):
* gst/rtp/gstrtph263pdepay.c: (gst_rtp_h263p_depay_setcaps):
* gst/rtp/gstrtph264depay.c: (gst_rtp_h264_depay_setcaps):
* gst/rtp/gstrtpilbcdepay.c: (gst_rtp_ilbc_depay_class_init),
(gst_rtp_ilbc_depay_init), (gst_rtp_ilbc_depay_setcaps),
(gst_rtp_ilbc_depay_process), (gst_ilbc_depay_set_property),
(gst_ilbc_depay_get_property):
* gst/rtp/gstrtpmp2tdepay.c: (gst_rtp_mp2t_depay_setcaps):
* gst/rtp/gstrtpmp4adepay.c:
* gst/rtp/gstrtppcmadepay.c: (gst_rtp_pcma_depay_init),
(gst_rtp_pcma_depay_setcaps):
* gst/rtp/gstrtppcmudepay.c: (gst_rtp_pcmu_depay_init),
(gst_rtp_pcmu_depay_setcaps):
Make sure we configure the clock_rate in the baseclass in the setcaps
function. Fixes #431282.
Diffstat (limited to 'gst/rtp/gstrtpmp2tdepay.c')
-rw-r--r-- | gst/rtp/gstrtpmp2tdepay.c | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/gst/rtp/gstrtpmp2tdepay.c b/gst/rtp/gstrtpmp2tdepay.c index 2f2cdf82..5d77086a 100644 --- a/gst/rtp/gstrtpmp2tdepay.c +++ b/gst/rtp/gstrtpmp2tdepay.c @@ -149,7 +149,7 @@ gst_rtp_mp2t_depay_init (GstRtpMP2TDepay * depayload, static gboolean gst_rtp_mp2t_depay_setcaps (GstBaseRTPDepayload * depayload, GstCaps * caps) { - + GstCaps *srccaps; GstStructure *structure; GstRtpMP2TDepay *rtpmp2tdepay; gint clock_rate = 90000; /* default */ @@ -157,13 +157,15 @@ gst_rtp_mp2t_depay_setcaps (GstBaseRTPDepayload * depayload, GstCaps * caps) rtpmp2tdepay = GST_RTP_MP2T_DEPAY (depayload); structure = gst_caps_get_structure (caps, 0); - - if (gst_structure_has_field (structure, "clock-rate")) { - gst_structure_get_int (structure, "clock-rate", &clock_rate); - } - + gst_structure_get_int (structure, "clock-rate", &clock_rate); depayload->clock_rate = clock_rate; + srccaps = gst_caps_new_simple ("video/mpegts", + "packetsize", G_TYPE_INT, 188, + "systemstream", G_TYPE_BOOLEAN, TRUE, NULL); + gst_pad_set_caps (GST_BASE_RTP_DEPAYLOAD_SRCPAD (depayload), srccaps); + gst_caps_unref (srccaps); + return TRUE; } |