Commit graph

239 commits

Author SHA1 Message Date
Tim-Philipp Müller
1c88985618 asfdemux: WM/Track starts counting from 0, adjust to start from 1 2009-11-05 18:11:55 +00:00
Tim-Philipp Müller
aa52dd1320 asfdemux: map WM/TrackNumber to GST_TAG_TRACK_NUMBER as well
There's both WM/Track and WM/TrackNumber.
2009-11-05 18:11:35 +00:00
Jan Schmidt
acd6f70515 asfdemux: Fix bogus variable used uninitialised warnings 2009-11-04 15:46:04 +00:00
Josep Torra
c4fe899f1a asfdemux: fix warning in macosx snow leopard 2009-10-11 16:06:25 +02:00
Stefan Kost
d125baa8c5 build: fprintf, sprintf, sscanf need stdio.h 2009-10-07 14:22:09 +03:00
Edward Hervey
6f58ca470e asfdemux: Refactor multiple packet pull.
This also fixes a bug by which the first buffer (in a multi-packet mode)
passed to asf_demux_parse_packet() would have a GST_BUFFER_SIZE of the
full incoming buffer and not just of the single asf packet.

Fixes corrupted frames introduced by latest commit.
2009-06-29 11:13:02 +02:00
Wim Taymans
0fc6f338dc asfdemux: use the right accurate field
Remove accurate variable and its faulty use because the real variable is an
instance variable.
2009-06-29 10:58:49 +02:00
Edward Hervey
d71973cc4c asfdemux: Sprinkle branch prediction macros accross the code 2009-06-28 17:52:38 +02:00
Edward Hervey
d451dff520 asfdemux: Delay newsegment handling until we have a keyframe.
We now have a chance for packets to be collected before we send out the
newsegment. If we're not in accurate seeking (keyunit) it will set
the segment start/time to the keyframe's timestamp.
2009-06-28 17:52:38 +02:00
Edward Hervey
3b63c95450 asfdemux: Remove useless check. We already have checked for it above. 2009-06-28 17:52:38 +02:00
Edward Hervey
a3c832405e asfdemux: No longer queue GOPs now that seeking is fixed.
We now *always* seek to the keyframe just before our requested position.
When we encounter the first keyframe and we were not accurate (therefore doing
keyframe seeking), we update the segment start position to the keyframe timestamp.
2009-06-28 17:50:45 +02:00
Edward Hervey
e6c6eefefb asfdemux: Store the accurate seeking flag 2009-06-28 17:50:45 +02:00
Edward Hervey
725da8579b asfdemux: Use the average frame duration for buffers without a duration.
This will still cause some timestamp jitter, but giving a hint as to the duration
rather than nothing seems to be a better idea.
Also, this allows some scenarios (like remuxing with asfmux) to estimate the total
duration using the accumulated packet duration (which will be correct).
2009-06-28 17:33:51 +02:00
Edward Hervey
99d9b34385 asfdemux: Use index entry packet count to optimize seeking.
The simple index entries also contain the number of packets one needs
to retrieve at a given position to get a full keyframe. We therefore
use that information to retrieve all those packets in one buffer when
working in pull-mode.
2009-06-28 17:33:48 +02:00
Thiago Santos
6e2a117eb2 asfdemux: Do not try to free const pointer
In gst_asf_demux_chain_headers, when 'goto wrong_type' was called
asfdemux tried to free a const pointer that had been cast to a
normal pointer variable.
2009-06-26 21:07:59 -03:00
Edward Hervey
3c683ead7b asfdemux: Use presentation timestamp when searching in the index.
We need to take the preroll into account... else we end up too early.
2009-06-26 20:45:09 +02:00
Edward Hervey
c1bf0a091c asfdemux: Convert index entry from presentation time to timestamps.
We weren't taking the preroll into account previously, meaning that we
were always seeking preroll nanoseconds too early... resulting in a lot
of dropped packets (which are before the start time).

This brings quit a bit closer to as-fast-as-possible seeking in asf files.
2009-06-26 13:35:38 +02:00
Edward Hervey
db5ddf927c asfdemux: Fix byte array metadata handling.
We basically discard byte array metadata. Should be trivial to adapt
to storing the pointers if we need it later on.
2009-06-26 10:58:56 +02:00
Edward Hervey
a3f200e4f8 asfdemux: Handle PAR/interlaced information stored in packet payload.
This is the 'other' way to store non 1/1 PAR in asf streams (by storing it
in the ASF Packet payload extensions).
2009-06-26 10:42:29 +02:00
Edward Hervey
1cc2eed416 asfdemux: Store/Handle global metadata (not specific to one stream).
This allows us to store (and handle) PAR information which might be stored there.
2009-06-26 10:42:29 +02:00
Tim-Philipp Müller
16a09febbd asfdemux: don't try to free a NULL taglist 2009-06-23 16:45:00 +01:00
Tim-Philipp Müller
6ec0b61980 asfdemux: post tags only after we've created our source pads
Post global tags only after we've added our source pads, so that
tag events get sent downstream in addition to tag messages posted
on the bus. This makes sure tags can be picked up automatically
when transcoding, but also by tagreadbin/playbin2. Fixes #519721.

