Commit graph

6747 commits

Author SHA1 Message Date
Sebastian Dröge
079b2cb0c7 gstplugin: Add hack for handling 0.11.9X and 0.11.89.X with X>0 the same as 1.0.0
Also update the version number to 0.11.89.1
2012-04-05 13:25:09 +02:00
Mark Nauwelaerts
515a1ad0f7 tocsetter: clear mutex upon free 2012-04-05 12:22:23 +02:00
Sebastian Dröge
f6848ad337 registry: Set registry version to 1.0.0 too 2012-04-05 10:57:29 +02:00
Alessandro Decina
e603d08e87 gstbuffer: fix compile warning 2012-04-05 09:07:18 +02:00
Sebastian Dröge
b0d89da6b6 gst: Change versioning
Remove GST_MAJORMINOR and replace it by GST_API_VERSION
Also set GST_VERSION_{MAJOR,MINOR,MICRO,NANO} explicitely
now.

All versions are at 1.0.0 now for the release soon but
API/ABI can still change until the 1.0.0 release.

Next release versions until 1.0.0 will be 0.10.9X and
these will be release candidates. GST_VERSION_* will
nonetheless stay at 1.0.0.0.
2012-04-04 14:28:55 +02:00
Wim Taymans
b15bcb66b4 buffer: improve _set_size() 2012-04-04 09:33:13 +02:00
Wim Taymans
8428d3e295 buffer: make get_sizes and _resize with ranges
Make the _get_sizes and _resize methods work on a range of memory to make them
more powerfull.
2012-04-04 09:33:13 +02:00
Stefan Sauer
e0ab66cf55 tocsetter: use new glib mutex api 2012-04-03 15:59:18 +02:00
Tim-Philipp Müller
fcaa6e3c48 gst: ref new entry enum types
Fixes 'make check', again.
2012-04-02 23:28:15 +01:00
Tim-Philipp Müller
730c263842 toc: don't export private functions 2012-04-02 23:23:46 +01:00
Stefan Sauer
3b0af8df9e toc: port to 0.11 2012-04-02 22:09:07 +02:00
Alexander Saprykin
3f30c73443 Add new GstTocSetter interface 2012-04-02 21:50:55 +02:00
Alexander Saprykin
6e65daa4d1 Add new TOC query 2012-04-02 21:50:55 +02:00
Alexander Saprykin
03d0f569b3 Add new TOC message 2012-04-02 21:50:55 +02:00
Alexander Saprykin
c3f97992c4 Add new TOC and TOC select events 2012-04-02 21:50:55 +02:00
Alexander Saprykin
1f7096b52a Add generic table of contents (TOC) support 2012-04-02 21:50:55 +02:00
Stefan Sauer
1074a4e99a Merge branch '0.10'
Conflicts:
	docs/gst/gstreamer-sections.txt
	gst/Makefile.am
	gst/gst.c
	gst/gst.h
	gst/gstevent.c
	gst/gstevent.h
	gst/gstmessage.h
	gst/gstquark.c
	gst/gstquark.h
	gst/gstquery.c
	gst/gstquery.h
	tests/check/Makefile.am
