Commit graph

362 commits

Author SHA1 Message Date
Guillaume Desmottes
4a41468ce7 Use MAY_BE_LEAKED_FLAG
This helps having "make check" passing with the leaks tracer enabled.

https://bugzilla.gnome.org/show_bug.cgi?id=766008
2016-06-02 23:14:15 +01:00
Guillaume Desmottes
8daad351a4 caps: add cleanup priv function
Those are allocated in _priv_gst_caps_initialize() so it makes
sense to have a symetric cleanup functions called by gst_deinit().

https://bugzilla.gnome.org/show_bug.cgi?id=765606
2016-04-26 14:29:08 +01:00
Evan Nemerson
d11e657412 docs: annotate C examples as such
https://bugzilla.gnome.org/show_bug.cgi?id=731292
2016-02-15 17:45:15 +00:00
Sebastian Dröge
2c272d74fd caps: Add (transfer full) annotation to simplify() and subtract() return value
https://bugzilla.gnome.org/show_bug.cgi?id=759948
2015-12-29 14:32:47 +02:00
Aurélien Zanelli
2ee33237c8 caps: add 'transfer full' annotation to caps returned by interserction functions
To make clear caller is responsible to unref them.

https://bugzilla.gnome.org/show_bug.cgi?id=759948
2015-12-29 14:30:29 +02:00
Nirbheek Chauhan
b76f046999 caps: clarify docs for a few functions that they don't update things in-place
It is not necessarily clear from the existing introspection tags and
documentation alone.
2015-10-27 11:23:25 +00:00
Vikram Fugro
c12bd5d807 gst: Documentation typo fix in caps & pad APIs
gst_caps_can_intersect() & GST_PAD_IS_ACCEPT_INTERSECT()
documentation typo fix.

https://bugzilla.gnome.org/show_bug.cgi?id=755257
2015-09-19 17:57:55 +02:00
Tim-Philipp Müller
1dd72f56ea debugutils: nicer printing of caps features
Only print interesting caps features, don't
append (memory:SystemMemory) to all caps,
which makes them much more unwieldy and
harder to read. Also use internal function
to get caps features so that our printing
has no side effects on the caps.

https://bugzilla.gnome.org/show_bug.cgi?id=746809
2015-04-01 12:15:30 +01:00
Sebastian Dröge
1f6d5d3ff5 structure/caps: Add gst_{structure,caps}_filter_and_map_in_place()
https://bugzilla.gnome.org/show_bug.cgi?id=739765
2014-12-16 18:22:46 +01:00
Sebastian Dröge
bc11a1b79d caps: Add gst_caps_foreach() and gst_caps_map_in_place()
https://bugzilla.gnome.org/show_bug.cgi?id=739765
2014-12-16 18:22:46 +01:00
George Kiagiadakis
780c83d5c4 caps: unset the parent refcount of the old features before freeing them in gst_caps_set_features()
Otherwise gst_caps_features_free() asserts and the features structure is leaked
2014-06-26 11:16:34 +03:00
Tim-Philipp Müller
8e30a9462c caps: gst_caps_is_any() should return TRUE or FALSE
Not some flag value instead of TRUE. Fixes code like
gst_caps_is_any() == TRUE.

https://bugzilla.gnome.org//show_bug.cgi?id=731704
2014-06-22 12:50:42 +01:00
Evan Nemerson
e10266e3f3 docs: convert NULL, TRUE, and FALSE to %NULL, %TRUE, and %FALSE
This should help improve documentation generated for
languages other than C.

https://bugzilla.gnome.org/show_bug.cgi?id=730961
2014-05-30 00:20:27 +01:00
Edward Hervey
25bcc2d7f6 caps: Don't leak features on error cases
If we fail to parse fields, we would end up leaking the features we
parsed just before

CID #1212152
2014-05-12 16:59:29 +02:00
Tim-Philipp Müller
6eb6d9ec38 docs: remove outdated and pointless 'Last reviewed' lines from docs
They are very confusing for people, and more often than not
also just not very accurate. Seeing 'last reviewed: 2005' in
your docs is not very confidence-inspiring. Let's just remove
those comments.
2014-04-26 21:21:51 +01:00
Stefan Sauer
c068b225fe docs: convert the examples to use gtk-doc markup, instead of docbook
The gtk-doc markup is less intrusive and better handled when creating docs for
language bindings. The titles (where used) where not adding much.
2014-02-27 18:11:35 +01:00
Sebastian Dröge
8d7e11e307 caps: When getting capsfeatures and none are there, store sysmem capsfeatures
... instead of returning a reference to a global instance. The caller might
want to change the global instance otherwise, which causes funny effects like
all global instances being changed and at the same time nothing in the caps
being changed.

As the caps might be immutable while we do this we have to do some magic
with atomic operations.

https://bugzilla.gnome.org/show_bug.cgi?id=723236
2014-02-04 18:47:23 +01:00
Sebastian Dröge
e51e0cb0d3 caps: Don't get us sysmem capsfeatures if we just check for fixed caps 2014-02-04 18:06:26 +01:00
Sebastian Rasmussen
53ae1b2c9c docs: Fix typos in function/object descriptions
Fixes https://bugzilla.gnome.org/show_bug.cgi?id=720029
2013-12-07 17:11:12 +00:00
Sebastian Rasmussen
b40fa2b8c3 docs: cosmetic changes in references/decriptions
* fix typo GstBufferFlag -> GstBufferFlags
 * fix typo GstFeatures -> GstCapsFeatures
 * fix typo GstAllocatorParams -> GstAllocationParams
 * fix typo GstContrlSources -> GstControlSource
 * do not refer to gstcheck as an object
 * make references gtk_init() and tcase_set_timeout() not be references
 * gst_element_get_pad() renamed gst_element_get_static_pad()
 * gst_clock_id_wait_async_full() renamed gst_clock_id_wait_async()
 * _drop_element() is really gst_queue_array_drop_element()
 * gst_pad_accept_caps() was removed, do not refer to it
 * separate GST_META_TAG_MEMORY_STR declaration from description
 * do not describe removed gst_collect_pads_collect()
 * correctly link to GstElementClass' virtual set_context()

