Commit graph

19449 commits

Author SHA1 Message Date
Edward Hervey
69867f95e2 adaptivedemux: Actually wait for playlist update when requested
There are several cases where a HLS server could temporarily have wrong
fragments, or reconfigure the playlist. In those cases, when we get
fragment download failures, we *really* want to wait a bit (for the next
playlist update) before retrying to get fragments.

Previously this method was first checking to see if there was next fragments
(according to the previous manifest update) before waiting for the next update.
The problem was that if that if there is a temporary failure on the server,
that's uncorrelated to whether the manifest contains next fragments or not.
2015-08-15 19:04:42 +02:00
Edward Hervey
c90f6b990b checks: Ensure thread-safe libX11/GL when running tests 2015-08-15 19:04:42 +02:00
Thiago Santos
56b822f9f6 audiodecoders: use default pad accept-caps handling
Avoids useless check of downstream caps when handling an
accept-caps query

Elements: dtsdec, faad, gsmdec, mpg123audiodec, opusdec,
          sbcdec, adpcmdec, sirendec
2015-08-15 13:51:16 -03:00
Thiago Santos
a5ed877783 videodecoders: use default pad accept-caps handling
Avoids useless check of downstream caps when handling an
accept-caps query

Elements: daaladec, libde265dec, openjpegdec, rsvgdec, schrodec,
          webpdec, pnmdec, vmncdec, openexrdec
2015-08-15 13:51:16 -03:00
Luis de Bethencourt
51dfa3b135 rtph265depay: make sure we call handle_nal for each NAL
Call handle_nal for each NAL in the STAP-A RTP packet. This makes sure
we correctly extract the SPS and PPS.

https://bugzilla.gnome.org/show_bug.cgi?id=730999
2015-08-15 16:22:22 +01:00
Nicolas Dufresne
e6bd7d2792 gloverlaycompositor: Also disable the blend when done 2015-08-15 15:55:08 +02:00
Nicolas Dufresne
f935b2c547 glsink: Enable sync meta on pools we offer
As the upload is asynchronous, we need to enable the sync meta to
gain correct rendering. The buffer pool receiver don't know about
that.
2015-08-15 15:55:08 +02:00
Nicolas Dufresne
74486ab7e1 gtkglsink: Add overlay composition support
Rendering composition overlay in GL with additional high resolution
overlay being added.
2015-08-15 15:55:08 +02:00
Nicolas Dufresne
0b271a863e gtkglsink: Fix unsafe handling of buffer life time
We need to keep the active buffer (the one we have retreive a
texture id from) otherwise it's racy and upstream may upload
new content before we have rendered or during later redisplay.
2015-08-15 15:55:08 +02:00
Nicolas Dufresne
e4cc364a14 gtkglsink: Remove reset path
The reset path is bogus and there is no reason to get rid of these
things during resize.
2015-08-15 15:55:08 +02:00
Nicolas Dufresne
ea484fb968 glimagesink: Move overlay rendering after video rendering
This is mostly cosmetic, but heoretically it reduces the amount of
required object in the context at one point. It also avoids potential
conflicts.
2015-08-15 15:55:08 +02:00
Luis de Bethencourt
4075b1112c rtph265pay: Copy metadata in the payloader, but only the relevant ones
The payloader didn't copy anything so far, the depayloader copied every
possible meta. Let's make it consistent and just copy all metas without
tags or with only the video tag.

https://bugzilla.gnome.org/show_bug.cgi?id=751774
2015-08-15 14:45:37 +01:00
Luis de Bethencourt
5b2ddfb90c rtph265pay: Use GST_WARNING_OBJECT() instead of GST_WARNING()
https://bugzilla.gnome.org/show_bug.cgi?id=753228
2015-08-15 11:41:43 +01:00
Luis de Bethencourt
585e042fca rtph265pay: fix potential crash when shutting down
A race condition in the state change function may cause buffers to be
unreffed while they are still used by the streaming thread in
gst_rtp_h265_pay_send_vps_sps_pps() resulting in a crash. Chain up to the
parent class first in the state change function to make sure streaming
has stopped and only then free those buffers.

https://bugzilla.gnome.org/show_bug.cgi?id=741381
2015-08-15 11:34:31 +01:00
Sebastian Dröge
f4a76139db opengl: Change GLclampd to double
GLclampd does not exist on GLES, only desktop GL.
2015-08-15 10:03:07 +02:00
Martin Kelly
591b2e2c68 opengl: add missing ClearDepth prototype
The ClearDepth call is missing.

https://bugzilla.gnome.org/show_bug.cgi?id=753639
2015-08-15 09:28:12 +02:00
Jan Schmidt
fdac09d843 h264parse: Clear SPS info after processing.
The SPS struct might be filled out by a call to
gst_h264_parser_parse_subset_sps, which fills out
dynamically allocated data and requires a call
to gst_h264_sps_clear() to free it. Also make sure
to clear out any allocated SPS data when returning
an error.

https://bugzilla.gnome.org/show_bug.cgi?id=753306
2015-08-15 15:39:23 +10:00
Vanessa Chipirrás Navalón
7a2f5d6b03 facedetect: Refactor the code
Some lines of code are repeated several times, therefore
this lines are simplified with a inline function, that this is
proper style of C++.
2015-08-14 18:28:43 +01:00
Thiago Santos
8f855a8b78 pngparse: enable accept-intersect and accept-template flags on sinkpad
Do a quick check with the pad template caps as it is enough. Users
should have figured the appropriate full caps on a previous caps query

https://bugzilla.gnome.org/show_bug.cgi?id=753623
2015-08-14 13:42:59 -03:00
Thiago Santos
c4cd1ce4fd videoparsers: enable accept-template flag
Do a quick check with the pad template caps as it is enough. Users
should have figured the appropriate full caps on a previous caps query

https://bugzilla.gnome.org/show_bug.cgi?id=753623
2015-08-14 13:42:59 -03:00
Luis de Bethencourt
b3418759d9 rtph265pay: fix buffer leak when using SPS/PPS
Fixes a buffer leak that would occur if the pipeline was shutdown while a
SPS/PPS header was being created.

https://bugzilla.gnome.org/show_bug.cgi?id=741271
2015-08-14 15:08:10 +01:00
Luis de Bethencourt
fd665514ba rtph265depay: copy metadata in the depayloader, but only the relevant ones
The payloader didn't copy anything so far, the depayloader copied every
possible meta. Let's make it consistent and just copy all metas without
tags or with only the video tag.

https://bugzilla.gnome.org/show_bug.cgi?id=751774
2015-08-14 12:00:23 +01:00
Alex Ashley
93edd99bf7 dashdemux: add support for HTTP HEAD method of time sync
The urn:mpeg:dash:utc:http-head:2014 method of time synchronisation
uses an HTTP HEAD request to a specified URL and then parses the
Date: HTTP response header.

This commit adds support to dashdemux for this method of time
synchronisation by making a HEAD request and then parsing the Date:
response.

This commit adds support to gstfragment to return the HTTP headers
and to uridownloader to support HEAD requests. To avoid creating a
new API, the RANGE get function is re-used (abused?) with start=-1
and end=-1 to indicate a HEAD request.

https://bugzilla.gnome.org/show_bug.cgi?id=752413
2015-08-14 06:47:21 -03:00
Alex Ashley
1640ee2b33 dashdemux: post-review fixup of UTCTiming element
This commit addresses the following items from the code review:
    use a portable way to define NTP_TO_UNIX_EPOCH,
    fix memory leak on error, and
    add documentation to UTCTiming parse functions

Using LL is not portable, so the G_GUINT64_CONSTANT needs to be instead.

If an error occurs during DNS resolution, the GError was not being
released, causing a memory leak.

https://bugzilla.gnome.org/show_bug.cgi?id=752413
2015-08-14 06:47:20 -03:00
Alex Ashley
95c705ae8f dashdemux: add support for UTCTiming elements for clock drift compensation
Unless the DASH client can compensate for the difference between its
clock and the clock used by the server, the client might request
fragments that either not yet on the server or fragments that have
already been expired from the server. This is an issue because these
requests can propagate all the way back to the origin

ISO/IEC 23009-1:2014/Amd 1 [PDAM1] defines a new UTCTiming element to allow
a DASH client to track the clock used by the server generating the
DASH stream. Multiple UTCTiming elements might be present, to indicate
support for multiple methods of UTC time gathering. Each element can
contain a white space separated list of URLs that can be contacted
to discover the UTC time from the server's perspective.

This commit provides parsing of UTCTiming elements, unit tests of this
parsing and a function to poll a time server. This function
supports the following methods:
    urn:mpeg:dash:utc:ntp:2014
    urn:mpeg:dash:utc:http-xsdate:2014
    urn:mpeg:dash:utc:http-iso:2014
    urn:mpeg:dash:utc:http-ntp:2014

The manifest update task is used to poll the clock time server,
to save having to create a new thread.

When choosing the starting fragment number and when waiting for a
fragment to become available, the difference between the server's idea
of UTC and the client's idea of UTC is taken into account. For example,
if the server's time is behind the client's idea of UTC, we wait for
longer before requesting a fragment

[PDAM1]: http://www.iso.org/iso/home/store/catalogue_tc/catalogue_detail.htm?csnumber=66068

dashdemux: support NTP time servers in UTCTiming elements

Use the gst_ntp_clock to support the use of an NTP server.

https://bugzilla.gnome.org/show_bug.cgi?id=752413
2015-08-14 06:47:20 -03:00
Edward Hervey
a7444ad850 check: Rename states unit test
Makes it easier to differentiate from other modules states unit test
2015-08-14 11:13:59 +02:00
Vineeth TM
6fb346717b spu-pgs: fix buffer and event leak
When playing mts files with embedded subtitles, the buffer is mapped,
but not unmapped at the end resulting in a memory leak.

Also unref event in handle_dvd_event as it takes ownership of the event.

https://bugzilla.gnome.org/show_bug.cgi?id=753539
2015-08-13 14:56:00 +01:00
Vineeth TM
0812437293 dvdspu: Fix event leaks
When playing mts files with embedded subtitles, there are few event leaks.
Events are supposed to be transfer full. So if not forwarding the event,
they need to be freed.

https://bugzilla.gnome.org/show_bug.cgi?id=753539
2015-08-13 14:38:03 +01:00
Sebastian Dröge
88f85f6595 Revert "srtpdec: Add support for buffer list"
This reverts commit ff11a1a8a0.

It can't be assumed that all buffers in a buffer list have the same SSRC or
are RTP or RTCP only. It has to be checked for every single buffer, and one
basically has to do the processing that is done by the default chain_list
implementation.
2015-08-13 12:40:14 +02:00
Luis de Bethencourt
397b5d06ec rtph265depay: checking if depay has sps/pps nals before insertion
Related to: https://bugzilla.gnome.org/show_bug.cgi?id=753430

https://bugzilla.gnome.org/show_bug.cgi?id=753228
2015-08-12 17:54:55 +01:00
Luis de Bethencourt
ef9b7ef60a rtph265depay: only update the srcpad caps if something else than the codec_data changed
h264parse and gstrtph264depay do the same, let's keep the behaviour
consistent. As we now include the codec_data inside the stream, this causes
less caps renegotiation.

https://bugzilla.gnome.org/show_bug.cgi?id=753228
2015-08-12 17:22:44 +01:00
Luis de Bethencourt
4edf2ac1c5 rtph265depay: PPS replaces old PPS if it has the same id
https://bugzilla.gnome.org/show_bug.cgi?id=753228
2015-08-12 16:51:18 +01:00
Luis de Bethencourt
021333a9fc rtph265depay: Insert SPS/PPS NALs into the stream
rtph264depay does the same and this fixes decoding of some streams with 32
SPS (or 256 PPS). It is allowed to have SPS ID 0 to 31 (or PPS ID 0 to 255),
but the field in the codec_data for the number of SPS or PPS is only 5
(or 8) bit. As such, 32 SPS (or 256 PPS) are interpreted as 0 everywhere.

This looks like a mistake in the part of the spect about the codec_data.
2015-08-12 16:34:43 +01:00
Luis de Bethencourt
fee3129d49 rtph265depay: implement process_rtp_packet() vfunc
For more optimised RTP packet handling: means we don't need to map the
input buffer again but can just re-use the mapping the base class has
already done.

Based on: https://bugzilla.gnome.org/show_bug.cgi?id=750235

https://bugzilla.gnome.org/show_bug.cgi?id=753228
2015-08-12 15:53:23 +01:00
Luis de Bethencourt
2d3dc2caa6 rtph265depay: Use GST_BUFFER_PTS() instead of GST_BUFFER_TIMESTAMP()
Switching to GST_BUFFER_TIMESTAMP() to be consistent with other rtp code.
2015-08-12 15:14:52 +01:00
Luis de Bethencourt
9379933607 rtph265depay: prevent trying to get 0 bytes from adapter
This causes an assertion and would lead to getting a NULL instead
of a buffer. Without proper checking this would easily lead to a
segfault.

Related to rpth264depay: https://bugzilla.gnome.org/show_bug.cgi?id=737199
2015-08-12 15:05:02 +01:00
Sreerenj Balachandran
8a6cc4ed27 codecparsers: h265: Fix the range of delta_chroma_log2_weight_denom
ChromaLog2WeightDenom = luma_log2_weight_denom + delta_chroma_log2_weight_denom

The value of ChromaLog2WeightDenom should be in the range of 0 to 7 and
the value luma_log2_weight_denom  should be also in the range of 0 to 7.
Which means , delta_chroma_log2_weight_denom can have values in the range
between -7 and 7.

https://bugzilla.gnome.org/show_bug.cgi?id=753552
2015-08-12 14:11:31 +02:00
Sreerenj Balachandran
b6b2e04501 codecparsers: h265: Fix the parsing of ref_pic_lists_modification
https://bugzilla.gnome.org/show_bug.cgi?id=753552
2015-08-12 14:11:26 +02:00
Matthew Waters
b38f107bd3 glimagesink: take into account non 1/1 par for navigation
The current code was ignoring the par/dar aspect when transforming
from window coordinates to stream coordinates resulting in incorrect
coordinates being sent upstream in the navigation events.
2015-08-12 00:25:35 +02:00
Matthew Waters
c867c8505b gtk: fix motion event name
s/motion/mouse/

Fixes hover interaction with DVD menus
2015-08-12 00:25:35 +02:00
Matthew Waters
7d96729feb gtk: correct navigation events for window scaling
i.e. take into account the possiblity of scaling in the sink
or through GDK_SCALE.

Fixes DVD Menus with a scaled gtkwidget
2015-08-12 00:25:35 +02:00
Nicolas Dufresne
e531ea9ff0 frei0r: Fix setting string parameters
String parameters are expected to be passed as (f0r_param_string *),
which actually map to char**. In the filters this is evaluated as
(*(char**)param) which currently lead to crash when passing char*.

Remove the special case for string, all types, including char* as
passed as a reference.

https://phabricator.freedesktop.org/T83
2015-08-11 15:11:01 -04:00
Matthew Waters
988643eb43 gtk: implement GstNavigation interface
Now we can push key/mouse input into the pipeline for DVD use cases.
2015-08-11 13:38:03 +02:00
Sebastian Dröge
711589ebde opus: Copy metadata in the (de)payloader, but only the relevant ones
The payloader didn't copy anything so far, the depayloader copied every
possible meta. Let's make it consistent and just copy all metas without tags or
with only the audio tag.

https://bugzilla.gnome.org/show_bug.cgi?id=751774
2015-08-11 12:46:06 +02:00
Sreerenj Balachandran
a83dabd5e8 videoparsers: h265: Fix the frame start detection code
Check slice headers in between GST_H265_NAL_SLICE_TRAIL_N
and GST_H265_NAL_SLICE_RASL_R for frame start detection.

https://bugzilla.gnome.org/show_bug.cgi?id=753497
2015-08-11 11:34:36 +01:00
Sreerenj Balachandran
2775b202dc videoparsers: h265: Avoid skipping of EOS and EOB nals
EndOfSequence and EndOfBitstream nal units have size of 2 bytes.
Don't consider them as broken nals.

https://bugzilla.gnome.org/show_bug.cgi?id=753497
2015-08-11 11:34:36 +01:00
Vanessa Chipi
32942c99d8 facedetect: wrong form to write the delete operator
The delete operator is written this way: delete (cascade). This way is
misspelled, it is an operator, not a function. Delete the parentheses.
2015-08-11 11:26:17 +01:00
vanechipi
28f9ff1312 facedetect: simplify repeated code.
Store the value of r.height / 2 instead of repeating the operation line
three times.
2015-08-11 11:18:50 +01:00
vanechipi
73bc2cf7b0 facedetect: Redundancy exists in code.
Checking the vector is not empty and checking the vector size is greater
than zero are the same thing, this is a redundancy in the code. Only
checking the vector is not empty is sufficient, therefore removing the
other check.
2015-08-11 11:13:23 +01:00
Nicolas Dufresne
9720c07f23 gl: Add opengl_version.h to the list of sources
Adding this private header to the list of sources. We don't want to make
this header public, but we need it in the list of sources otherwise it
won't be included in the tarball. This fixes make distcheck.

This regression was introduced by commit 1a6fe3db
2015-08-10 14:51:02 -04:00