Commit graph

11953 commits

Author SHA1 Message Date
Wim Taymans
029ac4597e pad: rework sticky events a little
Update the design docs with some clear rules for how sticky events are
handled.
Reimplement the sticky tags, use a small structure to hold the event and its
current state (active or inactive).
Events on sinkpads only become active when the event function returned success
for the event.
When linking, only update events that are different.
Avoid making a copy of the event array, use the object lock to protect the event
array and release it only to call the event function. This will need to check
if something changed, later.
Disable a test in the unit test, it can't work yet.
2011-05-18 11:08:52 +02:00
Wim Taymans
93a80e2d91 pad: don't push sticky events on flush
Only allow serialized and non-flush events forward the sticky events.
2011-05-17 19:03:30 +02:00
Wim Taymans
8699bca39f test: reset pad caps properly 2011-05-17 18:23:22 +02:00
Wim Taymans
ba534c6416 pad: add more debug 2011-05-17 18:23:06 +02:00
Wim Taymans
5642f9db8c ghostpad: remove unused code
The code to make sure that caps are properly set on both pads, it now happens
automatically with the caps event.
2011-05-17 18:21:38 +02:00
Wim Taymans
7b8b93ad64 tests: fix tests
Remove the tests that handle incompatible formats, we don't want that anymore.
2011-05-17 17:53:00 +02:00
Wim Taymans
82cc487776 segment: handle wraparound better
Now that we use unsigned values for the segment, handle wraparound when seeking
better.
2011-05-17 17:51:58 +02:00
Wim Taymans
189980ec56 pad: remove unref, the object is NULL 2011-05-17 16:50:53 +02:00
Sebastian Dröge
b0d106fefa event: The RECONFIGURE element only exists in 0.11
Implementing it properly in 0.10 seems to be impossible.
2011-05-17 14:01:05 +02:00
Sebastian Dröge
eee515e5ad tests: Update for caps/pad template related API changes 2011-05-17 13:14:16 +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
c7789694fb gst: Update for caps/pad template related API changes 2011-05-17 13:14:04 +02:00
Sebastian Dröge
5f406248eb element: Consider GstPadTemplate as immutable
Don't copy the templates when creating subclasses but only increase
their refcount.
2011-05-17 13:13:51 +02:00
Sebastian Dröge
be00534878 padtemplate: Create pad templates with floating refs
And take ownership of the floating ref in gst_element_add_pad_template()
2011-05-17 13:13:51 +02:00
Sebastian Dröge
dd89e924db padtemplate: Improve reference handling of the template's caps
gst_pad_template_new() does not take ownership of the caps anymore.
2011-05-17 13:13:51 +02:00
Sebastian Dröge
b5bc5b459a pad: Let template related functions return new references
gst_pad_template_get_caps(), gst_pad_get_pad_template_caps()
and gst_pad_get_pad_template() return a new reference of the
caps or template now and the return value needs to be
unreffed after usage.
2011-05-17 12:00:18 +02:00
Sebastian Dröge
50f91c0825 Revert "event: example of how to optimize events"
This reverts commit fa28e2c5e6.

The optimization only has minimal impact on the performance and
makes everything more complex.
2011-05-17 11:45:46 +02:00
Sebastian Dröge
b7482263cc Revert "event: update the structure when needed"
This reverts commit 905100cdbe.
2011-05-17 11:45:42 +02:00
Sebastian Dröge
077cf48689 structure: Fix compilation 2011-05-17 11:22:58 +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
Sebastian Dröge
d0f34fe6b2 Revert "bin: Dereference GstQuery** before passing it to GST_QUERY_TYPE_NAME"
This reverts commit 437c92b403.
2011-05-17 11:21:41 +02:00
Sebastian Dröge
c096199fb9 Revert "ghostpad: fix g_return_* with new query"
This reverts commit 877c1c28ff.
2011-05-17 11:21:36 +02:00
Sebastian Dröge
e34c26b509 Merge branch 'master' into 0.11
Conflicts:
	win32/common/libgstreamer.def
