Wim Taymans
d23fc81c43
basesrc: don't accidentally disable the pool
...
When we set a pool and it is the same as the old pool, don't disable the pool.
2011-07-15 16:04:11 +01:00
Tim-Philipp Müller
59441b36b6
baseparse: fix printf format in debug message
2011-07-14 12:45:33 +01:00
Mark Nauwelaerts
27313d05c1
basesink: unset PLAYING transition flag when transition completed
2011-07-13 11:40:26 +02:00
Mark Nauwelaerts
e3446a74e0
baseparse: eat incoming caps event
...
... as it is typically up to baseclass to set proper src caps.
2011-07-11 11:59:18 +02:00
Mark Nauwelaerts
c8b9275578
basesink: try harder to arrange increasing position reporting
...
... rather than having a momentary decreasing one while transitioning
to PLAYING.
Fixes #628021 .
2011-07-11 11:14:02 +02:00
Tim-Philipp Müller
f47c3472df
baseparse: fix invalid memory access in debug messages
...
Don't use buffers that we've given away or unrefed in debug messages.
2011-07-07 14:57:18 +01:00
Wim Taymans
c87375a813
basesrc: fix after merge
2011-07-07 11:14:34 +02:00
Wim Taymans
b171259612
Merge branch 'master' into 0.11
...
Conflicts:
libs/gst/base/gstbasesrc.c
2011-07-07 11:13:19 +02:00
Tim-Philipp Müller
0a6ec83336
gst: make compiler warn about unstable API if GST_USE_UNSTABLE_API is not defined
...
And define it in our own build.
2011-07-05 09:46:43 +01:00
Mark Nauwelaerts
0993102834
basesrc: do not sneakily mess with current offset when updating length
2011-06-30 17:59:27 +02:00
Mark Nauwelaerts
c79f8a52af
basesrc: unref allocation query when no longer needed
2011-06-28 22:18:46 +02:00
Koop Mast
c1983b9939
basetransform: remove redundant ()
...
See #653137
2011-06-22 17:09:52 +02:00
Koop Mast
ef1b2b0e8f
baseparse: fix seekstop
...
See #653137
2011-06-22 17:05:27 +02:00
Wim Taymans
6da2a33b7a
tags: Remove crazy tag messages
...
Don't mix messages and pads and tags.
Make the sink post tag messages when a tag event is received.
Since tags are sticky on pads now, they can be retrieved from there
when needed.
2011-06-22 16:16:56 +02:00
Wim Taymans
3884badea6
memory: rename GstMemoryAllocator -> GstAllocator
...
simplify the name of the allocator object.
2011-06-22 11:42:46 +02:00
Wim Taymans
c6a3878369
Merge branch 'master' into 0.11
...
Conflicts:
configure.ac
win32/common/config.h
win32/common/gstversion.h
2011-06-21 17:54:38 +02:00
Wim Taymans
9c3bd65ba7
basesrc: improve debugging
2011-06-21 17:47:23 +02:00
Wim Taymans
69409f1ec8
basetransform: activate the bufferpool
...
always activate the bufferpool, even if we get it from the allocation
query.
2011-06-20 17:32:47 +02:00
Wim Taymans
fc5b0b09da
basesrc: always activate the pool we get
...
Activate the pool when we get it from the allocation query.
2011-06-20 17:32:11 +02:00
Wim Taymans
3822eea7cf
basetransform: inprove allocation handling
...
Add vmethod for subclasses to influence the pool and allocator.
Log when query fails.
Respect negotiated allocator and alignment.
2011-06-20 16:53:04 +02:00
Wim Taymans
9c67925fb7
basesrc: Improve logging
...
Log when things fail.
Fix a query leak.
2011-06-20 16:53:04 +02:00
Philip Jägenstedt
9f0e066102
basesink: Fix typo in documentation
...
Fixes #652577 .
2011-06-17 01:54:31 -07:00
Wim Taymans
c4f35cb2e0
basesrc: fix refcounting problem
2011-06-15 16:56:30 +02:00
Wim Taymans
1ea2722180
Merge branch 'master' into 0.11
2011-06-13 19:10:00 +02:00
Wim Taymans
54fd50bfe1
buffer: add index to _take_memory()
...
Add an index to gst_buffer_take_memory() so that we can also insert memory at a
certain offset. This is mostly interesting to prepend a header memory block to
the buffer.
2011-06-13 16:31:53 +02:00
Wim Taymans
844e8aefaa
basesrc: Allocator buffers from negotiated allocator
...
Allocate buffers from the negotiated allocator or bufferpool.
Handle the state of the bufferpool when flushing.
Add fill method to pushsrc.
2011-06-13 12:07:03 +02:00
Wim Taymans
3977991c9d
basesrc: negotiate allocation
...
Add vmethod to configure allocation methods.
Remove some unused variables
2011-06-13 10:21:53 +02:00
Wim Taymans
6ca5d44704
bufferpool: remove postfix parameter
...
Remove the postfix parameter, it's not used and can be done differently.
2011-06-11 18:52:42 +02:00
Wim Taymans
94ae04f098
basesrc: use new _check_reconfigure() method
2011-06-10 17:32:48 +02:00
Wim Taymans
b27ee30a35
buffer: make new _buffer_allocate method
...
Make a new method to allocate a buffer + memory that takes the allocator and the
alignment as parameters. Provide a macro for the old method but prefer to use
the new method to encourage plugins to negotiate the allocator properly.
2011-06-10 13:49:23 +02:00
Tim-Philipp Müller
954bcb09c7
docs: update for gst_base_src_set_dynamic_size
...
Add to sections file and add Since: marker. Also update
win32 .def file.
API: gst_base_src_set_dynamic_size()
2011-06-10 12:45:37 +01:00
Wim Taymans
c35e0de65e
basesrc: add fill vmethod to basesrc
...
Add a new fill virtual method to basesrc. The purpose of this method is to fill
a provided buffer with data.
Add a default implementation of the create method that allocates a buffer and
calls the fill method on it. This would allow the base class to implement
bufferpool and allocator negotiation on behalf of the subclasses.
Fix the blocksize property.
Make filesrc use the new fill method.
2011-06-10 13:04:23 +02:00
Wim Taymans
bbfec45ecc
event: add reset_time boolean to flush_stop event
...
Add a boolean to the flush_stop event to make it possible to implement flushes
that don't reset_time.
Make basesink post async_done with the reset_time property from the flush stop
event.
Fix some unit tests
2011-06-10 11:55:08 +02:00
Wim Taymans
4d6e4ea9e6
Merge branch 'master' into 0.11
...
Conflicts:
libs/gst/base/gstbasesrc.c
2011-06-09 12:01:02 +02:00
Mark Nauwelaerts
f8168cd75f
basesrc: add dynamic size handling
...
This allows subclass to indicate that size reported by src may not be static
and should as such be updated regularly, rather than only when really
needed.
Particular examples are filesrc or fdsrc reading from a file that is still
growing (e.g. being downloaded).
Fixes #652037 .
2011-06-08 20:16:25 +02:00
Mark Nauwelaerts
c040305b8c
Revert "basesrc: Send an update NEWSEGMENT event downstream if the duration changes"
...
This reverts commit 934faf163c
.
Original commit leads to possibly sending newsegment event downstream
in pull mode. In push mode, quite some downstream elements
are likely to only expect newsegment event following a seek they performed
and as such may have their state messed up.
2011-06-08 20:14:16 +02:00
Wim Taymans
b5d4529fa4
basesink: inline the clip segment
2011-06-08 18:35:16 +02:00
Wim Taymans
3cb8b33935
message: move the new_base_time flag to async_done
...
Move the flag to indicate that a new_base_time should be distributed to the
pipeline, from the async_start to the async_done message. This would allow us to
decide when to reset the pipeline time based on other reasons than the
FLUSH_START event.
The main goal eventually is to make the FLUSH events not reset time at all but
reset the time based on the first buffer or segment that prerolls the pipeline
again.
2011-06-08 13:45:19 +02:00
Wim Taymans
a767bf2bf9
caps: use the caps event
...
Use the caps event instead of gst_pad_set_caps() and the setcaps function
2011-06-07 09:43:20 +02:00
Edward Hervey
69800aa307
basesink: Don't accept segments after EOS
...
And refactor the code slightly to avoid code duplication.
This solves a regression introduced by bdbc0693
2011-06-06 11:20:29 +02:00
Tim-Philipp Müller
4b920eb5d2
docs: update for API changes
...
Also remove GST_PAD_CHECKGETRANGEFUNC macro
2011-06-05 18:57:56 +01:00
Wim Taymans
3cbeb3848c
baseparse: use caps event instead of setcaps
2011-06-02 19:24:26 +02:00
Edward Hervey
9b1c84d5ac
basetransform: Use local priv variable instead of trans->priv
2011-05-31 18:31:53 +02:00
Edward Hervey
ceb86a586e
gst: Remove obvious dead assignments
2011-05-31 18:30:30 +02:00
Wim Taymans
690c81b95d
basesrc: remove deprecated clean shutdown method
2011-05-27 17:28:34 +02:00
Sebastian Dröge
26a5a877ff
basesrc: Fix for SEGMENT event API changes
2011-05-27 14:02:37 +02:00
Sebastian Dröge
30a7fd7b4d
Merge branch 'master' into 0.11
2011-05-27 13:58:26 +02:00
Sebastian Dröge
7295f3e2f6
basetransform: Pass the complete caps to transform_caps
...
Instead of passing it structure by structure. This allows
better optimized transform_caps functions and allows better
transformation decisions.
See bug #619844 .
2011-05-27 11:37:24 +02:00
Sebastian Dröge
934faf163c
basesrc: Send an update NEWSEGMENT event downstream if the duration changes
...
This allows streaming the complete file for files that have grown since
streaming started.
Fixes bug #647940 .
2011-05-27 09:05:46 +02:00
Sebastian Dröge
5076688c1f
pushsrc: Fix infinite recursion in pushsrc query handler
2011-05-26 14:14:13 +02:00
Wim Taymans
2c221a5729
feature: use object name
...
Remove the name property from the plugin feature and port code to use the object
name instead.
2011-05-24 18:17:24 +02:00
Wim Taymans
7e6d579301
scheduling: port to new scheduling query
2011-05-24 17:39:56 +02:00
Wim Taymans
7754d8d7ba
transform: fixes for bufferpool handling
...
Don't error out when the allocation query returns success.
Do bufferpool query after we pushed the caps event downstream so that we can get
a good bufferpool suggestion.
Also proxy the bufferpool query downstream when we operate in in_place mode.
2011-05-23 18:15:00 +02:00
Wim Taymans
35cc371363
transform: reset reconfigure state
...
When we negotiate new caps, reset the reconfigure state.
2011-05-23 16:53:01 +02:00
Wim Taymans
1cb7523efa
basetransform: WIP handle bufferpool
2011-05-23 15:38:31 +02:00
Wim Taymans
4e13568d27
basesrc: avoid calling _set_caps() on the srcpad
...
Avoid installing a setcaps function on the srcpad and calling the setcaps
function, we can do more efficiently with sending the event ourself and calling
our vmethod.
2011-05-21 19:06:08 +02:00
Wim Taymans
d33909302e
basetransform: remove some more code
...
Remove some more unused code from basetransform.
Prepare for implementing bufferpools.
2011-05-20 16:01:57 +02:00
Sebastian Dröge
ce216c1406
Merge branch 'master' into 0.11
2011-05-20 13:06:57 +02:00
Sebastian Dröge
1d57e46dbd
basesink: Only reinit the cached GstClockID if it is for the same clock
...
The clock might have changed since the clock ID was created and in
that case we have to request a new one.
2011-05-20 13:05:04 +02:00
Sebastian Dröge
a46c9c2a62
event: Make SEGMENT event parsing API more consistent with the others
2011-05-18 16:56:43 +02:00
Wim Taymans
ad0693f47d
basetransform: relax caps check
...
Also run the caps transform function on ANY caps, like we used to do before.
This makes sure that capsfilter has a chance to filter ANY caps as well.
2011-05-18 16:49:28 +02:00
Wim Taymans
e39182a085
Merge branch 'master' into 0.11
...
Conflicts:
gst/gstminiobject.c
gst/gstpad.c
gst/gstpad.h
gst/gstplugin.h
libs/gst/base/gstbaseparse.c
2011-05-18 13:14:57 +02:00
Mark Nauwelaerts
35567592ef
baseparse: maintain frame state during frame parsing round
...
See #650093 .
2011-05-18 09:49:35 +02:00
Mark Nauwelaerts
af5061e943
baseparse: provide latency query support
2011-05-18 09:49:22 +02:00
Mark Nauwelaerts
82a6cb39ae
baseparse: make minimum frame size handling more efficient and convenient
...
While some formats allow subclass to determine a specific subsequent
needed frame size, others may to need to scan for markers and can only
request 'additional data' by whatever reasonable available step.
In push mode, trying to minimize additional latency leads to step size
being the next input buffer. In pull mode, any reasonable step size
(such as already used by buffer caching) can be applied.
2011-05-18 09:49:12 +02:00
Mark Nauwelaerts
ee3344824c
baseparse: set correct buffer size
2011-05-18 09:49:02 +02:00
Sebastian Dröge
5f2cd2b0a3
base: Update for caps/pad template related API changes
2011-05-17 13:14:12 +02:00
Sebastian Dröge
3d2127f865
Revert "query: allow _make_writable on query handlers"
...
This reverts commit cf4fbc005c
.
This change did not improve the situation for bindings because
queries are usually created, then directly passed to a function
and not stored elsewhere, and the writability problem with
miniobjects usually happens with buffers or caps instead.
2011-05-17 11:21:41 +02:00
Wim Taymans
53e4d1a007
basetransform: fix buffer refcounting
...
When we fail to allocate an output buffer, set the buffer pointer to NULL or
else the calling function will try to unref it.
Remove some old comments
2011-05-16 18:48:20 +02:00
Wim Taymans
115c34badd
basesink: handle more formats
...
Don't hardcode GST_FORMAT_TIME in places, we can work with many formats.
2011-05-16 17:09:06 +02:00
Sebastian Dröge
b935a814d9
Merge branch 'master' into 0.11
...
Conflicts:
configure.ac
docs/gst/gstreamer-sections.txt
gst/gstbin.c
gst/gstelement.c
gst/gstelement.h
gst/gstghostpad.c
gst/gstminiobject.c
gst/gstminiobject.h
libs/gst/base/gstbasesrc.c
libs/gst/base/gstbasetransform.c
plugins/elements/gstinputselector.c
tests/check/gst/gstminiobject.c
2011-05-16 16:53:04 +02:00
Sebastian Dröge
bdf9022861
base: Improve negotiation with new getcaps() filter
2011-05-16 15:33:10 +02:00
Wim Taymans
bdbc069348
Rework GstSegment handling
...
Improve GstSegment, rename some fields. The idea is to have the GstSegment
structure represent the timing structure of the buffers as they are generated by
the source or demuxer element.
gst_segment_set_seek() -> gst_segment_do_seek()
Rename the NEWSEGMENT event to SEGMENT.
Make parsing of the SEGMENT event into a GstSegment structure.
Pass a GstSegment structure when making a new SEGMENT event. This allows us to
pass the timing info directly to the next element. No accumulation is needed in
the receiving element, all the info is inside the element.
Remove gst_segment_set_newsegment(): This function as used to accumulate
segments received from upstream, which is now not needed anymore because the
segment event contains the complete timing information.
2011-05-16 11:37:52 +02:00
Sebastian Dröge
e8688b62b2
basetransform: When trying to fixate the sink suggestion prefer its structure order
2011-05-14 11:39:34 +02:00
Sebastian Dröge
f56c6e1225
basetransform: In getcaps() prefer the caps order and caps of downstream if possible
2011-05-14 11:39:34 +02:00
Sebastian Dröge
b4bed6e09e
basetransform: Prefer caps order given by the subclass of the template caps order
2011-05-14 11:39:34 +02:00
Vincent Penquerc'h
03050fd71d
basesrc: do not set first buffer timestamp to 0 for live sources
...
Doing so avoids a large timestamp gap between first and second buffer
for live sources which take time to start up.
The first buffer now has a "live" timestamp based on the running time,
as other buffers do.
https://bugzilla.gnome.org/show_bug.cgi?id=649369
2011-05-12 18:10:14 +01:00
Wim Taymans
a59bc0ab02
basetransform: remove obsolete code
...
Remove some obsolete code.
Don't try to reconfigure when we don't have sink caps.
2011-05-11 18:09:03 +02:00
Sebastian Dröge
ef673656b7
basetransform: Implement support for pad reconfiguration again
2011-05-11 15:26:02 +02:00
Wim Taymans
cf4fbc005c
query: allow _make_writable on query handlers
...
Pass a GstQuery ** to the query handlers so that they can make the query
writable before using a setter on it.
Port code to new API.
2011-05-10 18:36:33 +02:00
Wim Taymans
7f24a48387
event: _qos_full -> _qos
2011-05-09 18:48:55 +02:00
Wim Taymans
c07b57fc05
segment: remove _full version
...
Rename the _full versions of the functions to the normal function names.
2011-05-09 17:51:07 +02:00
Wim Taymans
d63829fc9a
segment: remove abs_rate from segment structure
...
Remove the abs_rate field from the segment structure, we can trivially compute
it when needed.
2011-05-09 16:39:13 +02:00
Wim Taymans
4eed658be1
basetransform: Use CAPs event
...
Use the caps event to configure basetransform.
Remove force_alloc hack, we don't need this in 0.11 with new upstream
negotiation.
Avoid getting some pad caps.
2011-05-09 15:08:51 +02:00
Wim Taymans
f127a416fa
basesink: add some more debug
2011-05-09 15:08:51 +02:00
Wim Taymans
24573211c6
Merge branch 'master' into 0.11
2011-05-08 13:14:55 +02:00
Wim Taymans
d34ca6140b
basesink: use CAPS event instead of setcaps function
2011-05-08 13:07:13 +02:00
Wim Taymans
ba6b915651
base: avoid using buffer caps
...
Comment all code using buffer caps.
Rework capsfilter code a little.
Fix some unit tests
2011-05-08 12:46:17 +02:00
Tim-Philipp Müller
dccde2652f
baseparse: don't post loads of empty taglists
...
Only post bitrate updates if there's something to post, don't
post empty taglists if nothing changed.
2011-05-06 23:44:15 +01:00
Wim Taymans
02e5feb2bf
pad: avoid using the old GST_PAD_CAPS
...
Don't use GST_PAD_CAPS but instead use the new gst_pad_get_current_caps()
method.
Avoid setting caps on buffers.
2011-05-06 19:04:54 +02:00
Wim Taymans
fb3da828e5
element: rename gst_element_lost_state_full()
...
Rename gst_element_lost_state_full() to gst_element_lost_state() and
remove the old method name.
2011-05-06 12:19:16 +02:00
Sebastian Dröge
0069dc08ec
basetransform: Don't get the parent twice in the setcaps function
2011-05-05 18:21:21 +02:00
Sebastian Dröge
aebe4a3c13
basetransform: In getcaps() prefer the caps order and caps of downstream if possible
2011-05-05 15:22:08 +02:00
Sebastian Dröge
a6c1cbe69a
basetransform: Prefer caps order given by the subclass of the template caps order
2011-05-05 15:20:10 +02:00
Sebastian Dröge
07f59f5404
basesrc: Use the reconfigure flag on the pad instead of the event
2011-05-05 15:20:02 +02:00
Sebastian Dröge
1cc95da945
basetransform: Use new reconfigure flag on the pads instead of the reconfigure event
2011-05-05 15:19:56 +02:00
Sebastian Dröge
0179530bf1
basesrc: Only renegotiate once after receiving a renegotiate event
...
Also make this threadsafe.
2011-05-05 15:04:16 +02:00
Thiago Santos
93904ef3ad
basesrc: Handle the new renegotiate event
...
Makes basesrc handle the new renegotiate event by using a
renegotiate flag.
2011-05-05 15:03:54 +02:00
Sebastian Dröge
24cef7aa2f
basetransform: Also call gst_base_transform_reconfigure() on renegotiate events
2011-05-05 15:02:56 +02:00
Thiago Santos
3baed25383
basetransform: Handle the new renegotiate event
...
Let basetransform push a renegotiate event upstream
when it gets a new suggestion
2011-05-05 15:02:46 +02:00