Commit graph

476 commits

Author SHA1 Message Date
Linus Svensson
398296d978 rtspsrc: Don't include payload type in the caps for framesize
When the sdp media attribute framesize are converted to caps
the <payload> should not be included.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=725335
2015-03-09 10:18:35 +01:00
Sebastian Dröge
c34a7cb90d rtspsrc: Fix handling of interleaved (TCP) streams
We need to set up the transport in any case, not just if we have a container
stream or a non-interleaved stream. Only if we have an interleaved stream and
are retrying, we should not set up the stream again.

https://bugzilla.gnome.org/show_bug.cgi?id=745599
2015-03-05 12:15:04 +01:00
Sebastian Dröge
b4aaa11f97 rtspsrc: Don't unref caps we don't own 2015-03-05 09:56:37 +01:00
Sebastian Dröge
297d808acc rtspsrc: Push RTCP caps on the RTCP pads
Otherwise we will get not-negotiated later from rtpbin, and will never be able
to send RTCP packets back to the server. Note that error flow returns from the
RTCP pads are ignored, that's why it didn't fail more visible before.
2015-03-05 09:47:29 +01:00
Sebastian Dröge
788074733c rtspsrc: Make sure to send SEGMENT events on all pads 2015-03-05 09:47:29 +01:00
Krzysztof Kotlenga
e3ca4d1c86 rtspsrc: improve error message when unauthorized
Make use of NOT_AUTHORIZED error code instead of falling back to generic
READ error.

https://bugzilla.gnome.org/show_bug.cgi?id=601733
2015-02-24 11:08:27 +02:00
Tim-Philipp Müller
603c1d71a1 rtspsrc: fix awkward if clause 2015-02-08 12:03:10 +00:00
Wim Taymans
852c040c89 rtspsrc: fix container handling
We detect a container correctly now so we need to revert the weird
check there was before.
Use gst_rtspsrc_stream_push_event() to push the caps event on the
right pad.

See https://bugzilla.gnome.org/show_bug.cgi?id=739391
2015-02-03 17:39:10 +01:00
Sebastian Dröge
d5aab81a77 Constify some static arrays everywhere 2015-01-21 09:55:53 +01:00
Aleix Conchillo Flaqué
07c5d1820a rtspsrc: set PLAYING state after configuring caps
We set to PLAYING after we have configured the caps, otherwise we
might end up calling request_key (with SRTP) while caps are still
being configured, ending in a crash.

https://bugzilla.gnome.org/show_bug.cgi?id=740505
2014-12-31 12:49:11 +00:00
Sebastian Dröge
d18b893d28 rtspsrc: Don't dereference NULL if a suitable stream for the AUX element can't be found
CID 1258717
2014-12-18 11:51:12 +01:00
Sebastian Dröge
6b2fc2de8d rtspsrc: Add something to the debug logs if an RTX AUX element can't be added
... because the application already has a signal handler set up here.
2014-12-16 16:40:08 +01:00
Matthew Waters
bf0a19bf02 rtspsrc: add retransmission support according to RFC4588
Based on the client-rtpaux example
2014-12-16 16:40:08 +01:00
Aleix Conchillo Flaqué
00ca83629b rtspsrc: fix leak for mikey base64 decoded key-mgmt
https://bugzilla.gnome.org/show_bug.cgi?id=740392
2014-11-20 09:15:56 +01:00
Aleix Conchillo Flaqué
d15ebcbf62 rtspsrc: mikey related memory leaks
https://bugzilla.gnome.org/show_bug.cgi?id=739430
2014-10-31 10:03:47 +00:00
Aleix Conchillo Flaqué
bd392d72ee rtspsrc: set full stream caps on internal src TCP pads
Set the complete stream caps on the TCP internal src pads. Otherwise,
ptdemux will not properly detect the caps change.

