Commit graph

7447 commits

Author SHA1 Message Date
Mathieu Duponchelle
da6afdec9c doc: remove xml from comments 2019-05-29 22:58:08 +02:00
Mathieu Duponchelle
102b1346e7 doc: fix element section documentations
Element sections were not rendered anymore after the hotdoc
port, fixing this revealed a few incorrect links.
2019-05-25 16:58:13 +02:00
Sebastian Dröge
1c712ca555 avwait: Protect properties and some other code with the mutex
These variables are all accessed from multiple threads.

Also fix some minor leaks in error code paths.
2019-05-24 10:41:35 +00:00
Sebastian Dröge
d55dda6252 avwait: Insert some empty lines to give the code some space to breath 2019-05-24 10:41:35 +00:00
Sebastian Dröge
c8876a37ba avwait: Allow setting start timecode after end timecode and the other way around
This might be necessary temporarily for changing the previous settings.
Make it an actual error if the settings are like this while processing a
buffer.
2019-05-24 10:41:35 +00:00
Sebastian Dröge
ab9d42cc7f proxy: Forward queries/events sent directly to the element correctly 2019-05-22 07:48:33 +00:00
Sebastian Dröge
70b08bdbfa proxy: Set SOURCE flag on the source and SINK flag on the sink
So that they are properly recognized as such.
2019-05-22 07:48:33 +00:00
Haihao Xiang
7820109b88 ivfparse: Check the data size against IVF_FRAME_HEADER_SIZE
It is parsing frame data and so should check the data size against the
frame header size instead of the file header size. If don't, it is
possible to drop the last frame because IVF_FILE_HEADER_SIZE is greater
than IVF_FRAME_HEADER_SIZE
2019-05-22 12:37:29 +08:00
Nicolas Dufresne
98acb3260d rist: Add combined bonding-method support
This patchs add support for configuring the bonding method used. There is
two method specified

 - redundant: All the RTP packets are replicated
 - combined: RTP packet are evenly distributed over each links

Additionally, an application can set the "dispatcher" property in order
to implement custom dispatching method. Whenever the "dispatcher"
property is set, "bonding-method" property will be ignored.
2019-05-21 18:49:17 +00:00
Nicolas Dufresne
9a443c04bc ristsrc: Implement per session stats
As we can now have multiple sessions, stats need to be implemented per
session. This follow RTPSession model with sources. The stats are now:

    dropped: 0
    received: 0
    recovered: 0
    permanently-lost: 0
    duplicates: 0
    retransmission-requests-sent: 0
    rtx-roundtrip-time: 0
    session-stats:
        session-id=0
            rtp-from=""
            rtcp-from=""
            dropped=0
            received=0
        session-id=1
            rtp-from=""
            rtcp-from=""
            dropped=0
            received=0
        . . .

session-stats is a GValueArray as there is no better alternatives.
2019-05-21 18:49:17 +00:00
Nicolas Dufresne
0c26aaa614 ristsrc: Cleanup unused include 2019-05-21 18:49:17 +00:00
Nicolas Dufresne
73edff67c7 ristsink: Implement per session stats
As we can now have multiple sessions, stats need to be implemented per
session. This follow RTPSession model with sources. The stats are now:

  sent-original-packets: 0
  sent-retransmitted-packets: 0
       session-stats:
            session-id=0
              sent-original-packets=0
              sent-retransmitted-packets=0
              round-trip-time=0
            session-id=1
              sent-original-packets=0
              sent-retransmitted-packets=0
              round-trip-time=0
            . . .

session-stats is a GValueArray as there is no better alternatives.
2019-05-21 18:49:17 +00:00
Nicolas Dufresne
4bba95ead2 ristsrc: rtxbin may be null in finalize 2019-05-21 18:49:17 +00:00
Nicolas Dufresne
e914abd402 ristsrc: Add bonding support
This add support for receiving and aggregating the same stream
over multiple addresses.
2019-05-21 18:49:17 +00:00
Nicolas Dufresne
ffedd7ce2d ristsink: Implement bonding support 2019-05-21 18:49:17 +00:00
Marc Leeman
ca36d70538 rist: spell and grammar corrects in top comments 2019-05-21 18:49:02 +00:00
Thibault Saunier
397f3afd19 docs: Update cache and mark some rist prop as 'show-default' 2019-05-21 13:31:52 +00:00
Thibault Saunier
601233c9ad doc: Add proxysink/proxysrc 2019-05-21 13:31:52 +00:00
Seungha Yang
1e3eb00b17 mpegtsmux: Fix build warning error
gstmpegtsmux.c:291:3: error: implicit declaration of function ‘memmove’ [-Werror=implicit-function-declaration]
   memmove (map.data + 4, map.data, map.size - 4);
   ^
