[gst-devel] patch rtp
Jim Thornton
jthornton at parc.com
Fri Mar 22 18:50:02 CET 2002
Fixes:
- L16 is supposed to be 44100 not 8000 by RTP params, if mono then should
be 1 channel
- mediatype is a string not a pointer
- ARG_SOCKET_CLOSED not handled
- capsnego props match for range 1000-48000 isn't matching 44100 for some
reason, so set template rate to exactly 44100 to get raw_audio to work for
now
- missing break on ARG_MTU
--- gstrtp-common.c.orig Tue Mar 19 13:48:43 2002
+++ gstrtp-common.c Tue Mar 19 14:10:37 2002
@@ -399,8 +399,8 @@
"signed", GST_PROPS_BOOLEAN (TRUE),
"width", GST_PROPS_INT (16),
"depth", GST_PROPS_INT (16),
- "rate", GST_PROPS_INT (8000),
- "channels", GST_PROPS_INT (2));
+ "rate", GST_PROPS_INT (44100),
+ "channels", GST_PROPS_INT (1));
}
return caps;
--- gstrtprecv.c.orig Mon Mar 18 10:42:45 2002
+++ gstrtprecv.c Tue Mar 19 15:52:27 2002
@@ -74,7 +74,8 @@
"signed", GST_PROPS_BOOLEAN (TRUE),
"width", GST_PROPS_INT (16),
"depth", GST_PROPS_INT (16),
- "rate", GST_PROPS_INT_RANGE (1000, 48000),
+ /* "rate", GST_PROPS_INT_RANGE (1000, 48000),*/
+ "rate", GST_PROPS_INT (44100),
"channels", GST_PROPS_INT (1))
)
@@ -244,7 +245,7 @@
/* wtay: add something suitable here */
break;
case ARG_MEDIA_TYPE:
- caps = mediatype_to_caps (g_value_get_pointer (value),
+ caps = mediatype_to_caps (g_value_get_string (value),
&rtprecv->payload_type, &rtprecv->mtu);
if( caps != NULL ) {
gst_pad_try_set_caps (rtprecv->srcpad, caps);
@@ -275,9 +276,12 @@
case ARG_CAPS:
g_value_set_pointer (value, gst_pad_get_caps (rtprecv->srcpad));
break;
+ case ARG_SOCKET_CLOSED:
+ /* jdt: add something suitable here */
+ break;
case ARG_MEDIA_TYPE:
media_type = caps_to_mediatype (gst_pad_get_caps
(rtprecv->srcpad));
- g_value_set_pointer (value, media_type);
+ g_value_set_string (value, media_type);
break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
--- gstrtpsend.c.orig Mon Mar 18 10:27:07 2002
+++ gstrtpsend.c Tue Mar 19 15:26:18 2002
@@ -394,10 +394,11 @@
break;
case ARG_MEDIA_TYPE:
media_type = caps_to_mediatype (gst_pad_get_caps
(rtpsend->sinkpad));
- g_value_set_pointer (value, media_type);
+ g_value_set_string (value, media_type);
break;
case ARG_MTU:
g_value_set_int (value, rtpsend->mtu);
+ break;
default:
G_OBJECT_WARN_INVALID_PROPERTY_ID (object, prop_id, pspec);
break;
More information about the gstreamer-devel
mailing list