Commit graph

8184 commits

Author SHA1 Message Date
Sangkyu Park 6696bd62ef rtpjitterbuffer: Minor cleanup
1. Add Null check in 'free_item' function.
2. Fix a typing error of comment.

https://bugzilla.gnome.org/show_bug.cgi?id=750965
2015-06-15 11:55:57 +02:00
Nicolas Dufresne 717265ebfb flmux: Make sure best_time is initialized 2015-06-12 17:45:23 -04:00
Sebastian Dröge dc513eb949 rtpbin/session: Add new ntp-time-source property and deprecate use-pipeline-clock property
The new property allows to select the time source that should be used for the
NTP time in RTCP packets. By default it will continue to calculate the NTP
timestamp (1900 epoch) based on the realtime clock. Alternatively it can use
the UNIX timestamp (1970 epoch), the pipeline's running time or the pipeline's
clock time. The latter is especially useful for synchronizing multiple
receivers if all of them share the same clock.

If use-pipeline-clock is set to TRUE, it will override the ntp-time-source
setting and continue to use the running time plus 70 years. This is only kept
for backwards compatibility.
2015-06-12 23:35:42 +02:00
Nicolas Dufresne 135e516730 qtdemux: Adjust segment according to ctts offset
In presence of a CTTS, the segment start/stop must be offset so
the segment start/stop include the PTS. This is needed since the
PTS cannot be negative in this format. This fixes issues where the
running time of the first buffer isn't at the start.

https://bugzilla.gnome.org/show_bug.cgi?id=740575
2015-06-12 17:18:24 -04:00
Nicolas Dufresne 12181efddc qtmux: Handle DTS with negative running time
As QT works with duration, simply bring back first DTS to 0 and shift
forward the PTS of the same amount.

https://bugzilla.gnome.org/show_bug.cgi?id=740575
2015-06-12 17:18:24 -04:00
Nicolas Dufresne 2274ca7d07 flvmux: Add negative runtime DTS support
This is done by using new feature of the CollectPad clip function
which sets the DTS as a gint64 in the collected data. It also simplify
the code a bit.

https://bugzilla.gnome.org/show_bug.cgi?id=740575
2015-06-12 17:18:24 -04:00
Sebastian Dröge 37e3ca1447 rtpbin: Rename some variables and debug output to make more sense
Local and remote were mixed up in a few places, and the time we store here is
not UNIX time (1970 epoch), but NTP time (1900 epoch) in nanoseconds.
2015-06-12 23:07:27 +02:00
Jan Schmidt 0c46c5c3e2 matroska-demux: Actually set detected 3D info into output caps.
Use the information read from the StereoMode info
to configure multiview-mode and multiview-flags in the
video caps.
2015-06-12 01:57:36 +10:00
Jan Schmidt 3f39d06338 splitmuxsink: Take released-but-not-yet-output bytes into account
When deciding whether it's time to switch to a new file, take into
account data that's been released for pushing, but hasn't yet
been pushed - because downstream is slow or the threads haven't been
scheduled.

Fixes a race in the unit test and probably in practice - sometimes
failing to switch when it should for an extra GOP or two.

Also fix a problem in splitmuxsrc where playback sometimes
stalls at startup if types are found too quickly.

https://bugzilla.gnome.org/show_bug.cgi?id=750747
2015-06-12 01:57:36 +10:00
Thiago Santos 03f1a2ea67 atoms: remove custom gst_buffer_new function in favor of core version
Remove a custom specialized version of gst_buffer_new_wrapped by
using gst_buffer_new_wrapped_full inside a macro to simplify
parameters and give it a more meaningful name.
It is only used to create temporary buffers to have its data copied.
2015-06-11 01:11:31 -03:00
Thiago Santos 1596972674 atoms: simplify free form data atoms creation
Avoid creating an intermediary buffer or memory area just
to copy into an atom's data area.
2015-06-11 01:11:31 -03:00
Thiago Santos ab18f5035c qtmux: add AC-3 muxing support
Adds AC-3 muxing support. It is defined for mp4 and 3gp formats.