2012-04-02 21:33:10 +02:00
Alexander Saprykin
566025b993 Add new GstTocSetter interface 2012-04-02 10:49:38 +02:00
Alexander Saprykin
105330784c Add new TOC query 2012-04-02 10:49:38 +02:00
Alexander Saprykin
af85bd8dbf Add new TOC message 2012-04-02 10:49:38 +02:00
Alexander Saprykin
2cb82d42fb Add new TOC and TOC select events 2012-04-02 10:49:38 +02:00
Alexander Saprykin
63256d271d Add generic table of contents (TOC) support 2012-04-02 10:49:38 +02:00
Wim Taymans
f3aad8b430 buffer: reuse more code 2012-04-01 12:02:40 +02:00
Wim Taymans
0e9241cfc6 buffer: make function to find memory in a buffer
Make a function to find the memory blocks for a region in a buffer.
2012-04-01 12:02:40 +02:00
Stefan Sauer
7f628113e4 childproxy: fix more missing GST_OBJECT -> G_OBJECT use 2012-03-31 21:26:56 +02:00
Wim Taymans
113b9dc535 buffer: add peek_memory method
Add a peerk_memory method that simply fetches the memory at an offset without
refcounting or merging.
2012-03-31 17:10:35 +02:00
Wim Taymans
3db0ce476f grammar.y: fix childproxy code
It takes GObject and not GstObject now
2012-03-31 12:00:56 +02:00
Stefan Sauer
e7b9b68361 childproxy: include the child name in the signal 2012-03-30 22:46:02 +02:00
Stefan Sauer
d93c5c5fd0 parser: update for childproxy api changes 2012-03-30 22:45:04 +02:00
Stefan Sauer
e96c312847 childproxy: fix signal parameter types 2012-03-30 22:36:35 +02:00
Stefan Sauer
f35267bb92 childproxy: use GObject instead of GstObject
This makes it prossible to be used more widely. Fix implementations for the API
change.
2012-03-30 22:24:26 +02:00
Stefan Sauer
ef48cff3d0 childproxy: make get_child_by_name virtual
Allows implementations to use custom name->object mappings.
2012-03-30 22:13:51 +02:00
Stefan Sauer
bd625b8152 childproxy: fix indentation 2012-03-30 22:01:26 +02:00
Wim Taymans
38b96e6c8c buffer: improve the buffer memory methods
gst_buffer_take_memory -> gst_buffer_insert_memory because insert is what the
method does.
Make all methods deal with ranges so that we can replace, merge, remove and map
a certain subset of the memory in a buffer. With the new methods we can make
some code nicer and reuse more code. Being able to deal with a subset of the
buffer memory allows us to optimize more cases later (most notably RTP headers
and payload that could be in different memory objects).
Make some more convenient macros that call the more generic range methods.
2012-03-30 18:15:24 +02:00
Edward Hervey
16bf133566 gstquery: Fix annotation 2012-03-29 17:53:47 +02:00
Mark Nauwelaerts
617a8b3811 query: parsing allocation query need not provide reffed caps
... in line with other query parsing function.
2012-03-29 17:08:57 +02:00
Fabrizio (Misto) Milo
31c450a5d5 caps: spelling fixes 2012-03-29 15:46:15 +02:00
Edward Hervey
2d95de113e gstelement: lower GST_ELEMENT_FLAG_LAST
It wouldn't leave that much room for subclass users
2012-03-29 15:28:44 +02:00
Edward Hervey
31ca9f9216 gstbuffer: Fix unitialized variable
gcc 4.5 complains otherwise :(
2012-03-29 15:18:33 +02:00
Wim Taymans
ce67b0e539 docs: update more documentation 2012-03-29 13:34:50 +02:00
Wim Taymans
9aa9751938 review some docs 2012-03-28 18:12:23 +02:00
Wim Taymans
3e6238135d buffer: simplify and refactor _span and _merge
Unify the _span and _merge code paths and simplify now that we only use this
internally.
2012-03-28 16:48:51 +02:00
Wim Taymans
315e77bf81 buffer: we always call _span with the buffer size 2012-03-28 16:48:51 +02:00
Wim Taymans
127074986c buffer: move some code around 2012-03-28 16:48:51 +02:00
Wim Taymans
8fc290a27f buffer: we call _span always with 0 offset 2012-03-28 16:48:51 +02:00
Wim Taymans
a4c861a4d3 buffer: remove always FALSE function argument 2012-03-28 16:48:50 +02:00
Mark Nauwelaerts
1af261169c buffer: delay buffer unref until buffer no longer needed 2012-03-28 16:39:54 +02:00
Wim Taymans
bb876588ac buffer: unify buffer merge methods
Add gst_buffer_append() which appends the memory blocks from one buffer to
another. Remove the old inefficient _merge() and _join() methods which forced a
premature memcpy in most cases.
Remove the _is_span() and _span() methods they are not needed anymore now that
we can _append(). Merging and spanning will be delayed until mapping or maybe
not at all when the element can deal with the different memory blocks.
2012-03-28 12:51:58 +02:00
Olivier Crête
fd675fa385 gstpad: Fix typo in docstring 2012-03-27 15:25:58 -04:00
Olivier Crête
37db4eefbf gstpad: Fix typo in docstring 2012-03-27 15:24:49 -04:00
Wim Taymans
a137002ef1 buffer: re-enable _span offset calculations
when we _span two complete buffers, we can copy offsets and timestamps.
2012-03-27 15:16:55 +02:00
Wim Taymans
a080b81808 trace: add refcount to trace debug 2012-03-27 15:00:38 +02:00
Wim Taymans
8ff7a0978d buffer: add more _is_writable checks
Add some checks to assert on writability for functions that modify metadata.
2012-03-27 14:59:06 +02:00
Wim Taymans
08f33d8d93 bufferpool: remove const from get/set_param
Remove the const from the GstCaps in get/set_param. set_param modifies
the refcount of the caps.
Don't increment the refcount of the caps result of get_param like we
do with other objects.
Update some annotiations.
2012-03-27 12:48:59 +02:00
Wim Taymans
f09ab3b007 bufferpool: fix annotation for _release
_release takes ownership of the buffer
2012-03-27 12:48:59 +02:00
Sebastian Dröge
9c4c9e3b6b bus: Change the timeout argument type of gst_bus_poll() from GstClockTimeDiff to GstClockTime
This is more consistent with the other GstBus methods that have a timeout.
2012-03-27 12:31:18 +02:00
Wim Taymans
e08956907c caps: remove old code
Remove attempt to delay _make_writable
2012-03-26 19:13:21 +02:00
Mark Nauwelaerts
7a7119ec99 caps: ensure writable caps prior to modification 2012-03-26 18:08:10 +02:00
Wim Taymans
3776eb9e25 bufferpool: check min/max_buffers 2012-03-26 17:38:50 +02:00
Wim Taymans
ce90970be2 query:fix copy-and-paste problem 2012-03-26 17:35:18 +02:00
Mark Nauwelaerts
5077f4c958 utils: add and improve debug messages
... so they end up in a more expected debug category rather than oblivion.
2012-03-23 18:52:11 +01:00
Sebastian Dröge
73e91b2ce3 query: Only allow fixed caps in the accept-caps query 2012-03-21 09:00:45 +01:00
Wim Taymans
f9c85a53dc pad: improve docs of get/pull_range
Improve the docs of the get/pull_range functions, define the lifetime of the
buffer in case of errors and short reads.
Make sure the code does what the docs say.
2012-03-20 13:14:55 +01:00
Wim Taymans
7bcc3baf64 buffer: improve gst_buffer_new_wrapped_full()
Make it possible to wrap all kinds of memory by exposing all properties to
gst_buffer_new_wrapped_full(). This makes it possible to also create writable
memory without a free function or memory with extra padding.
2012-03-20 10:20:29 +01:00
Wim Taymans
db1318ab4a pad: change the semantics of get/pull_range a little
Make it so that one can specify a buffer for get/pull_range where the downstream
element should write into. When passing NULL, upstream should allocate a buffer,
like in 0.10.
We also need to change the probes a little because before the pull probe, there
could already be a buffer passed. This then allows us to use the same PROBE
macro for before and after pulling.
While we're at the probes, make the query probe more powerful by handling the
GST_PAD_PROBE_DROP return value. Returning _DROP from a query probe will now
return TRUE upstream and will not forward the probe to the peer or handler.
Also handle _DROP for get/pull_range properly by not dispatching to the
peer/handler or by generating EOS when the probe returns DROP and no buffer.
Make filesrc handle the non-NULL buffer passed in the get_range function and
skip the allocation in that case, writing directly into the downstream provided
buffer.
Update tests because now we need to make sure to not pass a random value in the
buffer pointer to get/pull_range
2012-03-16 21:37:10 +01:00
Wim Taymans
6b90850257 event: fix docs a little, alloc_buffer is gone 2012-03-16 18:39:08 +01:00
Wim Taymans
a7e6c7d2a8 bufferpool: split bufferpool configuration
Make separate methods to control the bufferpool and the allocator used by the
bufferpool.
Make it possible to change the allocator of a pool.
2012-03-15 22:09:02 +01:00
Wim Taymans
83af60019e query: rework the ALLOCATION query
Separate the bufferpool and allocator hints in the allocation query, some
of the values don't always make sense together.
Keep the bufferpool and its configuration together.
Keep the allocator and its parameters together.
Allow for multiple bufferpool configurations in the query.
2012-03-15 20:23:59 +01:00
Wim Taymans
c8acf02f23 pad: comment and debug improvement 2012-03-15 16:50:31 +01:00
Wim Taymans
f0084ac8e9 utils: improve debug
also fix a potential memory leak
2012-03-15 16:49:33 +01:00
Wim Taymans
9a1cd17136 GstBufferPoolParams -> GstBufferPoolAcquireParams
Because those flags are not from the bufferpool but for the acquire function.
2012-03-15 14:01:44 +01:00
Wim Taymans
85c9543841 memory: group allocation parameters in a struct
Group the extra allocation parameters in a GstAllocationParams structure to make
it easier to deal with them and so that we can extend them later if needed.
Make gst_buffer_new_allocate() take the GstAllocationParams for added
functionality.
Add boxed type for GstAllocationParams.
2012-03-15 13:42:17 +01:00
Wim Taymans
69e3639c96 query: fix copy function
Copy the structure too.
2012-03-15 13:42:17 +01:00
Wim Taymans
592b5bec39 memory: fix maxsize after align
when we align the data pointer, make sure to update the maxsize.
Add some more debug
2012-03-15 13:42:17 +01:00
Wim Taymans
edd2ffe4d4 memory: Add 0 padding
Change gst_allocator_alloc() so that we can also spicify flags and padding.
Add 2 new flags to mark the memory 0 prefixed/padded. This allows us to
remove some resizes in the base classes.
When allocating memory, memset prefix and padding with 0 when the flags tell
us to.
On resize, clear the zero padding flags if we can't guarantee the memory is
still 0 filled.
Update tests.
2012-03-14 21:32:22 +01:00
Wim Taymans
3d76e6011c query: also include padding in ALLOCATION query
Negotiating padding is needed on second thought so include it in the
ALLOCATION query.
Make the bufferpool take padding into account when allocating.
Make basesrc take padding into account.
Use padding and prefix when allocating in basetransform.
2012-03-14 19:47:10 +01:00
Mark Nauwelaerts
f2d81f4c3d bufferpool: free owned discarded pool config 2012-03-14 17:20:01 +01:00
Wim Taymans
e332862985 pad: implement DRAIN handling
When we forward the DRAIN query and there is nothing to forward it to, assume we
are drained.
When a basesink receives a drain query, reply with TRUE.
2012-03-14 16:27:31 +01:00
Wim Taymans
318baf4cd9 query: add new drain query
With the new serialized downstream queries we can implement a drain query that
makes an element waits until a downstream element replies to the query.
2012-03-14 16:18:02 +01:00
Wim Taymans
05cd564bea pad: make serialized queries push sticky events first
Before we can proceed with a serialized query, we need to be sure that all
sticky events were pushed.
2012-03-14 16:01:15 +01:00
Wim Taymans
fb2fc331de pad: take stream lock on serialized queries 2012-03-14 15:29:12 +01:00
Wim Taymans
cd6693fdc9 pad: enforce correct query direction 2012-03-14 15:16:56 +01:00
Wim Taymans
5a21eb36c7 query: register queries like events
Also register queries with a QueryType that allows us to check if the event is
sent in the right direction. Add a serialized query type because we will need
this for the allocation query.
Remove the QueryTypeDefinition stuff, it is not used anymore and we now use
custom queries and separate API for them.
Update defs.
2012-03-14 14:51:16 +01:00
Wim Taymans
d2d7be7b75 bin: remove old compat mode 2012-03-13 15:40:37 +01:00
Wim Taymans
bcf115a620 caps: small docs update 2012-03-13 15:40:23 +01:00
Wim Taymans
272142089e caps: remove gst_caps_union()
Remove gst_caps_union(), use gst_caps_merge(). This function was not used
anymore and it is unclear what the difference is with _merge().
2012-03-13 10:04:36 +01:00
Wim Taymans
5e719a293a caps: delay _make_writable() until needed in _normalize()
Delay _make_writable() until we actually found a list and need to update the
caps.
2012-03-12 18:34:30 +01:00
Wim Taymans
4cdddd2bb1 caps: shortcut simplify earlier
A simple caps is already simplified, no need to check for fixedness.
2012-03-12 18:25:38 +01:00
Wim Taymans
f4aa1b1011 caps: small cleanup, remove const 2012-03-12 18:22:05 +01:00
Wim Taymans
4bbc3b6f04 caps: small cleanups 2012-03-12 18:02:27 +01:00
Wim Taymans
1bc93bbf8f caps: small doc improvement 2012-03-12 16:40:38 +01:00
Wim Taymans
4feb6c3989 caps: fix some 0.11 FIXMEs 2012-03-12 12:35:07 +01:00
Wim Taymans
67931bfded caps: make _normalize take ownership of input
Make gst_caps_normalize() take ownership of the input so that it can more
intelligently decide when to copy or not.
2012-03-12 12:21:34 +01:00
Wim Taymans
8a76c3269a caps: _do_simplify() -> _simplify()
Rename _do_simplify() to _simplify(). The name was introduced as a replacement
method for a deprecated method but we can now rename it again.
Fix some docs.
2012-03-12 11:38:37 +01:00
Wim Taymans
9cdbffea94 caps: improve _do_simplify
Make gst_caps_do_simplify() take ownership of the input caps and produce a
simplified output caps. This removes the requirement of having writable input
caps and the method can make the caps writable only when needed.
2012-03-12 10:42:23 +01:00
Wim Taymans
43abf99a8a caps: avoid using in-place oprations
Rework some caps operations so they don't rely on writable caps but instead take
ownership of the input caps and do _make_writable() only when needed.
Remove some const from caps functions, it does not make much sense for
refcounted objects and does not allow us to return a refcount to the const input
caps.
Rework the base classes fixate vmethods to not operate on the caps in-place.
All this saves us around 30% of caps and structure copy and new operations.
2012-03-11 18:57:44 +01:00
Wim Taymans
89d0316895 structure: add allocation debug 2012-03-11 17:22:01 +01:00
Wim Taymans
fe5fe438d3 typefind: remove const from refcounted GstCaps
Having const on refcounted objects require us to make copies instead of simply
taking a ref, don't do that.
2012-03-10 09:25:43 +01:00
Wim Taymans
6426145fc9 registry: avoid copy when caps are fixed
Avoid doing a useless copy when the caps are fixed and simplify will not do
anything.
2012-03-10 09:15:43 +01:00
Wim Taymans
6ffba69d65 buffer: small optimizations
shortcut heavy work when buffer_resize does nothing.
Avoid an extra _ref when mapping a buffer.
Add some G_LIKELY.
2012-03-09 16:14:02 +01:00