gstmpegtsmux.c:291:3: error: incompatible implicit declaration of built-in function ‘memmove’ [-Werror]
gstmpegtsmux.c:291:3: note: include ‘<string.h>’ or provide a declaration of ‘memmove’
2019-05-20 19:34:37 +09:00
Mathieu Duponchelle
54cb25456d basetsmux: improve bitrate property documentation 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
9190541e3c tsmux: refactor logic for when to (re)transmit tables
In order to output them at regular intervals in the bitstream
when a bitrate is specified.
2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
52efb62876 basetsmux: fix PCR stream selection 2019-05-19 19:40:48 +00:00
Jan Schmidt
1ff72bb69d Fix compile after aggregator rewrite and base class refactor 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
3c7c08e7c4 tsmux: fix continuity counter for packets with no payload 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
a1cadd11b8 mpegtsmux: aggregator port 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
a57f4dc8d9 mpegtsmux: spring cleanup, no functional change 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
44c701d113 basetsmux: extract m2ts-mode to mpegtsmux 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
649cc2d5e8 mpegtsmux: extract an actual base class 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
4e7f94f5fa mpegtsmux: expose the vmethods necessary for ATSC E-AC-3 handling 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
ea011a3266 mpegtsmux: provide API for subclasses to override stream creation 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
80bfa16c95 mpegtsmux: add an ATSC subclass 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
98c98c7c53 tsmux: Calculate PCR from number of bytes written in CBR mode 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
07235bbf46 mpegtsmux: Expose bitrate property
This allows outputting a Transport Stream with a constant bitrate,
by inserting null packets.
2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
4d53a7ac09 tsmux: actually respect the PCR frequency we target 2019-05-19 19:40:48 +00:00
Mathieu Duponchelle
dc2b28d456 tsmux: Use DTS over PTS 2019-05-19 19:40:48 +00:00
Olivier Crête
beba12e97b rist: Fix typo 2019-05-17 17:15:13 -04:00
Thibault Saunier
e19700c458 docs: Add gstrist to the documentation 2019-05-16 09:16:34 -04:00
Thibault Saunier
8917c62f93 docs: Make sure frei0r plugins properties default are stable
frei0r returns 'random' values as default and it makes the cache
often change for no good reason
2019-05-14 10:47:19 -04:00
Thibault Saunier
47a49f3381 docs: Build documentation with hotdoc 2019-05-13 17:00:00 -04:00
Thibault Saunier
7fe3f36ac8 Minor documentation fixes 2019-05-13 11:36:27 -04:00
Seungha Yang
a24367132b h265parse: Parse mastering display info and content light level from SEI
... and set to caps if necessary.

Note 1) the mastering display info and content light level SEI meessages
are persistent in the corresponding codec video sequence (i.e., GOP).
So any bitstream containing those SEI messages
(and also all pictures are intended to be HDR rendered) should be ensured that
each first slice of codec video sequence follows those SEI messages.

Note 2) The codec video sequence is a group an [IRAP + NoRaslOutputFlag == 1]
and following AUs which are not [IRAP + NoRaslOutputFlag == 1]
The NoRaslOutputFlag is equal to 1 for each IDR AU, BLA AU and some CRA AU.
For a CRA AU to have NoRaslOutputFlag equal to 1, following condition should required.
* When the CRA AU is the first AU in the bitstream in decoding order
* or the CRA AU is the first AU that follows an end of sequence NAL in decoding order
* or the HandleCraAsBlaFlag equal to 1.

Due to the limited context in parse element, in this commint, CRA AU will not considered as
having the NoRaslOutputFlag equal to 1. Therefore, in the worst case,
mastering-display-info and content-light-level could be cleared one GOP after
when stream was chagned from HDR to SDR.
2019-05-03 19:44:15 +00:00
Nicolas Dufresne
f0d04b39dd rist: Add a plugin implenting RIST TR-06-1 Simple Profile
RIST TR-06-1 is a specification for video streaming made by the VSF
group. It is using a subset of RTP specification to which some
modification has been made to improve RTX behaviour and avoid any need
for signaling. The plugin implement ristrtxsend / ristrtxreceive element
which are the RIST specific equivalent of rtprtxsend/rtprtxreceive and
ristsink / ristsrc which implement rist transmitter and receiver. The
RIST protocol is meant to be used in unidirectional way. Typically, MPEG
TS over RTP is used.

Currently we support unicast and multicast streaming according to the
specification. This patch does not include any bonding support yet. The
ristsrc element introduce rist:// URI handling in parallel to it's
property configuration interface.
2019-05-02 19:28:25 +00:00
Xavier Claessens
63562d0b0a h264parse: Fix typo when setting multiview mode and flags 2019-05-02 12:06:36 +00:00
Tim-Philipp Müller
76f1ed15fb h264parse: extract CEA-708 closed captions
Expose SEI data in the H.264 bitstream parser API and
extract closed captions and other things that are not
specified in the H.264 spec itself in the videoparser.

Based on patch by: Mathieu Duponchelle <mathieu@centricular.com>

https://gitlab.freedesktop.org/gstreamer/gst-plugins-bad/issues/940
2019-04-08 19:21:34 +01:00
Mathieu Duponchelle
f11ce297f4 rtponviftimestamp: prioritize PTS over DTS for NTP timestamp
NTP timestamps are supposed to match the expected presentation
time, prefering the DTS to compute them was incorrect.

<https://www.onvif.org/specs/stream/ONVIF-Streaming-Spec.pdf>

Section 6.3.1: NTP Timestamps
2019-04-05 00:28:48 +00:00
Mathieu Duponchelle
62b240eb4e rtponviftimestamp: buffer without PTS or DTS is not an error.
For example, when plugged after rtpgstpay, serialized events will
have neither.
2019-04-05 00:28:48 +00:00
Mathieu Duponchelle
9c3816830c rtponviftimestamp: implement support for the T flag
https://www.onvif.org/specs/stream/ONVIF-Streaming-Spec.pdf

6.3 RTP header extension
2019-04-05 00:28:48 +00:00
Mathieu Duponchelle
0e89f2a6d9 h264parse, h265parse: take unit_field_based_flag into account ..
when computing timecode metas. Depending on the value of that flag,
n_frames is to be interpreted as a number of fields or a number of
frames. As GstVideoTimeCodeMeta always deals with frames, we want
to scale that number when needed.
2019-04-02 15:18:03 +02:00
Mathieu Duponchelle
55bb8966e1 h265parse: forward time codes
This transforms time code SEIs into GstVideoTimeCodeMeta
2019-04-01 10:02:33 +00:00
Mathieu Duponchelle
7c425cf339 h264parse: forward time codes
This transforms time codes from the timing SEI into
GstVideoTimeCodeMeta
2019-04-01 10:02:33 +00:00