2011-05-17 09:43:21 +02:00
Sebastian Dröge
b4dea3a1d3 structure: Make both parameters to gst_structure_is_equal() const 2011-05-17 09:35:54 +02:00
Sebastian Dröge
53ef31718d structure: Update Since markers to the correct version 2011-05-17 09:33:47 +02:00
Sebastian Dröge
a08a17dfbd structure: Add gst_structure_intersect()
API: gst_structure_intersect()
2011-05-17 09:33:04 +02:00
Edward Hervey
64725facb5 gststructure: Add gst_structure_can_intersect API
Allows checking if two structures can intersect without having to
go through GstCaps

API: gst_structure_can_intersect

https://bugzilla.gnome.org/show_bug.cgi?id=629300
2011-05-17 09:28:06 +02:00
Edward Hervey
ae46eb3a38 gstructure: New API: gst_structure_is_equal
Allows checking equality of GstStructure without having to create
intermediary GstCaps.

API: gst_structure_is_equal

https://bugzilla.gnome.org/show_bug.cgi?id=629300
2011-05-17 09:28:00 +02:00
Wim Taymans
ca0069595f tests: set elements in PAUSED
Set elements in PAUSED before trying to set caps on pads.
2011-05-16 19:09:54 +02:00
Wim Taymans
d4f85a0cd9 test: fix ghostpad test
We need to have activated pads before we can pass around caps.
Don't set NULL caps on pads.
2011-05-16 19:05:23 +02:00
Wim Taymans
887838aefe pad: avoid setting NULL caps on pads 2011-05-16 19:04:35 +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
cf4c955615 capsfilter: allow NULL filters and fix refcounting 2011-05-16 18:29:29 +02:00
Wim Taymans
32f1899354 caps: only add the structure when we could set the parent 2011-05-16 18:12:33 +02:00
Wim Taymans
877c1c28ff ghostpad: fix g_return_* with new query 2011-05-16 17:53:48 +02:00
Sebastian Dröge
b2e1c8b791 win32: Update list of exported symbols 2011-05-16 17:24:53 +02:00
Wim Taymans
f6178ee53e inputselector: handle more formats
Use the segment format instead of a hardcoded _TIME.
2011-05-16 17:09:06 +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
c079b5fd42 Merge branch '0.11' of ssh://git.freedesktop.org/git/gstreamer/gstreamer into 0.11 2011-05-16 16:54:02 +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
Wim Taymans
bd1c4506b8 update manual code examples for new _get_caps() 2011-05-16 16:10:49 +02:00
Sebastian Dröge
6bff1f968a tests: Update for negotiation related API changes 2011-05-16 15:33:11 +02:00
Sebastian Dröge
43e165c93c elements: Update for negotiation related API changes
The filter caps are only forwarded and returned instead
of ANY caps in the core elements because they don't do
anything caps specific.
2011-05-16 15:33:11 +02:00
Sebastian Dröge
bdf9022861 base: Improve negotiation with new getcaps() filter 2011-05-16 15:33:10 +02:00
Sebastian Dröge
3fa1594aaf gst: Add a filter caps parameter to all get_caps() functions
This is used to pass the possible caps and preferences to
the pad and to allow better negotiation decisions.
2011-05-16 15:33:10 +02:00
Mark Nauwelaerts
fe1dcbe6fa queue2: adjust input data rate estimation
... being aware of possible initial higher burst rate.
2011-05-16 12:20:51 +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
ddf2489be4 pad: Re-implement notify::caps 2011-05-16 10:25:10 +02:00
Tim-Philipp Müller
76ccd2a1e9 docs: fix up some Since markers and update for new multiqueue args 2011-05-14 14:05:52 +01:00
Sebastian Dröge
7316a88387 bin: Don't interprete pipelines without sink elements as always being in EOS state
Some tests (e.g. elements/capsfilter) have pipelines with dangling
sinkpads and without a sink element. These pipelines can never post
an EOS message (because this is only valid by a sink) and as such
should never get an EOS message posted by the bin.
2011-05-14 11:39:36 +02:00