https://bugzilla.gnome.org/show_bug.cgi?id=737868
2014-10-21 11:33:01 +02:00
Sebastian Dröge
d1c7f2e4d1 rtspsrc: Fix compiler warnings
gstrtspsrc.c:7939:11: error: implicit conversion from enumeration type 'GstSDPResult' to different enumeration type
      'GstRTSPResult' [-Werror,-Wenum-conversion]
    res = gst_sdp_message_new (&sdp);
        ~ ^~~~~~~~~~~~~~~~~~~~~~~~~~
gstrtspsrc.c:7944:11: error: implicit conversion from enumeration type 'GstSDPResult' to different enumeration type
      'GstRTSPResult' [-Werror,-Wenum-conversion]
    res = gst_sdp_message_parse_uri (uri, sdp);
        ~ ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2014-09-26 13:46:16 +03:00
Sanjay NM
f62076e49c rtsp: clarify expression so operator precedence is clear
https://bugzilla.gnome.org/show_bug.cgi?id=736903
2014-09-24 00:48:09 +01:00
Sebastian Dröge
add40de469 rtspsrc: Push the correct segment in TCP mode when seeking 2014-08-05 16:28:04 +02:00
Tim-Philipp Müller
c2614e5253 rtspsrc: fix query leak
https://bugzilla.gnome.org/show_bug.cgi?id=733003
2014-07-10 17:19:42 +01:00
Wim Taymans
db1d9444d6 rtspsrc: fix for mikey api change 2014-07-02 16:01:47 +02:00
Wim Taymans
98a4ee0f92 rtspsrc: pass the stream id when asking for crypto params
This way the app can choose different parameters for each stream.
2014-06-19 16:17:23 +02:00
Aleix Conchillo Flaqué
7ce0ea3946 rtspsrc: add support for key length parameters
This patch adds supports for the incoming key management parameters for
encryption and authentication key lengths.

It also adds a new signal request-rtcp-key that allows the user to
provide the crypto parameters and key for the RTCP stream.

https://bugzilla.gnome.org/show_bug.cgi?id=730473
2014-06-19 16:11:19 +02:00
Aleix Conchillo Flaqué
782d65cab1 rtspsrc: always use a random ssrc for the internal session
Use a random SSRC different than 0 for the internal session SSRC.

https://bugzilla.gnome.org/show_bug.cgi?id=730212
2014-05-16 16:58:44 +02:00
Vincent Penquerc'h
a846e84349 rtspsrc: remove duplicate test
item was dereference previously.

While there, reorder some test for faster early out.

