Sebastian Dröge
8c743fbc0f
basevideo: Fix locking, especially if both pads have different streaming threads
2011-08-18 10:23:32 +02:00
Sebastian Dröge
a081501a90
basevideo: Don't call g_type_class_peek_parent() in class_init
...
This is already done by the GObject boilerplate macro
2011-08-18 10:15:20 +02:00
Sebastian Dröge
6e4e4e107c
basevideodecoder: Use the cached video frame size instead of recalculating it
2011-08-09 10:43:55 +02:00
Sebastian Dröge
83c4e8814e
basevideodecoder: First inform subclass about resetting before resetting/freeing all internal state
...
The subclass might want to access the old state.
2011-07-11 12:59:07 +02:00
Sebastian Dröge
a59246c1d1
basevideodecoder: Track present position on discont before resetting it
2011-07-11 12:36:42 +02:00
Sebastian Dröge
08823f80d6
basevideodecoder: Also protect the list of pending frames from concurrent access when pushing all pendings events
2011-07-11 11:52:48 +02:00
Sebastian Dröge
81f4c9e8bf
basevideocodec: Protect access to the list of pending frames with the object lock
...
This is required if ::finish_frame() and all buffer output happens
on a different thread than the sinkpad streaming thread.
2011-07-11 11:28:40 +02:00
Sebastian Dröge
caed64c720
basevideodecoder: Set the correct lists to NULL after freeing
2011-07-11 09:35:25 +02:00
Sebastian Dröge
584859488b
basevideodecoder: Work with a copy of the GstVideoState in setcaps until the caps are accepted
...
Also fix a refcount problem with the codec_data.
2011-07-11 09:19:28 +02:00
Sebastian Dröge
e61d3d1a0c
basevideo: Move the utils from the codec header to its own header
2011-07-09 11:40:17 +02:00
Sebastian Dröge
5f55a74571
basevideo: Use GSlice for allocating GstVideoFrame and don't duplicate code in the decoder base class
2011-07-09 11:09:12 +02:00
Sebastian Dröge
f341386b64
basevideodecoder: Don't reorder serialized src events
...
And allow to drop EOS by the subclass if ::finish returns
DROPPED. This requires that the subclass sends EOS manually later.
Fixes bug #653544 .
2011-07-09 11:04:18 +02:00
Sebastian Dröge
525875727a
basevideo: Add the caps to the GstVideoState and clean up caps/codec_data properly
...
Having access to the caps in ::set_format can be useful if
non-standard caps fields like the h264 alignment must be accessed.
2011-07-09 11:02:01 +02:00
Sebastian Dröge
fc93c66d3b
basevideo: Add destroy notify for the coder_hook to prevent memory leaks
...
Fixes bug #654293 .
2011-07-09 11:00:28 +02:00
David Schleef
929603d56c
basevideodecoder: Better handling of invalid par
2011-06-04 14:09:29 -07:00
Debarshi Ray
03bb5dc8ba
Remove unused but set variables
...
This is needed to satisfy the new -Wunused-but-set-variable added in
GCC 4.6: http://gcc.gnu.org/gcc-4.6/changes.html
2011-05-30 22:52:03 +10:00
Mark Nauwelaerts
9b6e819247
basevideodecoder: handle missing framerate when calculating timestamp
2011-05-16 20:32:24 +02:00
Mark Nauwelaerts
cfe85ad780
basevideodecoder: debug code style fixes
2011-05-16 20:32:24 +02:00
Mark Nauwelaerts
2f6af91f09
basevideodecoder: tune parsing sink caps into video state
...
... to provide subclass with more information w.r.t. original caps.
2011-05-16 20:32:24 +02:00
Mark Nauwelaerts
380a443be4
basevideodecoder: video state reference to codec_data is not refcounted
...
... but rather implicitly valid as long as sink caps are not modified.
2011-05-16 20:32:24 +02:00
Mark Nauwelaerts
a1825bd5e2
basevideodecoder: improve glitch resilience
...
Provide a replacement for GST_ELEMENT_ERROR to avoid aborting at the first
atom out of place, while on the other hand not failing indefinitely.
2011-05-16 20:32:24 +02:00
Mark Nauwelaerts
1588ed321c
basevideodecoder: reverse playback support
2011-05-16 20:32:23 +02:00
Mark Nauwelaerts
1d99e8eafa
basevideodecoder: use basevideocodec discont field
2011-05-16 20:32:23 +02:00
Mark Nauwelaerts
1b151caf11
basevideodecoder: really and only set src pad caps whenever requested
...
... since subclass is expected to be wise enough to know when to do so.
2011-05-16 20:32:23 +02:00
Mark Nauwelaerts
550237347b
basevideodecoder: add some sanity enforcing
2011-05-16 20:32:23 +02:00
Mark Nauwelaerts
f72658435b
basevideodecoder: add documentation
...
... and remove some more stray unused code and methods.
2011-05-16 20:32:23 +02:00
Mark Nauwelaerts
a085acb586
basevideodecoder: streamline discont, flush and reset handling
...
... which is not to say there is no room for further tweaking ...
2011-05-16 20:32:23 +02:00
Mark Nauwelaerts
cfc65b14b1
basevideodecoder: remove (almost) unused fields
...
... and also some more unused code.
2011-05-16 20:32:22 +02:00
Mark Nauwelaerts
f591361d2f
basevideodecoder: invoke subclass start method at state change and use set_format
...
While this changes API slightly (e.g. actually uses set_format now), which is OK
for unstable API, it has following merits:
* symmetric w.r.t. stop at state change
* in line with other base class practice
* otherwise no subclass method at state change (global activation time)
Moreover, subclassese are either unaffected or trivially adjusted accordingly.
2011-05-16 20:32:22 +02:00
Mark Nauwelaerts
04a34b4ab7
basevideodecoder: fixup tweak
2011-05-16 20:32:22 +02:00
Mark Nauwelaerts
39fb2fa74a
basevideodecoder: add and tweak debug statements
2011-05-16 20:32:22 +02:00
Mark Nauwelaerts
fc705cf8fd
basevideodecoder: arrange for limited legacy seeking support
...
In particular, tweak src query and event handling to provide for
byte <-> time conversion.
2011-05-16 20:32:22 +02:00
Mark Nauwelaerts
3bd16a48b4
basevideo: cater for format conversion
2011-05-16 20:32:22 +02:00
Mark Nauwelaerts
4311909a53
basevideodecoder: fix copy-and-paste variable misnomer
2011-05-16 20:32:21 +02:00
Mark Nauwelaerts
7862d9ed35
basevideodecoder: subsume skip_frame into finish_frame
2011-05-16 20:32:21 +02:00
Mark Nauwelaerts
0230143cb8
basevideodecoder: remove unused code
2011-05-16 20:32:21 +02:00
Mark Nauwelaerts
8defa8cb49
basevideodecoder: code cleanup and debug style fixes
2011-05-16 20:32:21 +02:00
David Schleef
aa02a4074f
basevideo: Check if caps are set directly
...
Fixes #647854 .
2011-04-24 19:40:08 -07:00
Tim-Philipp Müller
fb67a0d126
basevideo: fix unused-but-set-variable warnings with gcc 4.6
2011-04-14 16:49:18 +01:00
David Schleef
293b0f7757
basevideo: Fix negotiation errors
2011-04-01 13:54:02 -07:00
David Schleef
83d6a5099b
basevideo: Add function to allocate src buffer
2011-04-01 13:54:02 -07:00
Sebastian Dröge
44da64d86b
basevideodecoder: Initialize some variables to make gcc 4.6 happy
2011-01-27 17:29:12 +01:00
David Schleef
fe50055715
basevideo: Move common fields/functions to basecodec
2010-10-15 16:30:57 -07:00
Sebastian Dröge
5816dbce6f
basevideodecoder: Don't use GST_FLOW_IS_SUCCESS()
2010-09-21 12:26:34 +02:00
David Schleef
9a62433722
basevideo: Remove check for old -base
2010-09-20 12:34:46 -07:00
David Schleef
62a9383527
basevideodecoder: add capture pattern handling
...
Move typical scan_for_sync() usage into base class, which just
calls gst_adapter_masked_scan_uint32().
2010-09-18 19:27:07 -07:00
David Schleef
dbbf1182dc
basevideodecoder: Don't blow away field information
...
Also, set field flags correctly.
2010-09-18 19:27:07 -07:00
David Schleef
7cd2e0dd3e
basevideo: Move deadline to frame structure
2010-09-18 19:27:07 -07:00
Sebastian Dröge
29943c87f8
basevideodecoder: Reset the segment on FLUSH_STOP and when going back to READY
2010-07-27 18:24:20 +02:00
Sebastian Dröge
ccbb765743
basevideodecoder: Fix memory leak
...
The timestamps are only used if the output adapter is used, not
if complete frames are provided by the decoder and finish_frame() is
called and even in the case where the output adapter is used they
might not be used and are leaked.
2010-07-10 15:50:50 +02:00