Commit graph

191 commits

Author SHA1 Message Date
Seungha Yang
84a3f0448b gst: Add non-inline methods for bindings to able to use core APIs
Provide non-inline version of refcounting APIs so that it can be
consumed by bindings

Fixes: https://gitlab.freedesktop.org/gstreamer/gstreamer-sharp/-/issues/46
Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/728>
2021-01-11 21:54:48 +09:00
Thibault Saunier
1627222aa5 taglist: Stop inlining gst_tag_list_copy
This way it gets exposed to bindings through GObject Introspection.

Same logic as with d1b2d3429c

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/561>
2020-07-09 07:57:01 -04:00
Matej Knopp
cab5b22f21 taglist: Fix crash when comparing two lists of the same length but with different items
Fixes #549

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/469>
2020-05-08 11:04:14 +03:00
Edward Hervey
81752169a4 taglist: Make equality check more uniform
Previously this was iterating over taglists with ... string names.

Instead use the same technique as `gst_structure_is_equal()` with the additional
double check.

Part-of: <https://gitlab.freedesktop.org/gstreamer/gstreamer/-/merge_requests/466>
2020-05-06 12:00:46 +02:00
Sebastian Dröge
5688773b91 taglist: Remove (scope call) annotation from gst_tag_register()
This was added in 7fdb15d6a2 but it is wrong. (scope call) is for
closures that only have to stay valid for the scope of the call, but the
tag merge function has to stay valid for the whole lifetime of the
application instead.

There's no appropriate scope annotation for that so we have to skip
these functions for now.
2019-01-24 07:52:34 +00:00
Sebastian Dröge
942fc7f79e gst: Add poisoning to more types 2018-08-03 14:31:34 +03:00
luz.paz
4a402c1c7d Fix typos in comments and docs
Found via `codespell`

https://bugzilla.gnome.org/show_bug.cgi?id=795610
2018-05-01 11:18:03 +01:00
Mark Nauwelaerts
9fb56a32f5 gst: fix some GIR annotations
Mostly related to out parameters and their transfer
2018-02-18 12:16:36 +01:00
Arun Raghavan
b5028383ab gst: Fix up a bunch of GIR annotations
This is mostly on nullable return values, and some other minor ones that
I ran across.

https://bugzilla.gnome.org/show_bug.cgi?id=789319
2018-01-27 10:41:24 +00:00
Thibault Saunier
e45873c6ec taglist: Avoid assertions when getting tag nick from unregister tag
With serialized GstDiscovererInfos we might end up trying to use
tags that have not been registered.
2017-11-26 12:53:54 -03:00
Thibault Saunier
a87b4551a6 Port gtk-doc comments to their equivalent markdown syntax
Modernizing our documentation and preparing a possible move to hotdoc.
This commits also adds missing @title metadatas to all SECTIONs
2017-01-27 16:36:38 -03:00
Scott D Phillips
584da6e86c taglist: remove return void in gst_tag_register
MSVC warns on this and the documentation about the warning says:

> The compiler assumes the function returns a value of type int

which is a little scary, so lets just remove the unnecessary 'return'

https://bugzilla.gnome.org/show_bug.cgi?id=774293
2016-11-12 10:50:33 +02:00
Tim-Philipp Müller
f02e52ba3f taglist: add guard to check writability when removing tags from a taglist
https://bugzilla.gnome.org/show_bug.cgi?id=762793
2016-02-28 13:59:48 +00:00
Adam Miartus
44423e8af3 taglist: add GST_TAG_CONDUCTOR
This is useful for metadata which explicitely distinguishes
between artist/composer and conductor.

https://bugzilla.gnome.org/show_bug.cgi?id=762450
2016-02-22 21:12:37 +00:00
Ravi Kiran K N
9fbecd6b6d tags: add GST_TAG_PRIVATE_DATA
Can be used to represent private data that may be
contained in tags, such as ID3v2 PRIV frames.

https://bugzilla.gnome.org/show_bug.cgi?id=730926
2015-11-20 19:43:31 +00:00
Nicolas Dufresne
7fdb15d6a2 taglist: Add missing scope to func param
This tell GI if this function is for actions (call) or is the
answer of this method being asynchronous (async). In this case
it's a call. This also silence warning from the GI scanner.
2015-06-13 12:32:49 -04:00
Sebastian Dröge
18b0581009 taglist: Copy the tag scope too when copying tag lists 2015-04-28 15:51:23 +02:00
Stefan Sauer
d5518edf12 fixme: bump leftover 0.11 fixme comments 2014-09-25 21:27:03 +02:00
Evan Nemerson
4088363aea introspection: add some missing allow-none annotations to in params
https://bugzilla.gnome.org/show_bug.cgi?id=730957
2014-06-26 19:00:58 +02:00
Evan Nemerson
2759882379 introspection: add missing (nullable) annotations to return values
Support for (nullable) was added to G-I at the same time as nullable
return values.  Previous versions of G-I will not mark return values as
nullable, even when an (allow-none) annotation is present, so it is
not necessary to add (allow-none) annotations for compatibility with
older versions of G-I.