Coverity 1139844
2014-05-02 14:06:25 +01:00
Tim-Philipp Müller
c9597298f9 docs: remove outdated and pointless 'Last reviewed' lines from docs
They are very confusing for people, and more often than not
also just not very accurate. Seeing 'last reviewed: 2005' in
your docs is not very confidence-inspiring. Let's just remove
those comments.
2014-04-26 23:35:17 +01:00
Wim Taymans
5b9945e0a6 rtspsrc: update for new MIKEY API 2014-04-04 17:38:14 +02:00
Wim Taymans
6210cbe1e2 rtspsrc: send sender SSRC in the MIKEY message
Allocate a new SSRC for our RTCP messages back to the server and set
this in the MIKEY message.
2014-04-03 17:40:01 +02:00
Wim Taymans
4f641ef18b rtspsrc: make random number for the CSB
As recommended in the RFC
2014-04-03 17:39:30 +02:00
Wim Taymans
f932da3be6 rtspsrc: don't put spaces in keymgmt header 2014-04-03 12:21:27 +02:00
Wim Taymans
2edd450369 rtspsrc: create and send the RTCP encryption key
Create and make a key for encrypting the RTCP packets back to the server
and wrap this in a MIKEY message that we send as a header in the SETUP
request.
2014-04-03 12:21:27 +02:00
Wim Taymans
a52b7eadfd rtspsrc: free the srtpdec element 2014-04-03 12:18:39 +02:00
Wim Taymans
f0f9451523 rtspsrc: cleanup stream_free function
There is no reason to NULL all fields, we will free the stream anyway.
2014-04-03 12:16:25 +02:00
Wim Taymans
e7c8fa1127 rtspsrc: only expose streams on dataflow
Only probe on buffers, we don't want to expose the streams on events.
2014-03-25 11:44:27 +01:00
Wim Taymans
3b497bf7d5 rtspsrc: copy sticky events to ghostpad
When we expose internal pads as ghostpads, first copy the sticky events
so that we have the caps and segment etc.

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=724712
2014-03-25 11:36:40 +01:00
Wim Taymans
67f3113759 rtspsrc: srtp handling 2014-03-25 10:23:24 +01:00
Wim Taymans
4846be1491 rtspsrc: set SSRC on caps if known 2014-03-25 10:23:00 +01:00
Wim Taymans
5ec8c96966 rtspsrc: put caps on udpsrc instead of using the signals
Try to avoid using the request-pt-map to get caps but set them directly
on the udpsrc element. That way, the caps get nicely transformed as they
pass through the different elements in the rtpbin, including the AUX and
decoder/encoder elements.
2014-03-24 17:07:06 +01:00
Wim Taymans
2b59828e0b rtspsrc: use profile to set rtcp caps
Use the negotiated profile to set x-rtcp or x-srtcp caps
2014-03-24 15:35:09 +01:00
Wim Taymans
a7b55d7687 rtspsrc: set udpsrc to READY
READY is enough to allocate ports now
2014-03-24 15:34:26 +01:00
Wim Taymans
a4f6f963ec rtspsrc: free caps in ptmap array
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=726696
2014-03-24 14:35:01 +01:00
Wim Taymans
d6c5fbc87c rtspsrc: handle NULL rtpmap and parse error better 2014-03-20 11:12:51 +01:00
Wim Taymans
224239096d rtspsrc: skip streams with same control url
Keep track of what streams we did the SETUP for. We only need to
configure caps, wait for pads and push events on setup streams. We can
remove the disabled state of the stream and simplify some checks.
After we setup a stream, skip the other streams that have the same
control url. Use a skipped flag to mark streams that should be skipped.
2014-03-06 12:30:54 +01:00
Wim Taymans
3b27fc2f0f rtspsrc: remove obsolete code 2014-03-06 12:30:54 +01:00
Wim Taymans
27d883fe64 rtspsrc: just use the SDP index as the stream id
Use the index of the media stream in the SDP as the stream id instead of
keeping a separate counter.
2014-03-06 12:30:54 +01:00
Wim Taymans
99a9d2873c rtspsrc: handle NULL control urls better 2014-03-05 15:44:25 +01:00
Alessandro Decina
c4bf6e8b7e rtspsrc: fix seeking
Call gst_rtspsrc_connection_flush (src, FALSE) to reset connections as
non-flushing before sending PAUSE and PLAY with the new npt range. Without this
patch, those commands would fail with EINTR as the connections were still
flushing.
2014-03-05 11:39:09 +01:00
Wim Taymans
70de0e4e99 rtspsrc: Add support for multiple payload types
A media stream can have multiple payload types. Parse all the payload
types and collect the caps information. We then have to store the
pt<->caps mapping instead of 1 pt and 1 caps.
Parse the profile from the SDP and use that to negotiate the transport
instead of always using AVP.
Rework how we do some tweaks for ASF and Realmedia.
2014-03-04 16:40:34 +01:00
Wim Taymans
dbe92c9147 rtspsrc: refactor payload handling 2014-03-04 11:34:39 +01:00
Santiago Carot-Nemesio
b9a953161f rtspsrc: Fix deadlock when task creation is no successful
https://bugzilla.gnome.org/show_bug.cgi?id=725124
2014-02-25 10:10:31 +01:00