One extra feature that was added was the ability to add extension
atoms after set_caps as the AC-3 extension atom needs some data
that has to be extracted from the stream itself and is not
present on caps.
2015-06-11 01:11:31 -03:00
Thiago Santos 674e0cc2df qtmux: remove unused type MP4S 2015-06-11 01:11:31 -03:00
Thiago Santos f83fd7a88f qtmux: remove duplicate attribute value set
It is also set a few lines below
2015-06-11 01:11:18 -03:00
Jan Schmidt ec5bc9dccb matroska: Implement basic stereoscopic video support
Implement support for the packed video formats WebM
uses, not all the values that Matroska might use.

In practice, it's really hard to find any samples in the
wild of any.

Supported in both the muxer and demuxer.
2015-06-11 12:11:42 +10:00
Jan Schmidt fff76157d8 qtdemux: Add basic support for MPEG-A stereoscopic video
The MPEG-A format provides an extension to the ISO base media
file format to store stereoscopic content encoded with different
codecs like H.264 and MPEG-4:2. The stereo video media information(svmi)
atom declares the presence and storage method for the video.

Stereo video information for MPEG-A can also be supplied through
the 'stvi' atom (ref: ISO/IEC_14496-12, ISO/IEC_23000-11), which
is not implemented in this patch.

Also missing is support for stereo video encoded as separate video tracks
for now.

Based on a patch by Sreerenj Balachandran <sreerenj.balachandran@intel.com>

https://bugzilla.gnome.org/show_bug.cgi?id=611157
2015-06-11 12:11:42 +10:00
Sebastian Dröge dc059efa60 rtp: Use GST_BUFFER_PTS() instead of GST_BUFFER_TIMESTAMP()
The mix between all these in the RTP code is confusing, let's try to be
consistent.
2015-06-10 14:34:47 +02:00
Ilya Konstantinov c7e168ec70 rtpmanager: clarify negative lost packets in stats
Also:
- Move notes on units before field documentation.
- Unify documentation style.

https://bugzilla.gnome.org/show_bug.cgi?id=750653
2015-06-10 14:10:52 +02:00
Vineeth TM 720ff75c72 qtdemux: fix reverse playback
When performing seek, segment->start is being updated with desired_offset,
but in case of reverse playback segment->start should be 0 and
segment->stop should be updated with desired offset.

https://bugzilla.gnome.org/show_bug.cgi?id=750675
2015-06-10 10:41:13 +02:00
Xavier Claessens b0b3e8e2cc rtspsrc: Add a GTlsInteraction property
It can be used for TLS client authentication.

https://bugzilla.gnome.org/show_bug.cgi?id=750471
2015-06-09 20:03:18 -04:00
Ilya Konstantinov 0a578c235a rtpmanager: document units of stats and arguments
Also, minor spelling and style corrections.

https://bugzilla.gnome.org/show_bug.cgi?id=750653
2015-06-09 18:21:59 +02:00
Luis de Bethencourt e56ef6bcf0 goom: possible uninitialized variables warning
Build fails with the latest snapshot of gcc-4.9 because param1 and param2 might
possibly be used uninitialized. They are set depending on the cases of a switch
statement and the compiler sees this as not a complete guarantee.
Set them to 0 if the switch statement falls down to the default case.