https://bugzilla.gnome.org/show_bug.cgi?id=730957
2014-06-26 18:56:38 +02:00
Tim-Philipp Müller
89a5b89388 value: simplify GST_VALUE_HOLDS for our boxed and fundamental types
Boxed types can't be derived from, and we don't support
deriving from our special fundamental types (the code
checks for GType equality in most places.
2014-06-21 01:10:22 +01:00
Sebastian Dröge
db1e4422b6 gst: Store more basic type GTypes in variables
Micro optimization to change a function call to a variable access
for all our basic types.
2014-06-19 08:06:55 +02: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
Stefan Sauer
cb218f2827 taglist: add a tag for midi base note numbers
Audio files containing sampled instruments can have metadata describing the note
that was played on the instrument.
2013-12-30 14:22:37 +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
Stewart Brodie
e7f514efbc docs: clarify encoding of strings in GstStructures and taglists
https://bugzilla.gnome.org/show_bug.cgi?id=709262
2013-12-06 20:50:19 +00:00
Matthieu Bouron
d10dab0884 taglist: handle publisher and interpreted-by tags
https://bugzilla.gnome.org/show_bug.cgi?id=705999
2013-08-20 14:43:32 +02:00
Nicolas Dufresne
4656d18fd5 Add few missing allow-none annotation 2013-07-03 14:25:07 -04:00
Edward Hervey
0d57bd3198 taglist: Avoid combinatorial explosion when merging tags
When appending/prepending tags, avoid re-creating (and copying) lists if we already
have one and instead just append/prepend the GValue to the list.

https://bugzilla.gnome.org/show_bug.cgi?id=702545
2013-06-19 11:58:37 +02:00
Wim Taymans
f45c84db02 taglist: avoid triggering an assertion
When deserialization of the structure fails, return a NULL taglist instead of
asserting.
2013-04-12 16:17:46 +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
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
Tim-Philipp Müller
e7a77927ff taglist: fix typo in translated string
Spotted by Chris Leonard.

https://bugzilla.gnome.org/show_bug.cgi?id=684755
2012-09-25 13:14:53 +01:00
Tim-Philipp Müller
c2a25bcd0f taglist: add warning when we get something else than a sample for a sample tag
Facilitate GstBuffer -> GstSample transition for some tags,
could be hard to catch otherwise when creating tags, since
it'll only be apparent later when someone tries to read the
tags.
2012-09-13 00:38:21 +01:00
Tim-Philipp Müller
dddcc31c42 docs: fix up docs a bit 2012-08-11 23:41:33 +01:00
Sebastian Dröge
826a8d643d tag: Add a scope to taglists
This specifies if a given taglist applies to the complete
medium or only this specific stream. By default a taglist
has a stream scope.

Fixes bug #677619.
2012-07-28 00:34:41 +02:00
Tim-Philipp Müller
7e98f05afc taglist: make GST_TAG_APPLICATION_DATA also a GstSample
That way additional meta-data can be passed along with it.
2012-07-26 16:44:15 +01:00
Tim-Philipp Müller
3231ea6204 taglist: gst_tag_list_get_buffer*() => gst_tag_list_get_sample*()
Image tags and other tags are now of GstSample type.
2012-07-26 15:51:10 +01:00
Tim-Philipp Müller
48d0d28755 taglist: check value type matches tag type when adding values to a taglist 2012-07-14 19:08:24 +01: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
528f89c940 taglist: fix confusing log message 2012-06-23 21:42:58 +01: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
Tim-Philipp Müller
8973bca63c taglist: remove some outdated FIXMEs and comments 2012-06-23 17:05:22 +01:00
Evan Nemerson
6c6bb0e217 introspection: assorted introspection and documentation fixes
These changes are to clean up syntax issues such as missing colons,
missing spaces, etc., and minor issues such as argument names in
headers not matching the implementation and/or documentation.
2012-06-18 13:11:40 +02:00
Tim-Philipp Müller
e560d7a364 taglist: no need to store the size of the tag list 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
d1379f1671 taglist: add guards to make sure taglist is writable when modifying it
Now that taglists are refcounted we need to check if they're
writable before modifying them.
2012-05-29 08:48:36 +01:00
Tim-Philipp Müller
d007ac4a1a taglist: avoid unnecessary string copying when registering tags
Add gst_tag_register_static() - no need to copy all those
string constants, whether translated or not.

API: gst_tag_register_static()
2012-05-29 08:00:28 +01:00
Tim-Philipp Müller
a88dcc2ab6 taglist: make GstTagList a GstMiniObject
Which adds refcounting support, and other things.
2012-05-28 00:05:16 +01:00