Commit graph

12116 commits

Author SHA1 Message Date
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
Sebastian Dröge
cdffc1d5d5 systemclock: Only retry writing to the socket for EAGAIN, EWOULDBLOCK and EINTR
Fixes infinite loop in some cases, bug #650002.
2011-05-14 11:39:35 +02:00
Sebastian Dröge
9149043e95 miniobject: Add new miniobject weak ref/unref functions to the docs 2011-05-14 11:39:35 +02:00
Sebastian Dröge
116972d6eb miniobject: Minor cleanup of last commit 2011-05-14 11:39:35 +02:00
José Alburquerque
cf671d7b0a miniobject: Add weak referencing functionality
API: gst_mini_object_weak_ref()
API: gst_mini_object_weak_unref()

Add weak referencing functionality to GstMiniObject, which
allows to get notifications when an mini object is destroyed
but doesn't increase the real refcount. This is mostly
useful for bindings.

Fixes bug #609473.
2011-05-14 11:39:35 +02:00
Sebastian Dröge
5229a26a76 inputselector: Add sync mode that syncs inactive pads to the running time of the active pad
Fixes bug #645017.
2011-05-14 11:39:35 +02:00
Sebastian Dröge
9f83109706 multiqueue: Add mode to synchronize deactivated/not-linked streams by the running time
Fixes bug #645107, #600648.
2011-05-14 11:39:35 +02:00
Sebastian Dröge
4a836cae9f bin: Only post EOS messages after reaching the PLAYING state
Fixes bug #647756.
2011-05-14 11:39:35 +02:00
Sebastian Dröge
3872b816d2 element: Add GstElement::state_changed vfunc
API: GstElement::state_changed

This is always called when the state of an element has changed and
before the corresponding state-changed message is posted on the bus.
2011-05-14 11:39:35 +02:00
Sebastian Dröge
3c760a3ee5 ghostpad: Add docs for all the new, public functions 2011-05-14 11:39:35 +02:00
Sebastian Dröge
800b738715 ghostpad: Add guards against invalid parameters to the new, public functions 2011-05-14 11:39:35 +02:00
Sebastian Dröge
6807e536b0 ghostpad: Rename ghostpad/proxypad default functions
API: gst_ghost_pad_activate_pull_default
API: gst_ghost_pad_activate_push_default
API: gst_ghost_pad_internal_activate_pull_default
API: gst_ghost_pad_internal_activate_push_default
API: gst_ghost_pad_link_default
API: gst_ghost_pad_setcaps_default
API: gst_ghost_pad_unlink_default
API: gst_proxy_pad_acceptcaps_default
API: gst_proxy_pad_bufferalloc_default
API: gst_proxy_pad_chain_default
API: gst_proxy_pad_chain_list_default
API: gst_proxy_pad_checkgetrange_default
API: gst_proxy_pad_event_default
API: gst_proxy_pad_fixatecaps_default
API: gst_proxy_pad_getcaps_default
API: gst_proxy_pad_getrange_default
API: gst_proxy_pad_iterate_internal_links_default
API: gst_proxy_pad_query_default
API: gst_proxy_pad_query_type_default
API: gst_proxy_pad_setcaps_default
2011-05-14 11:39:34 +02:00
Sebastian Dröge
4c1e594ae5 ghostpad: Make all the internal caps functions public
This is useful if ghostpad/proxypads should be used but
additional code should be executed, e.g. for tracking
segments in the event function.
2011-05-14 11:39:34 +02:00
Sebastian Dröge
b36ce63f38 ghostpad: Only implement the iterate_internal_links function on proxypads
ghostpads inherit it from their parent class. Also make it threadsafe.
2011-05-14 11:39:34 +02:00
Sebastian Dröge
a216426bb6 ghostpad: API: Expose gst_proxy_pad_get_internal()
This allows to get the internal pad of ghostpads and
proxypads without using gst_pad_iterate_internal_links()
and is much more convenient.

The internal pad of a ghostpad is the pad of the opposite direction
that is used to link to the ghostpad target.
2011-05-14 11:39:34 +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
6e57ce32e5 caps: Merge structures when intersecting instead of appending them
This prevents adding duplicates over and over again to the resulting
caps if they already describe the new intersection result.

