David Schleef
9469aa92f3
baseparse: Create baseparse library
2011-04-08 18:07:16 +01:00
Mark Nauwelaerts
f3f44f81c3
baseparse: tune QUERY_SEEKING response
...
Even if we currently do not have a duration yet, assume seekable if
it looks like we'll likely be able to determine it later on
(which coincides with needed information to perform seeking).
Fixes #641047 .
2011-04-08 18:07:16 +01:00
Arun Raghavan
f0435d6fd6
baseparse: Update min/max bitrate before first posting them
...
This avoids posting an initial min-bitrate of G_UINTMAX and max-bitrate
of 0.
https://bugzilla.gnome.org/show_bug.cgi?id=641857
2011-04-08 18:07:16 +01:00
Arun Raghavan
7f4a61b56c
mpegaudioparse: Post CBR bitrate as nominal bitrate
...
Even if VBR headers are missing, we can't guarantee that a stream is in
fact a CBR stream, so it's safer to let baseparse calculate the average
bitrate rather than assume a CBR stream. However, in order to make
/some/ metadata available before the requisite number of frames have
been parsed, this posts the bitrate from the non-VBR headers as the
nominal bitrate.
https://bugzilla.gnome.org/show_bug.cgi?id=641858
2011-04-08 18:07:16 +01:00
Mark Nauwelaerts
cc1b5ded6d
amrparse: a valid amr-wb frame should not have reserved frame type index
...
See #639715 .
2011-04-08 18:07:16 +01:00
Mark Nauwelaerts
d1bea6361b
ac3parse: improve handling of dependent substream frames
...
In particular, timestamps of these should track main-stream timestamps.
2011-04-08 18:07:16 +01:00
Mark Nauwelaerts
3f2ffc9e53
baseparse: tune default duration estimate update interval
...
Rather than a fixed default frame count, estimate frame count to aim for
an interval duration depending on fps if available, otherwise use old
fixed default.
2011-04-08 18:07:16 +01:00
Mark Nauwelaerts
fa16a9a0ef
baseparse: reverse playback; mind keyframes for fragment boundary
2011-04-08 18:07:16 +01:00
Mark Nauwelaerts
39da316386
amrparse: properly check for sufficient available data prior to access
2011-04-08 18:07:16 +01:00
Mark Nauwelaerts
fd064765a7
baseparse: ensure non-empty candidate frames
2011-04-08 18:07:16 +01:00
Mark Nauwelaerts
2e76193c56
baseparse: clarify some debug statements
2011-04-08 18:07:15 +01:00
Mark Nauwelaerts
054621a58c
baseparse: properly track upstream timestamps
...
... rather than with a delay.
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
6df2a01762
baseparse: need proper frame duration to obtain sensible frame bitrate
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
1749b527c1
baseparse: proper initial values for index tracking variables
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
6616883390
baseparse: arrange for consistent event handling
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
de1d89dba6
baseparse: header style cleaning
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
9f5840572e
baseparse: provide some more initial frame metadata in parse_frame
...
... and document accordingly.
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
551eefb757
baseparse: refactor passthrough into format flags
...
Also add a format flag to signal baseparse that subclass/format can provide
(parsed) timestamp rather than an estimated one. In particular, such "strong"
timestamp then allows to e.g. determine duration.
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
4163969a24
baseparse: introduce a baseparse frame to serve as context
...
... and adjust subclass parsers accordingly
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
b45821c83f
baseparse: restrict duration scanning to pull mode and avoid extra set_caps call
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
9a76c1d8cd
baseparse: update some documentation
...
Also add some more debug.
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
32f57133ac
baseparse: allow increasing min_size for current frame parsing only
...
Also check that subclass actually either directs to skip bytes or
increases expected frame size to avoid going nowhere in bogus
indefinite looping.
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
d9def3d05d
baesparse: fix refactor regression in loop based parsing
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
9d9d9beb04
baseparse: pass all available data to subclass rather than minimum
...
Also reduce some adapter calls and add a few debug statements.
2011-04-08 18:07:14 +01:00
Mark Nauwelaerts
feaf23f8bd
baseparse: fix reverse playback handling
2011-04-08 18:07:13 +01:00
Mark Nauwelaerts
95c2251390
baseparse: minor typo and debug statement cleanup
2011-04-08 18:07:13 +01:00
Mark Nauwelaerts
d1bb142b68
baseparse: reduce locking
...
... which is either already mute and/or implicitly handled by STREAM_LOCK.
2011-04-08 18:07:13 +01:00
Mark Nauwelaerts
ce23c62f58
baseparse: avoid loop in frame locating interpolation
2011-04-08 18:07:13 +01:00
Mark Nauwelaerts
eafcdf67b9
flacparse: mind gst_buffer_unref not liking NULL
...
Fixes #639950 .
2011-04-08 18:07:13 +01:00
Thiago Santos
244f747df2
audioparsers: baseparse: Be careful to not lose the event ref
...
Don't unref the event if it hasn't been handled, because the caller
assumes it is still valid and might reuse it.
I ran into this problem when transcoding an AVI (with mp3 inside)
to gpp.
https://bugzilla.gnome.org/show_bug.cgi?id=639555
2011-04-08 18:07:13 +01:00
Tim-Philipp Müller
bb8f0d3b4c
dcaparse: fix sync word for 14-bit little endian coding
...
Fix copy'n'paste bug that made us look for the raw little endian
sync word twice instead of looking for the 14-bit LE sync word
as well. Fixes parsing of such streams (see #636234 for sample file).
2011-04-08 18:07:13 +01:00
Tim-Philipp Müller
a8c854374b
docs: minor baseparse docs/comment fixes
...
Remove copy'n'paste leftovers.
2011-04-08 18:07:13 +01:00
Edward Hervey
6fbdfa07a8
flacparse: Fix unitialized variable on macosx
2011-04-08 18:07:13 +01:00
Mark Nauwelaerts
cf5b01a55f
ac3parse: relax bsid checking
...
... to the widest possible spec interpretation.
Fixes #637062 .
2011-04-08 18:07:13 +01:00
Mark Nauwelaerts
d2a9daec36
audioparsers: update some documentation
2011-04-08 18:07:13 +01:00
Mark Nauwelaerts
cfbc40aca7
mpegaudioparse: add to documentation
2011-04-08 18:07:13 +01:00
Mark Nauwelaerts
d1d1239fe4
dcaparse: add to documentation
2011-04-08 18:07:13 +01:00
Mark Nauwelaerts
0bb654ed66
baseparse: increase keyframe awareness
...
... which is not particular relevant for audio parsing, but more so
in video cases. In particular, auto-determine if dealing with video (caps).
2011-04-08 18:07:13 +01:00
Mark Nauwelaerts
f7de334d61
ac3parse: use proper EAC-3 caps
2011-04-08 18:07:12 +01:00
Mark Nauwelaerts
b8af812987
baseparse: avoid unexpected stray metadata
2011-04-08 18:07:12 +01:00
Mark Nauwelaerts
24cf864c91
baseparse: use proper _NONE output value when applicable
2011-04-08 18:07:12 +01:00
Edward Hervey
1e71d31e67
audioparsers: Remove dead assignments
2011-04-08 18:07:12 +01:00
Andoni Morales Alastruey
5bfc92714e
audioparse: fix possible division-by-zero
...
https://bugzilla.gnome.org/show_bug.cgi?id=635786
2011-04-08 18:07:12 +01:00
Mark Nauwelaerts
a45019fdd6
baseparse: use correct offset when adding index entry
...
... bearing in mind that BUFFER_OFFSET is media specific and may not
reflect the basic offset after having been parsed.
2011-04-08 18:07:12 +01:00
Mark Nauwelaerts
76b322a429
baseparse: enhancements for timestamp marked framed formats
...
That is, as such formats allow subclass to extract position from frame,
it is possible to extract duration (if not otherwise provided)
from (near) last frame, and a seek can fairly accurately target the required
position.
Fixes #631389 .
2011-04-08 18:07:12 +01:00
Mark Nauwelaerts
634d4de627
baseparse: refactor frame scanning peformed by _loop
2011-04-08 18:07:12 +01:00
Mark Nauwelaerts
563f1a136b
baseparse: slightly optimize sending of pending newsegment events
2011-04-08 18:07:12 +01:00
Mark Nauwelaerts
5eeb1f2e1f
baseparse: minor fixes and enhancements
...
Arrange for upstream as well as downstream flushing when seeking.
Also determine upstream size as well as seekability. Adjust some comments
to reality and employ debug statement in proper order.
2011-04-08 18:07:12 +01:00
Mark Nauwelaerts
3e50f0a3c9
aacparse: minor cleanups
2011-04-08 18:07:12 +01:00
Mark Nauwelaerts
31d387f7b5
aacparse: fix regression in ADIF src caps setting
2011-04-08 18:07:12 +01:00