Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
gst-plugins-good
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
George Kiagiadakis
gst-plugins-good
Commits
1db7e620
Commit
1db7e620
authored
Jul 01, 2013
by
Wim Taymans
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
rtspsrc: add signal to notify of the SDP
This way, the app can look and modify the SDP.
parent
5d98c9d5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
25 additions
and
0 deletions
+25
-0
gst/rtsp/gstrtspsrc.c
gst/rtsp/gstrtspsrc.c
+25
-0
No files found.
gst/rtsp/gstrtspsrc.c
View file @
1db7e620
...
...
@@ -121,6 +121,7 @@ GST_STATIC_PAD_TEMPLATE ("internalsink_%u",
enum
{
SIGNAL_HANDLE_REQUEST
,
SIGNAL_ON_SDP
,
LAST_SIGNAL
};
...
...
@@ -573,6 +574,27 @@ gst_rtspsrc_class_init (GstRTSPSrcClass * klass)
0
,
NULL
,
NULL
,
g_cclosure_marshal_generic
,
G_TYPE_NONE
,
2
,
G_TYPE_POINTER
,
G_TYPE_POINTER
);
/**
* GstRTSPSrc::on-sdp:
* @rtspsrc: a #GstRTSPSrc
* @sdp: a #GstSDPMessage
*
* Emited when the client has retrieved the SDP and before it configures the
* streams in the SDP. @sdp can be inspected and modified.
*
* This signal is called from the streaming thread, you should therefore not
* do any state changes on @rtspsrc because this might deadlock. If you want
* to modify the state as a result of this signal, post a
* #GST_MESSAGE_REQUEST_STATE message on the bus or signal the main thread
* in some other way.
*
* Since: 1.2
*/
gst_rtspsrc_signals
[
SIGNAL_ON_SDP
]
=
g_signal_new
(
"on-sdp"
,
G_TYPE_FROM_CLASS
(
klass
),
0
,
0
,
NULL
,
NULL
,
g_cclosure_marshal_generic
,
G_TYPE_NONE
,
1
,
GST_TYPE_SDP_MESSAGE
|
G_SIGNAL_TYPE_STATIC_SCOPE
);
gstelement_class
->
send_event
=
gst_rtspsrc_send_event
;
gstelement_class
->
provide_clock
=
gst_rtspsrc_provide_clock
;
gstelement_class
->
change_state
=
gst_rtspsrc_change_state
;
...
...
@@ -5816,6 +5838,9 @@ gst_rtspsrc_open_from_sdp (GstRTSPSrc * src, GstSDPMessage * sdp,
gst_rtsp_ext_list_parse_sdp
(
src
->
extensions
,
sdp
,
src
->
props
);
/* let the app inspect and change the SDP */
g_signal_emit
(
src
,
gst_rtspsrc_signals
[
SIGNAL_ON_SDP
],
0
,
sdp
);
gst_segment_init
(
&
src
->
segment
,
GST_FORMAT_TIME
);
/* parse range for duration reporting. */
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment