Commit graph

3222 commits

Author SHA1 Message Date
Gianluca Gennari
416ea67979 mpdparser: support multiple ProgramInformation nodes
now we keep a list of ProgramInformation nodes for each Period node
2013-05-08 18:13:48 -03:00
Gianluca Gennari
dd198bc86d mpdparser: fixed parsing of SegmentList syntax element, and eliminated Represention node list from Period node
SegmentList nodes are allowed into Period, AdaptationSet or Representation nodes
and there is at most 1 element, so no need to keep a list;

Period nodes cannot have any Represention elements, as AdaptationSet nodes are mandatory;
this breaks compatibility with some legacy DASH test sequences.
2013-05-08 18:13:48 -03:00
Gianluca Gennari
8e3092661a mpdparser: fixed return with no value
gstmpdparser.c: In function ‘gst_mpdparser_get_list_and_nb_of_audio_language’:
gstmpdparser.c:2891: warning: ‘return’ with no value, in function returning non-void
2013-05-08 18:13:48 -03:00
Gianluca Gennari
7330bbfa7a mpdparser.c/.h: changed license from dual MIT/LGPL 2.0 to LGPL 2.1
uniformed licencinsing to the other libraries in the dashdemux project
2013-05-08 18:13:48 -03:00
hzakari
ec44485510 Optimize the two functions that return the number and the list of languages in a single function 2013-05-08 18:13:48 -03:00
Hamid ZAKARI
fab388c9fd Add the headers to the adaptationsets segments if any one of these changed representation 2013-05-08 18:13:46 -03:00
Hamid ZAKARI
713d02b81a Support Multi languages (need a decodebin2 patch) 2013-05-08 18:13:45 -03:00
Hamid ZAKARI
a4ac4a3117 Remove the "TODO" comment 2013-05-08 18:13:45 -03:00
David Corvoysier
3c937636ee Renamed LICENSE into COPYING 2013-05-08 18:13:44 -03:00
David Corvoysier
79dc12cc05 Updated authors 2013-05-08 18:13:44 -03:00
David Corvoysier
6fc0db0e0b Initial import of gstdashdemux sources 2013-05-08 18:13:43 -03:00
Tim-Philipp Müller
43fea50c8a smoothstreaming: pass width, height, channels and rate as integer
g_ascii_strtoull() returns a long long integer, but we need to
pass a normal int to gst_structure_set() for fields of G_TYPE_INT,
so cast appropriately.
2013-05-08 15:42:01 +01:00
Tim-Philipp Müller
99c1dce8db smoothstreaming: fix WMV caps
Makes this show at least a picture:
http://playready.directtaps.net/smoothstreaming/TTLSS720VC1/To_The_Limit_720.ism/Manifest
2013-05-08 10:55:16 +01:00
Thiago Santos
4711da22e9 mssdemux: fixing compiler warnings about print formats 2013-05-07 21:09:49 -03:00
Thiago Santos
4545f4bf4e smoothstreaming: port to 1.0 2013-05-07 21:09:49 -03:00
Thiago Santos
001da5a239 mssdemux: remove already fixed TODO comment 2013-05-07 21:09:49 -03:00
Thiago Santos
210f6c510c mssdemux: replace gst_value_deserialize with simpler function
The deserialization was only used to convert hex strings into
GstBuffers. Replace gst_value_deserialize with a simpler, direct
function.
2013-05-07 21:09:49 -03:00
Thiago Santos
1458500850 mssdemux: fix newsegment event leak 2013-05-07 21:09:48 -03:00
Thiago Santos
e541ec7e63 mssdemux: replace unused parameter
The buffer parameter wasn't being used, it was only to signal if
a buffer was downloaded and advance to the next fragment in the
manifest.

Replace the buffer with a boolean that has the same effect and is
safer
2013-05-07 21:09:48 -03:00
Wim Taymans
6d56eba653 mss: avoid GValue leak 2013-05-07 21:09:48 -03:00
Louis-Francis Ratté-Boulianne
f0b6b79461 mssdemux: fix a small memory leak 2013-05-07 21:09:48 -03:00
Louis-Francis Ratté-Boulianne
00400a838b mssdemux: avoid streaming to fail when download is cancelled
When download was failing repeatedly, it was causing streaming to fail even though it was cancelled on purpose (stopping tasks).
2013-05-07 21:09:48 -03:00
Thiago Santos
b579cb1ddc mssdemux: removing unused functions 2013-05-07 21:09:48 -03:00
Thiago Santos
1d28c574cf mssdemux: switch bitrates without switching pads 2013-05-07 21:09:48 -03:00
Andre Moreira Magalhaes (andrunko)
c8367a346c mssdemux: Check if pads are valid before removing. 2013-05-07 21:09:48 -03:00
Thiago Santos
bf0ea5d561 mssdemux: add a maximum error count for downloads
mssdemux will tolerate a few download errors before emitting an
error message to the bus
2013-05-07 21:09:48 -03:00
Thiago Santos
255eb4b161 mssdemux: use streams bitrate individually
connection setup times seem to matter when measuring the download
rate of different streams. Streams with longer fragments have a
*relatively* lower connection setup time and achieve higher bitrates.

Using the average seems unfair here, so use each stream's measured bitrate
to select its best quality option.
2013-05-07 21:09:48 -03:00
Thiago Santos
52c97834df mssdemux: use downloadbitrate utility for measuring bitrate
downloadbitrate keeps a short history of bitrates and helps
tracking the current average download bitrate for mssdemux
2013-05-07 21:09:48 -03:00
Andre Moreira Magalhaes (andrunko)
68308b3e54 mssdemux: Properly compute new bitrate and use bitrate_limit. 2013-05-07 21:09:48 -03:00
Andre Moreira Magalhaes (andrunko)
706b127daa mssdemux: Avoid a possible division by zero 2013-05-07 21:09:48 -03:00
Andre Moreira Magalhaes (andrunko)
28beb2ebd7 mssdemux: Add missing object param to GST_DEBUG|INFO_OBJECT calls 2013-05-07 21:09:48 -03:00
Thiago Santos
2219a3a1cc mssdemux: add bitrate-limit property
It allows the plugin to use its own downloading bitrate measures
as a feedback to select the best streams bitrate for the current
network scenario
2013-05-07 21:09:48 -03:00
Thiago Santos
a0a05b2941 mssdemux: use the shared uridownloader lib instead of an internal copy 2013-05-07 21:09:47 -03:00
Andre Moreira Magalhaes (andrunko)
12e9432847 mssdemux: Do not block on reset.
We need to cancel the downloader for each stream before joining the main download task, otherwise
the download task will block until all the stream tasks finish.
2013-05-07 21:09:47 -03:00
Louis-Francis Ratté-Boulianne
8ab3d09f81 mssdemux: handle FLUSH events by resetting the demuxer state 2013-05-07 21:09:47 -03:00
Louis-Francis Ratté-Boulianne
4a630f86f8 mssdemux: add conditions to prevent some crashes 2013-05-07 21:09:47 -03:00
Louis-Francis Ratté-Boulianne
218f2dee0c mssdemux: use standard glib methods 2013-05-07 21:09:47 -03:00
Louis-Francis Ratté-Boulianne
44d02efee0 mssdemux: fix some memory leaks and use right free function 2013-05-07 21:09:47 -03:00
Louis-Francis Ratté-Boulianne
b064910895 mssdemux: don't stop a task from inside the loop
Only pause the task
2013-05-07 21:09:47 -03:00
Louis-Francis Ratté-Boulianne
0239d77999 mssdemux: log manifest content for debugging 2013-05-07 21:09:47 -03:00
Louis-Francis Ratté-Boulianne
ea5f2718bf mssdemux: make codec private data from manifest attributes with AAC-LC
When the codec is AAC-LC, some server implementation (e.g. Microsoft IIS) doesn't add the CodecPrivateData attribute. The element needs to re-create the codec data from the Quality Level attributes (channels and sampling rate).
2013-05-07 21:09:47 -03:00
Louis-Francis Ratté-Boulianne
3ebb842388 mssdemux: only try to reload the manifest for live streams
There is no way to know if a live stream is really finished, so try to reload the manifest and check if there are more fragments to download. Else just let know it's the EOS.
2013-05-07 21:09:47 -03:00
Thiago Santos
7cb3a367f6 mssdemux: add some documentation
Adds a little bit of docs explaning the internals of mssdemux
2013-05-07 21:09:47 -03:00
Thiago Santos
46efc08809 mssdemux: add max-queue-size-buffers property
Indicates how much buffering should be done internally in
mssdemux
2013-05-07 21:09:47 -03:00
Thiago Santos
23ad760e3a mssdemux: stop tasks faster
Issue a cancel to the downloaders so they stop earlier
2013-05-07 21:09:47 -03:00
Thiago Santos
aa1713068a mssdemux: implement live streams handling
Live streams force the demuxer to keep reloading the Manifest from
time to time, as the new fragments are being added as they are recorded.
The demuxer should also try to keep up and detect when it had to skip
fragments, marking the discont flag when that happens.

Curiously, the spec doesn't seem to mention when/how a live stream is supposed
to end, so keep trying downloads until the demuxer errors out.
2013-05-07 21:05:12 -03:00
Thiago Santos
0704f15103 mssdemux: do not leak fragments 2013-05-07 21:05:12 -03:00
Thiago Santos
21872e78b8 mssdemux: fix issue on fragment timestamping parsing
Use guint64 as the fragments can start at very high numbers,
specially on live streams
2013-05-07 21:05:12 -03:00
Thiago Santos
0a4c077d2e mssdemux: error out when upstream doesn't implement URI query
Error out when upstream doesn't answer to URI query and mssdemux
doesn't know the URI to fetch the fragments from
2013-05-07 21:05:12 -03:00
Thiago Santos
1116eee681 mssdemux: push newsegments with same start time on bitrate switches
This keeps sinks working in sync after a bitrate switch
2013-05-07 21:05:12 -03:00