ges: Add all missing Since markers from 1.16 onward

Part-of: <https://gitlab.freedesktop.org/gstreamer/gst-editing-services/-/merge_requests/191>
This commit is contained in:
Thibault Saunier 2020-06-19 11:13:24 -04:00
parent c05f9b1d5e
commit fe49c80c8d
19 changed files with 144 additions and 17 deletions

View file

@ -182,6 +182,8 @@ ges_clip_asset_get_supported_formats (GESClipAsset * self)
* @framerate_d: The framerate denominator * @framerate_d: The framerate denominator
* *
* Result: %TRUE if @self has a natural framerate %FALSE otherwise * Result: %TRUE if @self has a natural framerate %FALSE otherwise
*
* Since: 1.18
*/ */
gboolean gboolean
ges_clip_asset_get_natural_framerate (GESClipAsset * self, ges_clip_asset_get_natural_framerate (GESClipAsset * self,
@ -216,6 +218,8 @@ ges_clip_asset_get_natural_framerate (GESClipAsset * self,
* Returns: The timestamp corresponding to @frame_number in the element source, given * Returns: The timestamp corresponding to @frame_number in the element source, given
* in internal time coordinates, or #GST_CLOCK_TIME_NONE if the clip asset does not have a * in internal time coordinates, or #GST_CLOCK_TIME_NONE if the clip asset does not have a
* natural frame rate. * natural frame rate.
*
* Since: 1.18
*/ */
GstClockTime GstClockTime
ges_clip_asset_get_frame_time (GESClipAsset * self, GESFrameNumber frame_number) ges_clip_asset_get_frame_time (GESClipAsset * self, GESFrameNumber frame_number)

View file

@ -45,6 +45,16 @@ struct _GESClipAssetClass
{ {
GESAssetClass parent; GESAssetClass parent;
/**
* GESClipAssetClass::get_natural_framerate:
* @self: A #GESClipAsset
* @framerate_n: The framerate numerator to retrieve
* @framerate_d: The framerate denominator to retrieve
*
* Returns: %TRUE if @self has a natural framerate @FALSE otherwise.
*
* Since: 1.18
*/
gboolean (*get_natural_framerate) (GESClipAsset *self, gint *framerate_n, gint *framerate_d); gboolean (*get_natural_framerate) (GESClipAsset *self, gint *framerate_n, gint *framerate_d);
gpointer _ges_reserved[GES_PADDING - 1]; gpointer _ges_reserved[GES_PADDING - 1];

View file

@ -2590,6 +2590,8 @@ ges_clip_class_init (GESClipClass * klass)
* #GESTimelineElement:duration of the clip due to a change in the above * #GESTimelineElement:duration of the clip due to a change in the above
* variables, its #GESTimelineElement:duration will be set to the new * variables, its #GESTimelineElement:duration will be set to the new
* limit. * limit.
*
* Since: 1.18
*/ */
properties[PROP_DURATION_LIMIT] = properties[PROP_DURATION_LIMIT] =
g_param_spec_uint64 ("duration-limit", "Duration Limit", g_param_spec_uint64 ("duration-limit", "Duration Limit",
@ -4003,6 +4005,8 @@ _active_time_effects_in_track_after_priority (GESClip * clip,
* Returns: The time in the timeline coordinates corresponding to * Returns: The time in the timeline coordinates corresponding to
* @internal_time, or #GST_CLOCK_TIME_NONE if the conversion could not be * @internal_time, or #GST_CLOCK_TIME_NONE if the conversion could not be
* performed. * performed.
*
* Since: 1.18
*/ */
GstClockTime GstClockTime
ges_clip_get_timeline_time_from_internal_time (GESClip * clip, ges_clip_get_timeline_time_from_internal_time (GESClip * clip,
@ -4418,6 +4422,8 @@ ges_clip_get_timeline_time_from_source_frame (GESClip * clip,
* *
* Returns: (transfer none): The element that was added to @track, either * Returns: (transfer none): The element that was added to @track, either
* @child or a copy of child, or %NULL if the element could not be added. * @child or a copy of child, or %NULL if the element could not be added.
*
* Since: 1.18
*/ */
GESTrackElement * GESTrackElement *
ges_clip_add_child_to_track (GESClip * clip, GESTrackElement * child, ges_clip_add_child_to_track (GESClip * clip, GESTrackElement * child,

View file

@ -189,6 +189,14 @@ register_ges_edge (GType * id)
*id = g_enum_register_static ("GESEdge", edges); *id = g_enum_register_static ("GESEdge", edges);
} }
/**
* ges_edge_name:
* @edge: The #GESEdge to get the name of
*
* Returns: A human friendly name for @edge
*
* Since: 1.16
*/
const gchar * const gchar *
ges_edge_name (GESEdge edge) ges_edge_name (GESEdge edge)
{ {

View file

@ -281,6 +281,8 @@ ges_layer_class_init (GESLayerClass * klass)
* *
* Will be emitted whenever the layer is activated or deactivated * Will be emitted whenever the layer is activated or deactivated
* for some #GESTrack. See ges_layer_set_active_for_tracks(). * for some #GESTrack. See ges_layer_set_active_for_tracks().
*
* Since: 1.18
*/ */
ges_layer_signals[ACTIVE_CHANGED] = ges_layer_signals[ACTIVE_CHANGED] =
g_signal_new ("active-changed", G_TYPE_FROM_CLASS (klass), g_signal_new ("active-changed", G_TYPE_FROM_CLASS (klass),
@ -1026,6 +1028,8 @@ ges_layer_get_clips_in_interval (GESLayer * layer, GstClockTime start,
* ges_layer_set_active_for_tracks(). * ges_layer_set_active_for_tracks().
* *
* Returns: %TRUE if @layer is active for @track, or %FALSE otherwise. * Returns: %TRUE if @layer is active for @track, or %FALSE otherwise.
*
* Since: 1.18
*/ */
gboolean gboolean
ges_layer_get_active_for_track (GESLayer * layer, GESTrack * track) ges_layer_get_active_for_track (GESLayer * layer, GESTrack * track)
@ -1062,6 +1066,8 @@ ges_layer_get_active_for_track (GESLayer * layer, GESTrack * track)
* timeline's tracks. * timeline's tracks.
* *
* Returns: %TRUE if the operation worked %FALSE otherwise. * Returns: %TRUE if the operation worked %FALSE otherwise.
*
* Since: 1.18
*/ */
gboolean gboolean
ges_layer_set_active_for_tracks (GESLayer * layer, gboolean active, ges_layer_set_active_for_tracks (GESLayer * layer, gboolean active,

View file

@ -38,8 +38,6 @@
#include "ges-internal.h" #include "ges-internal.h"
#include "ges-meta-container.h" #include "ges-meta-container.h"
/* GESMarker */
static void ges_meta_container_interface_init (GESMetaContainerInterface * static void ges_meta_container_interface_init (GESMetaContainerInterface *
iface); iface);
@ -92,10 +90,12 @@ ges_marker_class_init (GESMarkerClass * klass)
GObjectClass *object_class = G_OBJECT_CLASS (klass); GObjectClass *object_class = G_OBJECT_CLASS (klass);
object_class->get_property = ges_marker_get_property; object_class->get_property = ges_marker_get_property;
/** /**
* GESMarker:position: * GESMarker:position:
* *
* Current position (in nanoseconds) of the #GESMarker * Current position (in nanoseconds) of the #GESMarker
*
* Since: 1.18
*/ */
properties[PROP_POSITION] = properties[PROP_POSITION] =
g_param_spec_uint64 ("position", "Position", g_param_spec_uint64 ("position", "Position",
@ -321,7 +321,7 @@ done:
/** /**
* ges_marker_list_get_markers: * ges_marker_list_get_markers:
* *
* Returns: (element-type GESMarker) (transfer full): a #GList * Returns: (element-type GESMarker) (transfer full): a #GList
* of the #GESMarker within the GESMarkerList. The user will have * of the #GESMarker within the GESMarkerList. The user will have
* to unref each #GESMarker and free the #GList. * to unref each #GESMarker and free the #GList.
* *
@ -350,7 +350,7 @@ ges_marker_list_get_markers (GESMarkerList * self)
/** /**
* ges_marker_list_move: * ges_marker_list_move:
* *
* Moves a @marker in a @list to a new @position * Moves a @marker in a @list to a new @position
* *
* Returns: %TRUE if the marker could be moved, %FALSE otherwise * Returns: %TRUE if the marker could be moved, %FALSE otherwise

View file

@ -27,11 +27,24 @@ G_BEGIN_DECLS
#define GES_TYPE_MARKER ges_marker_get_type () #define GES_TYPE_MARKER ges_marker_get_type ()
/**
* GESMarker:
*
* A timed #GESMetaContainer object.
*
* Since: 1.18
*/
GES_API GES_API
G_DECLARE_FINAL_TYPE (GESMarker, ges_marker, GES, MARKER, GObject) G_DECLARE_FINAL_TYPE (GESMarker, ges_marker, GES, MARKER, GObject)
#define GES_TYPE_MARKER_LIST ges_marker_list_get_type () #define GES_TYPE_MARKER_LIST ges_marker_list_get_type ()
/**
* GESMarkerList:
*
* A list of #GESMarker
*
* Since: 1.18
*/
GES_API GES_API
G_DECLARE_FINAL_TYPE (GESMarkerList, ges_marker_list, GES, MARKER_LIST, GObject) G_DECLARE_FINAL_TYPE (GESMarkerList, ges_marker_list, GES, MARKER_LIST, GObject)

View file

@ -594,6 +594,8 @@ ges_meta_container_add_metas_from_string (GESMetaContainer * container,
* *
* Returns: %TRUE if the @meta_item field was successfully registered on * Returns: %TRUE if the @meta_item field was successfully registered on
* @container to only hold @type values, with the given @flags. * @container to only hold @type values, with the given @flags.
*
* Since: 1.18
*/ */
gboolean gboolean
ges_meta_container_register_static_meta (GESMetaContainer * container, ges_meta_container_register_static_meta (GESMetaContainer * container,

View file

@ -61,8 +61,15 @@ struct _GESProjectClass
GType extractable_type); GType extractable_type);
gboolean (*loaded) (GESProject * self, gboolean (*loaded) (GESProject * self,
GESTimeline * timeline); GESTimeline * timeline);
gboolean (*loading) (GESProject * self, /**
GESTimeline * timeline); * GESProjectClass::loading:
* @self: The self
* @timeline: The loading timeline
*
* Since: 1.18
*/
void (*loading) (GESProject * self,
GESTimeline * timeline);
gpointer _ges_reserved[GES_PADDING - 1]; gpointer _ges_reserved[GES_PADDING - 1];
}; };

View file

@ -26,6 +26,13 @@ G_BEGIN_DECLS
#define GES_TYPE_SOURCE_CLIP_ASSET ges_source_clip_asset_get_type () #define GES_TYPE_SOURCE_CLIP_ASSET ges_source_clip_asset_get_type ()
/**
* GESSourceClipAsset:
*
* An asset types from which #GESSourceClip will be extracted
*
* Since: 1.18
*/
GES_API GES_API
G_DECLARE_DERIVABLE_TYPE(GESSourceClipAsset, ges_source_clip_asset, GES, G_DECLARE_DERIVABLE_TYPE(GESSourceClipAsset, ges_source_clip_asset, GES,
SOURCE_CLIP_ASSET, GESClipAsset); SOURCE_CLIP_ASSET, GESClipAsset);

View file

@ -584,6 +584,8 @@ ges_timeline_element_class_init (GESTimelineElementClass * klass)
* Note that some GES elements will be automatically created with * Note that some GES elements will be automatically created with
* pre-registered children properties. You can use * pre-registered children properties. You can use
* ges_timeline_element_list_children_properties() to list these. * ges_timeline_element_list_children_properties() to list these.
*
* Since: 1.18
*/ */
ges_timeline_element_signals[CHILD_PROPERTY_ADDED] = ges_timeline_element_signals[CHILD_PROPERTY_ADDED] =
g_signal_new ("child-property-added", G_TYPE_FROM_CLASS (klass), g_signal_new ("child-property-added", G_TYPE_FROM_CLASS (klass),
@ -598,6 +600,8 @@ ges_timeline_element_class_init (GESTimelineElementClass * klass)
* *
* Emitted when the element has a child property unregistered. See * Emitted when the element has a child property unregistered. See
* ges_timeline_element_remove_child_property(). * ges_timeline_element_remove_child_property().
*
* Since: 1.18
*/ */
ges_timeline_element_signals[CHILD_PROPERTY_REMOVED] = ges_timeline_element_signals[CHILD_PROPERTY_REMOVED] =
g_signal_new ("child-property-removed", G_TYPE_FROM_CLASS (klass), g_signal_new ("child-property-removed", G_TYPE_FROM_CLASS (klass),

View file

@ -214,14 +214,6 @@ struct _GESTimelineElement
* to redirect property names. Or overwrite to change which child is * to redirect property names. Or overwrite to change which child is
* returned if multiple children share the same child property name. * returned if multiple children share the same child property name.
* @get_track_types: Return a the track types for the element. * @get_track_types: Return a the track types for the element.
* @set_child_property: Method for setting the child property given by
* @pspec on @child to @value. Default implementation will use
* g_object_set_property().
* @set_child_property_full: Similar to @set_child_property, except
* setting can fail, with the @error being optionally set. Default
* implementation will call @set_child_property and return %TRUE.
* @get_layer_priority: Get the #GESLayer:priority of the layer that this
* element is part of. (Since: 1.18)
* @list_children_properties: List the children properties that have been * @list_children_properties: List the children properties that have been
* registered for the element. The default implementation is able to fetch * registered for the element. The default implementation is able to fetch
* all of these, so should be sufficient. If you overwrite this, you * all of these, so should be sufficient. If you overwrite this, you
@ -268,16 +260,52 @@ struct _GESTimelineElementClass
gboolean (*lookup_child) (GESTimelineElement *self, const gchar *prop_name, gboolean (*lookup_child) (GESTimelineElement *self, const gchar *prop_name,
GObject **child, GParamSpec **pspec); GObject **child, GParamSpec **pspec);
GESTrackType (*get_track_types) (GESTimelineElement * self); GESTrackType (*get_track_types) (GESTimelineElement * self);
/**
* GESTimelineElementClass::set_child_property:
*
* Method for setting the child property given by
* @pspec on @child to @value. Default implementation will use
* g_object_set_property().
*
* Since: 1.16
*/
void (*set_child_property) (GESTimelineElement * self, void (*set_child_property) (GESTimelineElement * self,
GObject *child, GObject *child,
GParamSpec *pspec, GParamSpec *pspec,
GValue *value); GValue *value);
/**
* GESTimelineElementClass::get_layer_priority:
*
* Get the #GESLayer:priority of the layer that this
* element is part of.
*
* Since: 1.16
*/
guint32 (*get_layer_priority) (GESTimelineElement *self); guint32 (*get_layer_priority) (GESTimelineElement *self);
/*< private > */ /**
* GESTimelineElementClass::get_natural_framerate:
* @self: A #GESTimelineElement
* @framerate_n: The framerate numerator to retrieve
* @framerate_d: The framerate denominator to retrieve
*
* Returns: %TRUE if @self has a natural framerate @FALSE otherwise.
*
* Since: 1.18
*/
gboolean (*get_natural_framerate) (GESTimelineElement * self, gint *framerate_n, gint *framerate_d); gboolean (*get_natural_framerate) (GESTimelineElement * self, gint *framerate_n, gint *framerate_d);
/**
* GESTimelineElementClass::set_child_property_full:
*
* Similar to @set_child_property, except setting can fail, with the @error
* being optionally set. Default implementation will call @set_child_property
* and return %TRUE.
*
* Since: 1.18
*/
gboolean (*set_child_property_full) (GESTimelineElement * self, gboolean (*set_child_property_full) (GESTimelineElement * self,
GObject *child, GObject *child,
GParamSpec *pspec, GParamSpec *pspec,

View file

@ -3223,6 +3223,8 @@ ges_timeline_move_layer (GESTimeline * timeline, GESLayer * layer,
* an element within the timeline. * an element within the timeline.
* *
* Returns: The timestamp corresponding to @frame_number in the output of @self. * Returns: The timestamp corresponding to @frame_number in the output of @self.
*
* Since: 1.18
*/ */
GstClockTime GstClockTime
ges_timeline_get_frame_time (GESTimeline * self, GESFrameNumber frame_number) ges_timeline_get_frame_time (GESTimeline * self, GESFrameNumber frame_number)
@ -3247,6 +3249,8 @@ ges_timeline_get_frame_time (GESTimeline * self, GESFrameNumber frame_number)
* corresponding #GESFrameNumber in the timeline's output. * corresponding #GESFrameNumber in the timeline's output.
* *
* Returns: The frame number @timestamp corresponds to. * Returns: The frame number @timestamp corresponds to.
*
* Since: 1.18
*/ */
GESFrameNumber GESFrameNumber
ges_timeline_get_frame_at (GESTimeline * self, GstClockTime timestamp) ges_timeline_get_frame_at (GESTimeline * self, GstClockTime timestamp)

View file

@ -151,6 +151,8 @@ ges_track_element_asset_get_track_type (GESTrackElementAsset * asset)
* @framerate_d: The framerate denominator * @framerate_d: The framerate denominator
* *
* Result: %TRUE if @self has a natural framerate %FALSE otherwise * Result: %TRUE if @self has a natural framerate %FALSE otherwise
*
* Since: 1.18
*/ */
gboolean gboolean
ges_track_element_asset_get_natural_framerate (GESTrackElementAsset * self, ges_track_element_asset_get_natural_framerate (GESTrackElementAsset * self,

View file

@ -44,6 +44,16 @@ struct _GESTrackElementAssetClass
{ {
GESAssetClass parent_class; GESAssetClass parent_class;
/**
* GESTrackElementAssetClass::get_natural_framerate:
* @self: A #GESTrackElementAsset
* @framerate_n: The framerate numerator to retrieve
* @framerate_d: The framerate denominator to retrieve
*
* Returns: %TRUE if @self has a natural framerate @FALSE otherwise.
*
* Since: 1.18
*/
gboolean (*get_natural_framerate) (GESTrackElementAsset *self, gint *framerate_n, gint *framerate_d); gboolean (*get_natural_framerate) (GESTrackElementAsset *self, gint *framerate_n, gint *framerate_d);
gpointer _ges_reserved[GES_PADDING - 1]; gpointer _ges_reserved[GES_PADDING - 1];

View file

@ -421,6 +421,8 @@ ges_track_element_class_init (GESTrackElementClass * klass)
* Note that GES can not support track elements that have both internal * Note that GES can not support track elements that have both internal
* content and manipulate the timing of their data streams (time * content and manipulate the timing of their data streams (time
* effects). * effects).
*
* Since: 1.18
*/ */
properties[PROP_HAS_INTERNAL_SOURCE] = properties[PROP_HAS_INTERNAL_SOURCE] =
g_param_spec_boolean ("has-internal-source", "Has Internal Source", g_param_spec_boolean ("has-internal-source", "Has Internal Source",
@ -441,6 +443,8 @@ ges_track_element_class_init (GESTrackElementClass * klass)
* per control source. * per control source.
* *
* Default value: %TRUE * Default value: %TRUE
*
* Since: 1.18
*/ */
properties[PROP_AUTO_CLAMP_CONTROL_SOURCES] = properties[PROP_AUTO_CLAMP_CONTROL_SOURCES] =
g_param_spec_boolean ("auto-clamp-control-sources", g_param_spec_boolean ("auto-clamp-control-sources",
@ -903,6 +907,8 @@ ges_track_element_set_active (GESTrackElement * object, gboolean active)
* *
* Returns: %FALSE if @has_internal_source is forbidden for @object and * Returns: %FALSE if @has_internal_source is forbidden for @object and
* %TRUE in any other case. * %TRUE in any other case.
*
* Since: 1.18
*/ */
gboolean gboolean
ges_track_element_set_has_internal_source (GESTrackElement * object, ges_track_element_set_has_internal_source (GESTrackElement * object,
@ -1346,6 +1352,8 @@ ges_track_element_is_active (GESTrackElement * object)
* Gets #GESTrackElement:has-internal-source for the element. * Gets #GESTrackElement:has-internal-source for the element.
* *
* Returns: %TRUE if @object can have its 'internal time' properties set. * Returns: %TRUE if @object can have its 'internal time' properties set.
*
* Since: 1.18
*/ */
gboolean gboolean
ges_track_element_has_internal_source (GESTrackElement * object) ges_track_element_has_internal_source (GESTrackElement * object)

View file

@ -47,6 +47,8 @@ G_BEGIN_DECLS
* GESFrameNumber: * GESFrameNumber:
* *
* A datatype to hold a frame number. * A datatype to hold a frame number.
*
* Since: 1.18
*/ */
typedef gint64 GESFrameNumber; typedef gint64 GESFrameNumber;

View file

@ -602,6 +602,8 @@ ges_uri_clip_asset_get_max_duration (GESUriClipAsset * self)
* Gets Whether the file represented by @self is an image or not * Gets Whether the file represented by @self is an image or not
* *
* Returns: Whether the file represented by @self is an image or not * Returns: Whether the file represented by @self is an image or not
*
* Since: 1.18
*/ */
gboolean gboolean
ges_uri_clip_asset_is_image (GESUriClipAsset * self) ges_uri_clip_asset_is_image (GESUriClipAsset * self)
@ -898,6 +900,8 @@ ges_uri_source_asset_get_filesource_asset (GESUriSourceAsset * asset)
* *
* Returns: %TRUE if the video stream corresponds to an image (i.e. only * Returns: %TRUE if the video stream corresponds to an image (i.e. only
* contains one frame) * contains one frame)
*
* Since: 1.18
*/ */
gboolean gboolean
ges_uri_source_asset_is_image (GESUriSourceAsset * asset) ges_uri_source_asset_is_image (GESUriSourceAsset * asset)

View file

@ -255,6 +255,8 @@ ges_video_source_init (GESVideoSource * self)
* account. * account.
* *
* Returns: %TRUE if the object has a natural size, %FALSE otherwise. * Returns: %TRUE if the object has a natural size, %FALSE otherwise.
*
* Since: 1.18
*/ */
gboolean gboolean
ges_video_source_get_natural_size (GESVideoSource * self, gint * width, ges_video_source_get_natural_size (GESVideoSource * self, gint * width,