https://bugzilla.gnome.org/show_bug.cgi?id=750566#c6
2015-06-08 23:06:39 +01:00
Chris Clayton e29f231e5d rtpvp8depay: potential access beyond end of array
Compiling (with gcc-4.9-20150603) produces an error because of an access beyond
the end of an array. This patch fixes the error by initializing the loop
control/array index variable (i) to 1 and returning i - 1 when a match is found.
Also, because the values stored in the array increase in value as the index
increases, the >= test unnecessary, so it is removed.
2015-06-08 20:16:20 +01:00
Jan Schmidt d78502deb1 splitmuxsink: Don't accumulate more than 2 GOPs
Don't allow large amounts of data to queue up - we only need
the GOP we're writing, and the GOP we're accumulating.
2015-06-08 18:58:43 +10:00
Jan Schmidt 23d610140d isomp4: fsync after sending updates in robust mode
Use the new GstBuffer SYNC_AFTER flag to trigger an fsync
after updating the moov or mdat atom, and after updating the free
atom to make it visible.
2015-06-08 14:49:11 +10:00
Jan Schmidt 3e17cd8acb isomp4: Only set moov header into streamheader at EOS
Only update the moov header into the caps if it's the finalised
moov at EOS time. Avoids posting a bogus moov at startup and
repeated updates in robust-recording mode
2015-06-08 14:49:11 +10:00
Jan Schmidt 1d058c7d8a isomp4: Implement robust muxing using ping-pong strategy
Implement a robust recording mode, where the output
file is always in a playable state, seeking and rewriting
the moov header at a configurable interval. Rewriting
moov is done using reserved space at the start of
the file, and a ping-pong strategy where the moov
is replaced atomically so it's never invalid.

Track when tags have actually changed, and don't write them into
the moov unless they've changed. Clear any existing tags when
re-writing them, so we can do progressive moov updating in robust
recording mode.

Write placeholder mdat as a free atom plus a 32-bit mdat
with '0' size, which means "rest of the file" in the spec.

Re-write it later to a full 64-bit extended size atom if needed.
2015-06-08 14:49:11 +10:00
Jan Schmidt 3d7b343525 isomp4: Update edit list when re-writing moov
Correctly update any edit lists each time the moov is recalculated,
updating existing table entries if they already exist instead of just
adding new ones.
2015-06-08 14:16:36 +10:00
Jan Schmidt 0c1bcc629d isomp4: Remove an extra bracket in a comment. 2015-06-08 14:16:36 +10:00
Jan Schmidt 94e113c6c6 splitmuxsrc: Protect total_duration state variable with the object lock.
Prevent deadlocks from downstream querying duration from the streaming thread.
2015-06-08 14:16:36 +10:00
Luis de Bethencourt 0b8c7ab797 goom: clean dereferences of private structure
https://bugzilla.gnome.org/show_bug.cgi?id=742875
2015-06-07 19:24:20 +01:00
Luis de Bethencourt fce8e5fb26 goom2k1: clean dereferences of private structure
https://bugzilla.gnome.org/show_bug.cgi?id=742875
2015-06-07 19:20:49 +01:00
Sebastian Dröge a7faa3e0a2 Release 1.5.1 2015-06-07 10:46:34 +02:00
Sebastian Dröge b549ebd066 rtpsession: Override the SSRC from the packets' SSRC if none was given via caps or property 2015-06-07 10:33:27 +02:00
Sebastian Dröge d650a310da rtpsession: Only suggest our internal ssrc if it's not a random one and was selected as internal ssrc
https://bugzilla.gnome.org/show_bug.cgi?id=749581
2015-06-05 16:45:54 +02:00
Vineeth TM 0e5631c5c0 interleave: error when channel-positions-from-input=False
self->channels is being incremented only when
channel-positions-from-input is set as TRUE. So in case of FALSE
self->func is not set and hence creating assertion error.
Hence removing the condition to increment self->channels.

https://bugzilla.gnome.org/show_bug.cgi?id=744211
2015-06-05 08:48:25 -03:00
Sebastian Dröge 8f5bdf9690 rtpjitterbuffer: Add support for receiving reduced size RTCP
It worked before but gave warnings, now we just ignore RTCP
packets that don't start with a SR. As all we're interested
in here are SRs.
2015-06-05 10:33:11 +02:00
Jose Antonio Santos Cadenas f563176349 rtpssrcdemux: Add support for reduce size rtcp
According to RFC 5506, reduce size packages can be sent, this
packages may not be compound, so we need to add support for
getting ssrc from other types of packages.

https://bugzilla.gnome.org/show_bug.cgi?id=750327
2015-06-05 10:30:15 +02:00
Jose Antonio Santos Cadenas f8f23bbf5d rtpsession: Add support for receiving reduced size rtcp
See RFC 5506

https://bugzilla.gnome.org/show_bug.cgi?id=750332
2015-06-05 10:24:17 +02:00
Sebastian Dröge ec82eba96b aacparse: Add support for channel configurations 11, 12 and 14 and 7 actually has 8 channels
ISO/IEC 14496-3:2009/PDAM 4 added 11, 12 and 14.
2015-06-04 16:09:41 +02:00
Nicolas Dufresne 3ab70e4677 asteriskh263: Un-rank clashing depayloader
This depayloader clash with the standard one for H263p. It produces an
H263p stream with a modified header. It uses encoding-name that is the
same as H263p (H263-1998) though the resulting ES is not decodable or
parsable in GStreamer, making it unsuable in dynamic pipeline. This
patch unrank this specialized depayloader since it can only be used in
custom pipeline.

https://bugzilla.gnome.org/show_bug.cgi?id=739935
2015-06-03 08:57:57 -04:00
Luis de Bethencourt ffe7507512 goom2k1: remove variables not needed anymore
https://bugzilla.gnome.org/show_bug.cgi?id=742875
2015-06-02 18:09:48 +01:00
Luis de Bethencourt 8756b6a9d4 goom2k1: rebase to use the audiovisualizer class
Rebase to have goom2k1 using the common GstAudioVisualizer class

https://bugzilla.gnome.org/show_bug.cgi?id=742875
2015-06-02 18:02:08 +01:00
Luis de Bethencourt 89903bf66a goom: rebase to use the audiovisualizer class 2015-06-02 17:47:57 +01:00
Sebastian Dröge 647eefea67 rtpsession: Only schedule a timer when we actually have to send RTCP
Otherwise we will have 10s-100s of thread wakeups in feedback profiles, create
RTCP packets, etc. just to suppress them in 99% of the cases (i.e. if no
feedback is actually pending and no regular RTCP has to be sent).

This improves CPU usage and battery life quite a lot.

https://bugzilla.gnome.org/show_bug.cgi?id=746543
2015-06-02 11:38:15 +02:00
Sebastian Dröge 8ada98964d rtpsession: Remove useless goto
https://bugzilla.gnome.org/show_bug.cgi?id=746543
2015-06-02 11:38:15 +02:00
Sebastian Dröge 0a7823b30f rtspsrc: Set RTP profile on the rtpsession objects
https://bugzilla.gnome.org/show_bug.cgi?id=746543
2015-06-02 11:38:15 +02:00
Sebastian Dröge 506a8a8857 rtpbin: Add rtp-profile property for setting the default profile of newly created sessions
https://bugzilla.gnome.org/show_bug.cgi?id=746543
2015-06-02 11:38:15 +02:00
Sebastian Dröge 0f7e80ed59 rtpsession: Only put RRs and full SDES into regular RTCP packets
If we may suppress the packet due to the rules of RFC4585 (i.e. when
below the t-rr-int), we can send a smaller RTCP packet without RRs
and full SDES. In theory we could even send a minimal RTCP packet
according to RFC5506, but we don't support that yet.

https://bugzilla.gnome.org/show_bug.cgi?id=746543
2015-06-02 11:38:15 +02:00
Sebastian Dröge 6f830e5bd5 rtpsession: Keep track of tp/tn and t_rr_last separately
Otherwise we can't properly schedule RTCP in feedback profiles as we need to
distinguish the time when we last checked for sending RTCP (tp) but might have
suppressed it, and the time when we last actually sent a non-early RTCP
packet.

This together with the other changes should now properly implement RTCP
scheduling according to RFC4585, and especially allow us to send feedback
packets a lot if needed but only send regular RTCP packets every once in a
while.

https://bugzilla.gnome.org/show_bug.cgi?id=746543
2015-06-02 11:38:15 +02:00