While this changes intersection from O(n*m) to O(n^2*m), it results in
smaller caps, which in the end will decrease further processing times.

For example in an audioconvert ! audioconvert ! audioconvert pipeline,
when forwarding the downstream caps preference in basetransform
(see e26da72de25a91c3eaad9f7c8b2f53ba888a0394) this results in
16 instead of 191 caps structures.
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
Miguel Angel Cabrera Moya
f450817d7f parse: don't unescape inside quotes
Escaped characters inside quoted strings are supposed to be unescaped by
deserialization functions, not by parsing functions.

https://bugzilla.gnome.org/show_bug.cgi?id=648025
2011-05-14 11:39:34 +02:00
Sebastian Dröge
f07b637d86 pad: Remove unnecessary FIXME
Resetting the result is not necessary when resyncing because
pads that previously got the event will be skipped and we
need to consider the results of the previous pushes.
2011-05-14 11:39:33 +02:00
Sebastian Dröge
2f947f3993 element: If activating one pad failed error out early instead of trying to activate the next pads
If one pad fails to activate the complete activation process will fail
anyway and trying to activate the other pads only wastes time.
2011-05-14 11:39:33 +02:00
Sebastian Dröge
f3f1f7d69a bin: If activating one pad failed error out early instead of trying to activate the next pads
If one pad fails to activate the complete activation process will fail
anyway and trying to activate the other pads only wastes time.
2011-05-14 11:39:33 +02:00
Tim-Philipp Müller
2fd64257fd Back to development 2011-05-14 09:31:33 +01:00
Tim-Philipp Müller
3f80f6584f Release 0.10.34 2011-05-14 01:00:23 +01:00
Sebastian Dröge
54fd068aba meta: Fix compilation of the unit test after removal of the serialize/deserialize functions 2011-05-13 08:38:30 +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
9339a59583 meta: remove (de)serialize functions
Add a GType to the metadata to identify the GstMetaInfo.
We can remove the (de)serialize functions for the metadata because we can
register GTtype transform functions between various types to implement
serialization later.
2011-05-11 19:10:24 +02:00
Wim Taymans
9597545d23 structure: more cleanups
gst_structure_get_type() -> _gst_structure_type to avoid method calls for
getting the GType that initialized at the start.
Hide some structure fields in private data so that we can change the
implementation.
Move structure equality check from caps.c to structure.c where it belongs.
2011-05-11 18:17:45 +02: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
437c92b403 bin: Dereference GstQuery** before passing it to GST_QUERY_TYPE_NAME 2011-05-11 16:47:33 +02:00
Wim Taymans
905100cdbe event: update the structure when needed
When we get the structure of an event, make sure it also contains the fields
that we keep in fast variables, this way we can easily serialize and debug
the events. We would probably later simply prefer to register a transform
function to G_TYPE_STRING and G_TYPE_BYTEARRAY etc..
2011-05-11 16:06:50 +02:00
Wim Taymans
e2452c8c78 caps: cleanups
We don't need to check if the type is 0, the init function is only called once
in the beginning.
2011-05-11 16:06:50 +02:00
Wim Taymans
0bfbce4463 event: clean up some macros
Avoid executing a method for GST_TYPE_EVENT but instead use the type variable
directly. We can do this because we register it before anything else.
2011-05-11 16:06:49 +02:00
Sebastian Dröge
9ec1673cae bus: Fix GST_DEBUG parameters to be consistent with the format string 2011-05-11 15:49:11 +02:00
Sebastian Dröge
ef673656b7 basetransform: Implement support for pad reconfiguration again 2011-05-11 15:26:02 +02:00
Sebastian Dröge
07c5caac50 capsfilter: Fix deadlock, gst_pad_get_current_caps() already takes the pad's object lock 2011-05-11 15:19:39 +02:00
Wim Taymans
fa28e2c5e6 event: example of how to optimize events
Use a structure for the QoS event by 'extending' the GstEventImpl structure.
This should avoid allocation of GstStructures and its contents.
2011-05-11 11:06:36 +02:00