While we're at it, also add a container-format tag.
2009-06-23 02:14:00 +01:00
Tim-Philipp Müller
aa0d6f7b48 asfdemux: use new bytereader functions for image tag parsing 2009-06-23 01:38:01 +01:00
Mark Nauwelaerts
1874bf5910 asfdemux: remove some more unused variables 2009-06-22 19:10:17 +02:00
Wim Taymans
36d0450d6e asfdemux: set DISCONT on streams
When we receive a DISCONT as input, don't clear our complete state but simply
mark a discont that will be put on the next buffer. The code will be able to
handle and throw away incomplete data.
Add some more debug info.
Remove an unused variable.
2009-06-22 17:16:58 +02:00
Wim Taymans
8de1502c9b asfdemux: fix latency calculations
We need to check for -1 as an invalid timestamp, not 1.
2009-06-22 13:39:41 +02:00
Tim-Philipp Müller
181db09d90 asfdemux: nicer metadata extraction of genre tags in some cases
Handle pseudo-strings like "(5)" and map them to the ID3v1 genre
that they presumably stand for.
2009-06-05 01:51:20 +01:00
Tim-Philipp Müller
2aeecee037 asfdemux: parse WM/Picture tags to extract cover art
Fixes #583112.
2009-06-05 01:37:54 +01:00
Tim-Philipp Müller
7c40c99238 asfdemux: fix bogus flow return handling in eos handler
Don't overwrite the origin flow return by whatever flow we get
when trying to push the remaining internally queued payloads.
We want to do our eos logic, ie. send an EOS event or segment-done
message in any case. Makes things EOS properly when an EOS event
is forced upon the pipeline so that the source returns
FLOW_UNEXPECTED to a pulling asfdemux. Should fix #582056.
2009-05-30 13:08:15 +01:00
Mark Nauwelaerts
e8a6ad2546 asfdemux: use upstream segment and timestamps for some interpolation
This should particularly help in case of upstream live src, e.g. rtspsrc,
and especially so if it has to perform fallback to TCP.
2009-05-07 12:23:51 +02:00
Mark Nauwelaerts
8b2812ca2e asfdemux: 0-base timestamps consistently (whether or not streaming)
This also makes timestamps (more) consistent before and after a possible
seek, and moreover makes for reasonable position reporting in live stream
(whose payload timestamps should not be taken for granted).
2009-05-05 22:41:41 +02:00
Mark Nauwelaerts
0b28139203 asfdemux: report initial latency due to internal preroll queue 2009-05-05 22:41:39 +02:00
Mark Nauwelaerts
c2d092765a asfdemux: enhance debug statement and refactor some initialization 2009-05-05 22:41:37 +02:00
Mark Nauwelaerts
b8297952cf asfdemux: handle FIXME; activate pads after internal preroll also when streaming 2009-05-05 22:41:35 +02:00
Mark Nauwelaerts
44ebe58377 asfdemux: handle FIXME; normalize preroll 2009-05-05 22:41:33 +02:00
Mark Nauwelaerts
b6d4fb9e4f asfdemux: fixes for streaming mode
* Improve newsegment handling, e.g. upstream might live in TIME.
* Only send newsegment if we have needed info.
* Avoid reading past end of data section.
2009-05-05 22:41:30 +02:00
Mark Nauwelaerts
2bd14c7153 asfdemux: fixes/enhancements for streaming mode
* Do not rock the boat by reacting to FLUSH_START.
* Try to handle TIME seeking by seeking upstream in BYTES.
* Handle SEEKING query.
2009-05-05 22:41:26 +02:00
Edward Hervey
bb6697ba4c asfdemux: Initialize flow for a corner case.
This might be caused by entering the if() line 1214 and then not having
any activated_streams.. resulting in reaching line 1267 without having
any valid flow value.
2009-04-19 14:03:58 +02:00
Wim Taymans
2377053422 asfdemux: add some more debugging 2009-04-14 10:53:33 +02:00
Sebastian Dröge
2744324adc Remove redundant push_mode struct member 2009-01-30 14:38:23 +01:00
Hans de Goede
3bcd050fab Add seeking support to asfdemux in push mode
Fixes bug #568836.
2009-01-26 10:02:02 +01:00
David Schleef
d798fa10c9 Fix leak of converted string 2009-01-23 17:51:32 -08:00
Wim Taymans
3838bdb40d gst/asfdemux/gstasfdemux.c: Remove duplicate and broken code for the streaming case and simply reuse the much better ...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_chain):
Remove duplicate and broken code for the streaming case and simply reuse
the much better working pull based code. Fixes #560348.
2008-11-20 21:31:19 +00:00
Wim Taymans
0ba1ec7104 gst/asfdemux/gstasfdemux.c: Only copy sane aspect ratio values on the caps. Fixes #559682.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_add_video_stream):
Only copy sane aspect ratio values on the caps. Fixes #559682.
2008-11-11 17:14:46 +00:00
Edward Hervey
def71526d9 gst/asfdemux/gstasfdemux.c: Fix aggregated GST_FLOW_RETURN check for when to send an error message on the bus.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_loop):
Fix aggregated GST_FLOW_RETURN check for when to send an error message
on the bus.
Re-fixes #546859
2008-08-28 09:57:30 +00:00
Michael Smith
33532cddc4 gst/asfdemux/gstasfdemux.c: Properly aggregate flow returns for both push and pull mode, so we shut down if all pads ...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c:
Properly aggregate flow returns for both push and pull mode, so we shut
down if all pads are unlinked.
Fixes #546859.
2008-08-11 18:44:35 +00:00
Tim-Philipp Müller
f887811a64 Use correct error code for encrypted streams.
Original commit message from CVS:
* configure.ac:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_process_object):
Use correct error code for encrypted streams.
2008-07-03 13:12:26 +00:00
Edgard Lima
d65a5d0d57 Fix "unused var" compiler error when --disable-gst-debug is used.
Original commit message from CVS:
Fix "unused var" compiler error when --disable-gst-debug is used.
2008-04-22 12:11:30 +00:00
Wim Taymans
2336c35df2 gst/asfdemux/gstasfdemux.c: Remove some debug code.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c:
(gst_asf_demux_process_ext_stream_props):
Remove some debug code.
2008-04-01 14:39:24 +00:00
Wim Taymans
229b4f33d3 gst/asfdemux/gstasfdemux.c: Guard against division by 0 and fall back to 25/1 framerate.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c:
(gst_asf_demux_process_ext_stream_props):
Guard against division by 0 and fall back to 25/1 framerate.
2008-04-01 14:29:32 +00:00
Wim Taymans
5f2bca58b0 gst/asfdemux/gstasfdemux.c: Instead of adding a fixes 25/1 framerate to the video caps, use the average frame duratio...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_add_video_stream),
(gst_asf_demux_process_ext_stream_props):
Instead of adding a fixes 25/1 framerate to the video caps, use the
average frame duration in the extended properties of the video stream as
the framerate. Fixes #524346.
2008-04-01 14:00:32 +00:00
Sebastian Dröge
269a9706fc gst/asfdemux/gstasfdemux.c: If we don't have the position to seek to in our index first try to convert from TIME to B...
Original commit message from CVS:
Patch by:
Hans de Goede <j dot w dot r dot degoede at hhs dot nl>
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_handle_seek_event):
If we don't have the position to seek to in our index first try
to convert from TIME to BYTES upstream and only if that fails
too use the old hack to simply seek to an earlier position
and let the sink drop everything before segment start.
Partially fixes bug #469930.
2008-02-22 06:19:41 +00:00
Tim-Philipp Müller
49cdce158d gst/asfdemux/gstasfdemux.*: Parse metadata object and extract pixel aspect ratio. Fixes #507844.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (asfdemux_dbg), (gst_asf_demux_reset),
(gst_asf_demux_add_video_stream),
(gst_asf_demux_process_ext_content_desc),
(gst_asf_demux_get_metadata_for_stream),
(gst_asf_demux_process_metadata), (gst_asf_demux_process_object),
(gst_asf_demux_change_state):
* gst/asfdemux/gstasfdemux.h:
Parse metadata object and extract pixel aspect ratio. Fixes #507844.
2008-01-08 16:31:29 +00:00
Stefan Kost
fcc7538113 gst/asfdemux/gstasfdemux.c: Sync _activate_pull() a little more with other demuxers.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c:
Sync _activate_pull() a little more with other demuxers.
2007-11-13 06:57:57 +00:00
Tim-Philipp Müller
db4e736086 gst/asfdemux/gstasfdemux.c: Convert tags that come as string into the type required by
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_process_ext_content_desc):
Convert tags that come as string into the type required by
GstTagList.
2007-10-31 14:33:03 +00:00
Stefan Kost
1c87647aa0 gst/asfdemux/gstasfdemux.c: Include stdlib.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c:
Include stdlib.
2007-07-20 07:58:25 +00:00
Tim-Philipp Müller
0e2c8a042f Fix build against core CVS by not using deprecated API. Bump requirements for new API (overdue anyway).
Original commit message from CVS:
* configure.ac:
* ext/mpeg2dec/gstmpeg2dec.c: (crop_buffer):
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_descramble_buffer):
* gst/dvdlpcmdec/gstdvdlpcmdec.c: (gst_dvdlpcmdec_chain_raw):
Fix build against core CVS by not using deprecated API. Bump
requirements for new API (overdue anyway).
2007-07-11 23:18:14 +00:00
Tim-Philipp Müller
08c63b6800 gst/asfdemux/gstasfdemux.*: Activate streams (ie. add the pads to the element) depending on whether we actually get d...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_reset),
(gst_asf_demux_chain_headers),
(gst_asf_demux_parse_data_object_start), (all_streams_prerolled),
(gst_asf_demux_have_mutually_exclusive_active_stream),
(gst_asf_demux_check_activate_streams),
(gst_asf_demux_find_stream_with_complete_payload),
(gst_asf_demux_push_complete_payloads), (gst_asf_demux_loop),
(gst_asf_demux_activate_ext_props_streams),
(gst_asf_demux_process_object):
* gst/asfdemux/gstasfdemux.h:
Activate streams (ie. add the pads to the element) depending on
whether we actually get data for those streams within the ASF
preroll value specified. Currently only done in pull-mode though
(this will fix problems with playbin hanging on mms streams once
we use this in push-mode as well).
2007-05-07 13:51:43 +00:00
Tim-Philipp Müller
f7abd8bbc8 gst/asfdemux/: Make all timestamps start from zero in pull-mode too; some small clean-ups and FIXMEs here and there.
Original commit message from CVS:
* gst/asfdemux/asfpacket.c: (gst_asf_payload_queue_for_stream):
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_reset),
(gst_asf_demux_init), (gst_asf_demux_push_complete_payloads),
(gst_asf_demux_process_file):
* gst/asfdemux/gstasfdemux.h:
Make all timestamps start from zero in pull-mode too; some small
clean-ups and FIXMEs here and there.
2007-05-04 11:04:16 +00:00
Tim-Philipp Müller
279b2b0290 gst/asfdemux/: Seeking improvements: honour the KEY_UNIT seek flag; after a seek, only send data from the keyframe ri...
Original commit message from CVS:
* gst/asfdemux/asfpacket.c: (gst_asf_payload_queue_for_stream):
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_seek_index_lookup),
(gst_asf_demux_handle_seek_event),
(gst_asf_demux_push_complete_payloads):
Seeking improvements: honour the KEY_UNIT seek flag; after a seek, only
send data from the keyframe right before the new segment start to
make sure the decoder doesn't have to decode more than absolutely
necessary.
2007-05-01 09:19:13 +00:00
Tim-Philipp Müller
b46ece6980 gst/asfdemux/: Implement payload extension system/extended replicated data parsing, so we can extract payload duratio...
Original commit message from CVS:
* gst/asfdemux/asfheaders.c:
* gst/asfdemux/asfheaders.h:
* gst/asfdemux/asfpacket.c:
(asf_payload_parse_replicated_data_extensions),
(gst_asf_demux_parse_payload):
* gst/asfdemux/asfpacket.h:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_free_stream),
(gst_asf_demux_push_complete_payloads),
(gst_asf_demux_process_ext_stream_props):
* gst/asfdemux/gstasfdemux.h:
Implement payload extension system/extended replicated data parsing,
so we can extract payload durations if they're specified.
2007-04-30 15:36:00 +00:00
Tim-Philipp Müller
850c0fbab8 gst/asfdemux/: Refactor stream parse/activation a bit (stream activation heuristics are still the same though); some ...
Original commit message from CVS:
* gst/asfdemux/asfheaders.h:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_free_stream),
(gst_asf_demux_reset), (gst_asf_demux_parse_data_object_start),
(gst_asf_demux_loop), (gst_asf_demux_setup_pad),
(gst_asf_demux_add_audio_stream), (gst_asf_demux_activate_stream),
(gst_asf_demux_parse_stream_object),
(gst_asf_demux_process_ext_stream_props),
(gst_asf_demux_process_queued_extended_stream_objects),
(gst_asf_demux_activate_ext_props_streams),
(gst_asf_demux_process_object):
* gst/asfdemux/gstasfdemux.h:
Refactor stream parse/activation a bit (stream activation heuristics
are still the same though); some more clean-ups.
2007-04-30 11:41:22 +00:00
Tim-Philipp Müller
1c69080416 gst/asfdemux/: Init debug category before using it.
Original commit message from CVS:
* gst/asfdemux/gstasf.c: (plugin_init):
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_base_init):
* gst/asfdemux/gstasfdemux.h:
Init debug category before using it.
2007-04-28 10:49:17 +00:00
Tim-Philipp Müller
9ee314648e gst/asfdemux/gstasfdemux.c: Fix silly bug when we can't pull as much data as we want; don't forget to announce pendin...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_pull_data),
(gst_asf_demux_push_complete_payloads), (gst_asf_demux_loop):
Fix silly bug when we can't pull as much data as we want; don't
forget to announce pending tags in the new packet parsing code.
2007-04-27 18:39:21 +00:00
Tim-Philipp Müller
6197c64106 gst/asfdemux/: New packet parsing code: should put halfway decent timestamps on buffers, and might even set the appro...
Original commit message from CVS:
* gst/asfdemux/Makefile.am:
* gst/asfdemux/asfpacket.c: (asf_packet_read_varlen_int),
(asf_packet_create_payload_buffer),
(asf_payload_find_previous_fragment),
(gst_asf_payload_queue_for_stream), (gst_asf_demux_parse_payload),
(gst_asf_demux_parse_packet):
* gst/asfdemux/asfpacket.h:
* gst/asfdemux/gstasfdemux.c:
(gst_asf_demux_reset_stream_state_after_discont),
(gst_asf_demux_push_complete_payloads), (gst_asf_demux_loop),
(gst_asf_demux_setup_pad), (gst_asf_demux_descramble_buffer),
(gst_asf_demux_process_chunk):
* gst/asfdemux/gstasfdemux.h:
New packet parsing code: should put halfway decent timestamps on
buffers, and might even set the appropriate keyframe/discont buffer
flags from time to time (and even if it doesn't, I'm at least able
to debug this code); only used in pull-mode so far. Still needs
some more work, like payload extensions parsing and proper flow
aggregation, and stream activation based on preroll. Stay tuned.
2007-04-20 20:57:56 +00:00
Tim-Philipp Müller
07f692085f gst/asfdemux/: Some clean-ups and small fixes: rename asf_stream_context structure to
Original commit message from CVS:
* gst/asfdemux/asfheaders.h:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_free_stream),
(gst_asf_demux_seek_index_lookup),
(gst_asf_demux_handle_seek_event), (gst_asf_demux_get_stream),
(gst_asf_demux_setup_pad), (gst_asf_demux_add_video_stream),
(gst_asf_demux_process_ext_content_desc),
(gst_asf_demux_process_file), (gst_asf_demux_descramble_segment),
(gst_asf_demux_push_buffer), (gst_asf_demux_process_chunk),
(gst_asf_demux_process_segment), (gst_asf_demux_handle_data):
* gst/asfdemux/gstasfdemux.h:
Some clean-ups and small fixes: rename asf_stream_context structure to
AsfStream; inline some three-line utility functions that are only used
once anyway and get rid of their associated helper structs; make debug
category global so that it is used by the debug statements in the other
file as well; simplify gst_asf_demux_get_stream(); fix accidental
implicit initialisation of stream->last_buffer_timestamp to 0, which
would lead to missing timestamps on the first buffer; put fourcc format
into video caps to make certain proprietary wmv decoders happy (for the
case of WMVA in particular); play_time is offset by preroll as well, so
fix overreporting of duration for some files.
2007-04-20 17:32:00 +00:00
Tim-Philipp Müller
9ff45f3d88 gst/asfdemux/gstasfdemux.c: Printf format fixes.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_handle_seek_event),
(gst_asf_demux_pull_indices):
Printf format fixes.
2007-04-17 10:21:50 +00:00
Tim-Philipp Müller
d0483656b3 gst/asfdemux/: Make asfdemux work in pull mode where possible. If there's an index at the end of the file, read it an...
Original commit message from CVS:
* gst/asfdemux/asfheaders.c:
* gst/asfdemux/asfheaders.h:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_free_stream),
(gst_asf_demux_reset), (gst_asf_demux_init),
(gst_asf_demux_activate), (gst_asf_demux_activate_push),
(gst_asf_demux_activate_pull), (gst_asf_demux_sink_event),
(gst_asf_demux_seek_index_lookup),
(gst_asf_demux_reset_stream_state_after_discont),
(gst_asf_demux_handle_seek_event),
(gst_asf_demux_handle_src_event), (gst_asf_demux_chain_headers),
(gst_asf_demux_chain), (gst_asf_demux_pull_data),
(gst_asf_demux_pull_indices),
(gst_asf_demux_parse_data_object_start),
(gst_asf_demux_pull_headers), (gst_asf_demux_loop),
(gst_asf_demux_setup_pad), (gst_asf_demux_process_file),
(gst_asf_demux_process_simple_index),
(gst_asf_demux_process_object),
(gst_asf_demux_send_event_unlocked), (gst_asf_demux_push_buffer),
(gst_asf_demux_handle_data), (gst_asf_demux_change_state):
* gst/asfdemux/gstasfdemux.h:
Make asfdemux work in pull mode where possible. If there's an index
at the end of the file, read it and use it for seeking purposes.
2007-04-12 13:38:03 +00:00
Tim-Philipp Müller
620f5606ba gst/asfdemux/gstasfdemux.c: Printf format fix.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_process_header_ext):
Printf format fix.
2007-03-10 15:56:26 +00:00
Tim-Philipp Müller
12f441024b gst/asfdemux/gstasfdemux.*: Parse advanced mutual exclusion object and only add pads for 'hidden' streams (those in a...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_process_file),
(gst_asf_demux_process_advanced_mutual_exclusion),
(gst_asf_demux_process_queued_extended_stream_objects),
(gst_asf_demux_process_object), (gst_asf_demux_change_state):
* gst/asfdemux/gstasfdemux.h:
Parse advanced mutual exclusion object and only add pads for
'hidden' streams (those in an extended stream header) that are
mutually exclusive with an already existing 'main stream' if
the broadcasting flag is not set. If the broadcasting flag is set,
assume that data for this stream isn't sent. (This should ideally be
solved better by making playbin more robust against this and/or by
making mmssrc send some information downstream about which streams
will be streamed). Fixes #353116.
2007-02-15 19:55:55 +00:00
Tim-Philipp Müller
f8d7045fc8 gst/asfdemux/: Refactor and clean up header parsing and chain function a bit; get rid of some cruft; make header pars...
Original commit message from CVS:
* gst/asfdemux/asfheaders.c:
* gst/asfdemux/asfheaders.h:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_init),
(gst_asf_demux_sink_event), (gst_asf_demux_handle_seek_event),
(gst_asf_demux_identify_guid), (asf_demux_peek_object),
(gst_asf_demux_chain_headers), (gst_asf_demux_chain),
(gst_asf_demux_setup_pad), (gst_asf_demux_process_stream),
(gst_asf_demux_process_ext_content_desc),
(gst_asf_demux_get_object_header), (gst_asf_demux_process_header),
(gst_asf_demux_process_file), (gst_asf_demux_process_comment),
(gst_asf_demux_process_bitrate_props_object),
(gst_asf_demux_process_header_ext),
(gst_asf_demux_process_language_list),
(gst_asf_demux_process_ext_stream_props),
(gst_asf_demux_process_queued_extended_stream_objects),
(gst_asf_demux_process_object), (gst_asf_demux_change_state):
* gst/asfdemux/gstasfdemux.h:
Refactor and clean up header parsing and chain function a bit; get
rid of some cruft; make header parsing a tad more robust, fixing
#403188.
2007-02-08 21:07:27 +00:00
Tim-Philipp Müller
69f195f044 gst/asfdemux/gstasfdemux.c: Post an error if we receive an EOS event while still waiting for the
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_sink_event):
Post an error if we receive an EOS event while still waiting for the
ASF header object to come through.
2007-02-01 11:12:25 +00:00
Xavier B
a7ba4d3802 gst/asfdemux/gstasfdemux.c: Guard places where we assume that a certain amount of data is available better against le...
Original commit message from CVS:
Patch by: Xavier B. <xavierb gmail com>
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_get_guid),
(gst_asf_demux_add_audio_stream), (gst_asf_demux_add_video_stream),
(gst_asf_demux_process_ext_content_desc),
(gst_asf_demux_process_data),
(gst_asf_demux_process_language_list),
(gst_asf_demux_process_ext_stream_props),
(gst_asf_demux_process_segment), (gst_asf_demux_handle_data):
Guard places where we assume that a certain amount of data is
available better against less data being available (should fix
infamous assertion crasher bug #336370). Also fixes a small
memory leak.
2007-01-24 17:36:36 +00:00
Stefan Kost
9a9c15cec3 gst/asfdemux/gstasfdemux.c: add a comment about a future change
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c:
(gst_asf_demux_get_gst_tag_from_tag_name),
(gst_asf_demux_process_ext_content_desc):
add a comment about a future change
* tests/check/elements/amrnbenc.c: (setup_amrnbenc),
(cleanup_amrnbenc):
* tests/check/elements/mpeg2dec.c: (setup_mpeg2dec),
(cleanup_mpeg2dec):
consistent pad (de)activation
2006-12-21 08:16:41 +00:00
Tim-Philipp Müller
5e3f0ca964 gst/asfdemux/gstasfdemux.c: Update query_types function too.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_get_src_query_types):
Update query_types function too.
2006-12-15 18:26:41 +00:00
Tim-Philipp Müller
7e1371c41e gst/asfdemux/gstasfdemux.*: Don't crash in the seek event handling code when playtime is 0, as may be the case with l...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_handle_seek_event),
(gst_asf_demux_process_data), (gst_asf_demux_process_file),
(gst_asf_demux_handle_src_query), (gst_asf_demux_change_state):
* gst/asfdemux/gstasfdemux.h:
Don't crash in the seek event handling code when playtime is 0,
as may be the case with live streams (#386218). Implement SEEKING
query so applications can query seekability without second-guessing
based on whether we have a duration or not.
2006-12-15 17:54:48 +00:00
Tim-Philipp Müller
ee9f77cd22 gst/asfdemux/gstasfdemux.c: The availability of extra codec data isn't something that warrants debug messages at WARN...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_add_audio_stream):
The availability of extra codec data isn't something that
warrants debug messages at WARNING level (see #376958).
2006-11-20 15:52:42 +00:00
Tim-Philipp Müller
3a38311f01 gst/: Active pads before adding them to the running element. Don't assert on non-BYTE format newsegment events in asf...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_sink_event),
(gst_asf_demux_setup_pad), (gst_asf_demux_process_segment):
* gst/mpegstream/gstdvddemux.c: (gst_dvd_demux_get_audio_stream),
(gst_dvd_demux_get_subpicture_stream):
* gst/mpegstream/gstmpegdemux.c: (gst_mpeg_demux_get_video_stream),
(gst_mpeg_demux_get_audio_stream),
(gst_mpeg_demux_get_private_stream):
Active pads before adding them to the running element. Don't assert
on non-BYTE format newsegment events in asfdemux.
2006-10-09 12:09:14 +00:00
Tim-Philipp Müller
03f40e53fd Printf format fixes.
Original commit message from CVS:
* ext/dvdread/dvdreadsrc.c: (gst_dvd_read_src_goto_title),
(gst_dvd_read_src_handle_seek_event):
* ext/mad/gstid3tag.c: (gst_id3_tag_chain):
* ext/mad/gstmad.c: (gst_mad_src_query), (gst_mad_chain):
* ext/sidplay/gstsiddec.cc:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_parse_data):
* gst/realmedia/rmdemux.c: (gst_rmdemux_loop),
(gst_rmdemux_parse_packet):
Printf format fixes.
2006-10-05 17:07:52 +00:00
Stefan Kost
f960e4ca4d gst/asfdemux/gstasfdemux.c: Erm, lets properly fix it. The only non-text tag that we support is the track-number and ...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c:
(gst_asf_demux_get_gst_tag_from_tag_name),
(gst_asf_demux_process_ext_content_desc):
Erm, lets properly fix it. The only non-text tag that we support is
the track-number and that is an UINT. asfdemux was returning a GValue
initialized as INT. Further the Track and not the TrackNumber tag
(the latter is a string too).
2006-09-07 16:05:31 +00:00
Stefan Kost
e70a50e330 gst/asfdemux/gstasfdemux.c: Skip tags that are unknown (was producing an uninialized GValue).
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c:
(gst_asf_demux_get_gst_tag_from_tag_name),
(gst_asf_demux_process_ext_content_desc):
Skip tags that are unknown (was producing an uninialized GValue).
2006-09-07 14:08:42 +00:00
Tim-Philipp Müller
24d6ec6f6f gst/asfdemux/gstasfdemux.c: Use static pad templates with ANY caps for the source pads for simplicity and to avoid wa...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_base_init),
(gst_asf_demux_add_audio_stream), (gst_asf_demux_add_video_stream):
Use static pad templates with ANY caps for the source pads for
simplicity and to avoid warnings when creating pads for unhandled
codec IDs (#351795).
2006-08-22 15:52:16 +00:00
Jan Schmidt
f71c079eea Fix dist by including gst-libs/
Original commit message from CVS:
* Makefile.am:
* configure.ac:
* gst/asfdemux/gstasfdemux.c:
Fix dist by including gst-libs/
2006-07-31 09:53:05 +00:00
Tim-Philipp Müller
7a4e25d6e2 gst/asfdemux/: Error out when the stream is encrypted (rather than feeding garbage to the decoders). Fixes #349025.
Original commit message from CVS:
* gst/asfdemux/Makefile.am:
* gst/asfdemux/asfheaders.c:
* gst/asfdemux/asfheaders.h:
* gst/asfdemux/gstasf.c: (plugin_init):
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_process_object):
Error out when the stream is encrypted (rather than feeding
garbage to the decoders). Fixes #349025.
2006-07-28 15:15:15 +00:00
Tim-Philipp Müller
0a62eac428 gst/asfdemux/gstasfdemux.c: Find language codes for audio streams if they are available.
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c:
(gst_asf_demux_get_ext_stream_props_for_stream),
(gst_asf_demux_add_audio_stream), (gst_asf_demux_change_state):
Find language codes for audio streams if they are available.
2006-07-15 13:33:38 +00:00
Tim-Philipp Müller
1a414437a6 gst/asfdemux/: Parse extended stream properties objects and stream objects hidden inside them (but delay creation of ...
Original commit message from CVS:
* gst/asfdemux/asfheaders.h:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_get_obj_stream),
(gst_asf_demux_process_stream),
(gst_asf_demux_process_language_list),
(gst_asf_demux_process_ext_stream_props),
(gst_asf_demux_process_queued_extended_stream_objects),
(gst_asf_demux_process_object), (gst_asf_demux_change_state):
* gst/asfdemux/gstasfdemux.h:
Parse extended stream properties objects and stream objects
hidden inside them (but delay creation of the appropriate
pads until after all the 'normal' stream objects have been
dealt with) (#343763). Also parse language list object.
2006-07-14 13:02:53 +00:00
Grzegorz Lukasik
4c6764332a gst/asfdemux/gstasfdemux.c: Fix typo. Closes #347029.
Original commit message from CVS:
Patch by: Grzegorz Lukasik <hauserx at gmail dot com>
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_add_video_stream),
(gst_asf_demux_process_segment):
Fix typo. Closes #347029.
2006-07-09 14:07:31 +00:00
Tim-Philipp Müller
05342dd632 gst/asfdemux/gstasfdemux.c: Skip chunks for unknown streams properly. Fixes broken sound and/or video for files that ...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_process_chunk):
Skip chunks for unknown streams properly. Fixes broken sound
and/or video for files that have additional streams that
we don't recognise yet (e.g. if they are embedded in extended
stream properties). Partly fixes #343763.
2006-07-08 20:29:56 +00:00
Tim-Philipp Müller
0a27252bb5 gst/asfdemux/: Add some more GUIDs and make debug log more readable and easier to follow when parsing the headers.
Original commit message from CVS:
* gst/asfdemux/asfheaders.c:
* gst/asfdemux/asfheaders.h:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_identify_guid),
(gst_asf_demux_process_header), (gst_asf_demux_push_obj),
(gst_asf_demux_pop_obj), (gst_asf_demux_process_object),
(gst_asf_demux_change_state):
* gst/asfdemux/gstasfdemux.h:
Add some more GUIDs and make debug log more readable
and easier to follow when parsing the headers.
2006-07-07 19:26:40 +00:00
Tim-Philipp Müller
3142e1a289 gst/asfdemux/gstasfdemux.*: Handle unknown codec IDs/fourccs properly (#345879); send tag events after newsegment eve...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_setup_pad),
(gst_asf_demux_add_audio_stream), (gst_asf_demux_add_video_stream),
(gst_asf_demux_push_buffer):
* gst/asfdemux/gstasfdemux.h:
Handle unknown codec IDs/fourccs properly (#345879); send tag
events after newsegment event; fix use of GST_FOURCC_FORMAT
macro.
2006-06-28 11:20:03 +00:00
Tim-Philipp Müller
1efcd72335 gst/asfdemux/gstasfdemux.c: Fix silly bug when reading metadata (#341254).
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_get_string):
Fix silly bug when reading metadata (#341254).
2006-05-10 14:40:03 +00:00
Maciej Katafiasz
3b88021c7e Add semicolons after GST_BOILERPLATE[_FULL] so that indent doesn't mess up following lines.
Original commit message from CVS:
Add semicolons after GST_BOILERPLATE[_FULL] so that indent doesn't mess up following lines.
2006-05-06 00:18:31 +00:00
Fabrizio Gennari
7a8e48e17c gst/asfdemux/gstasfdemux.c: Send newsegment event only once per pad, fixes #336550.
Original commit message from CVS:
Patch by: Fabrizio Gennari  <fabrizio dot ge at tiscali dot it>
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_sink_event),
(gst_asf_demux_push_buffer):
Send newsegment event only once per pad, fixes #336550.
2006-04-07 09:14:26 +00:00
Fabrizio Gennari
08c4bd4168 gst/asfdemux/gstasfdemux.*: Subtract first timestamp from timestamps, so that stream starts from 0; makes live stream...
Original commit message from CVS:
Patch by: Fabrizio Gennari  <fabrizio dot ge at tiscali dot it>
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_setup_pad),
(gst_asf_demux_process_chunk):
* gst/asfdemux/gstasfdemux.h:
Subtract first timestamp from timestamps, so that
stream starts from 0; makes live streams that don't
start at 0 work again (fixes #317310, #336097).
2006-03-27 10:39:03 +00:00
Fabrizio
3de20e5147 gst/asfdemux/gstasfdemux.c: Read packet size, sequence and padsize in right order again
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_handle_data):
Read packet size, sequence and padsize in right order again
(fixes #332796; patch by: Fabrizio Gennari).
2006-03-01 09:55:49 +00:00
Tim-Philipp Müller
7858b15ed2 gst/asfdemux/gstasfdemux.c: In sink event handler, release object lock again _before_ sending EOS event downstream (#...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_sink_event):
In sink event handler, release object lock again
_before_ sending EOS event downstream (#313838).
2006-02-17 17:58:44 +00:00
Edward Hervey
d2445ecbf4 gst/asfdemux/gstasfdemux.c: Do not error out on non-recognized streams. Ignore them and allow playback of the other s...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_process_stream):
Do not error out on non-recognized streams. Ignore them and allow
playback of the other streams.
2006-02-17 10:24:56 +00:00
Edward Hervey
821effe791 gst/asfdemux/gstasfdemux.c: Take into account the file properties preroll value for timestamping/newsegment. It's wei...
Original commit message from CVS:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_process_file):
Take into account the file properties preroll value for
timestamping/newsegment. It's weird this value was commented out.
2006-02-17 09:54:43 +00:00
Tim-Philipp Müller
366b006b7d asfdemux ported to 0.10. Does still need a bit of work (seems like there's something funky going on when timestamping...
Original commit message from CVS:
* configure.ac:
* gst/asfdemux/asfheaders.c: (gst_asf_identify_guid),
(gst_asf_get_guid_nick):
* gst/asfdemux/asfheaders.h:
* gst/asfdemux/gstasf.c: (plugin_init):
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_base_init),
(gst_asf_demux_class_init), (gst_asf_demux_init),
(gst_asf_demux_sink_event), (gst_asf_demux_handle_seek_event),
(gst_asf_demux_handle_src_event),
(gst_asf_demux_get_current_offset), (gst_asf_demux_chain),
(gst_asf_demux_skip_bytes), (gst_asf_demux_identify_guid),
(gst_asf_demux_get_uint8), (gst_asf_demux_get_uint16),
(gst_asf_demux_get_uint32), (gst_asf_demux_get_uint64),
(gst_asf_demux_get_var_length), (gst_asf_demux_get_buffer),
(gst_asf_demux_get_bytes), (gst_asf_demux_get_string),
(gst_asf_demux_get_guid), (gst_asf_demux_get_obj_file),
(gst_asf_demux_get_bitrate_record),
(gst_asf_demux_get_obj_comment), (gst_asf_demux_get_obj_header),
(gst_asf_demux_get_obj_header_ext), (gst_asf_demux_get_obj_stream),
(gst_asf_demux_get_replicated_data), (gst_asf_demux_get_obj_data),
(gst_asf_demux_get_obj_data_correction),
(gst_asf_demux_get_stream_audio),
(gst_asf_demux_get_stream_correction),
(gst_asf_demux_get_stream_video),
(gst_asf_demux_get_stream_video_format),
(gst_asf_demux_get_stream), (gst_asf_demux_setup_pad),
(gst_asf_demux_add_audio_stream), (gst_asf_demux_add_video_stream),
(gst_asf_demux_process_stream),
(gst_asf_demux_get_gst_tag_from_tag_name),
(gst_asf_demux_commit_taglist),
(gst_asf_demux_process_ext_content_desc),
(gst_asf_demux_get_object_header), (gst_asf_demux_process_data),
(gst_asf_demux_process_header), (gst_asf_demux_process_file),
(gst_asf_demux_process_comment),
(gst_asf_demux_process_bitrate_props_object),
(gst_asf_demux_process_header_ext), (gst_asf_demux_process_object),
(gst_asf_demux_descramble_segment),
(gst_asf_demux_element_send_event),
(gst_asf_demux_send_event_unlocked), (gst_asf_demux_push_buffer),
(gst_asf_demux_process_chunk), (gst_asf_demux_process_segment),
(gst_asf_demux_handle_data), (gst_asf_demux_parse_data),
(gst_asf_demux_get_src_query_types),
(gst_asf_demux_handle_src_query), (gst_asf_demux_change_state):
* gst/asfdemux/gstasfdemux.h:
asfdemux ported to 0.10. Does still need a bit of work (seems like
there's something funky going on when timestamping video frames).
The seeking code is likely to make Wim cry, but hey, at least it
compiles.
2006-02-15 15:48:07 +00:00
Thomas Vander Stichele
e8805d7869 fix up error domains, error strings, and use of translation
Original commit message from CVS:
2006-01-20  Thomas Vander Stichele  <thomas at apestaart dot org>

* ext/dvdnav/dvdnavsrc.c: (if):
* ext/dvdread/stream_labels.c:
* gst/asfdemux/gstasfdemux.c: (gst_asf_demux_process_segment):
* gst/realmedia/rmdemux.c: (gst_rmdemux_loop):
fix up error domains, error strings, and use of translation
* po/POTFILES.in:
fix up this file, even though none of them are actually marked
for build yet.
2006-01-20 14:18:20 +00:00