Fixes https://bugzilla.gnome.org/show_bug.cgi?id=719614
2013-12-02 21:01:08 +00:00
Thiago Santos
007c0e5fe1 value: fix caps serialization when there are caps inside caps
Wrap caps strings so that it can handle serialization and deserialization
of caps inside caps. Otherwise the values from the internal caps are parsed
as if they were from the upper one

https://bugzilla.gnome.org/show_bug.cgi?id=708772
2013-09-30 16:20:48 -03:00
Sebastian Dröge
9ddcfcf8f4 gst: Add some more Since: 1.2 2013-07-18 14:39:42 +02:00
Sebastian Dröge
91b3890d70 caps: Handle ANY caps features properly in more places 2013-04-06 21:49:25 +02:00
Sebastian Dröge
db6ee700f2 caps: Properly handle ANY caps features in caps operations 2013-04-06 21:09:49 +02:00
Tim-Philipp Müller
cf69475aeb caps: fix caps feature leak
Fixes leaks in 14 core unit tests including
gst/gstcaps.
2013-04-04 23:14:13 +01:00
Wim Taymans
d92ce924e6 caps: update docs, is_subset() works now 2013-04-04 17:46:09 +02:00
Sebastian Dröge
65c650d7d4 capsfeatures: Add GST_CAPS_FEATURES_ANY
This is equal to any other caps features but results in unfixed caps. It
would be used by elements that only look at the buffer metadata or are
currently working in passthrough mode, and as such don't care about any
specific features.
2013-04-02 22:17:22 +02:00
Sebastian Dröge
efcb4023e6 caps: Set features' parent refcount in gst_caps_set_features() too 2013-04-01 10:19:01 +02:00
Sebastian Dröge
ccd2966f7a caps: Set sysmem features if explicitely requested 2013-04-01 10:18:39 +02:00
Sebastian Dröge
7477b25df5 caps: Add new data type for handling caps features to the caps
These are meant to specify features in caps that are required
for a specific structure, for example a specific memory type
or meta.

Semantically they could be though of as an extension of the media
type name of the structures and are handled exactly like that.
2013-03-31 18:15:52 +02:00
Sebastian Dröge
7decc9bef7 caps: Fix gst_static_caps_get(GST_STATIC_CAPS_NONE)
https://bugzilla.gnome.org/show_bug.cgi?id=696435
2013-03-25 09:22:49 +01:00
Tim-Philipp Müller
22036ef1c4 caps, structure, taglist: micro-optimisations
Avoid some unnecessary GValue copying by making use of
gst_structure_id_take_value() where possible.
2012-12-22 16:55:26 +00:00
Wim Taymans
12f835ca43 caps: fix docs 2012-12-05 14:56:48 +01:00
Tim-Philipp Müller
666c8c11c6 Fix FSF address
https://bugzilla.gnome.org/show_bug.cgi?id=687520
2012-11-03 20:44:48 +00:00
Edward Hervey
d3ffa82639 Remove 0.10-related documentation and "Since" markers 2012-07-10 12:03:27 +02:00
Wim Taymans
3b16efa1d1 miniobject: add lock functionality to GstMiniObject
Move the locking methods from GstMemory to GstMiniObject.
Add a miniobject flag to enable LOCKABLE objects. LOCKABLE objects can
use the lock/unlock API to control the access to the object.
Add a minobject flag that allows you to lock an object in readonly mode.
Modify the _is_writable() method to check the shared counter for LOCKABLE
objects. This allows us to control writability separately from the refcount for
LOCKABLE objects.
2012-07-05 11:19:16 +02:00
Tim-Philipp Müller
1be934f0dd miniobjects: pass copy, dispose and free function to gst_mini_object_init()
So mini objects don't have to poke into the GstMiniObject part
of the structure. Saves lines of code, and seems slightly cleaner.
We don't have proper OO hierarchies or methods here after all.
2012-06-23 20:02:02 +01:00
Wim Taymans
c066ea8c69 caps: NULL is not a valid caps anymore 2012-06-15 17:01:37 +02:00
Tim-Philipp Müller
463268b21f caps: no need to store the size of the caps structure inside the structure 2012-06-15 10:26:56 +01:00
Wim Taymans
12aefaa078 miniobject: remove the size field
The size field is used by subclasses to store the total allocated size of the
memory for this miniobject. Because miniobject doesn't really do anything with
this field we can move it to the subclasses.
2012-06-14 17:11:11 +02:00
Tim-Philipp Müller
b5ab3fb1dc caps: log freeing of caps at same log level as creation, i.e. TRACE 2012-05-27 20:31:30 +01:00
Thiago Santos
80fa8aa77b gstcaps: Update docs for gst_caps_is_equal
NULL caps aren't valid caps in 1.0 and aren't accepted in
gst_caps_is_equal
2012-05-01 15:57:39 -03:00
Fabrizio (Misto) Milo
31c450a5d5 caps: spelling fixes 2012-03-29 15:46:15 +02:00
Wim Taymans
9aa9751938 review some docs 2012-03-28 18:12:23 +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
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