GESTimelineObject
GESTimelineObjectClass
CreateTrackObjectFunc
+CreateTrackObjectsFunc
FillTrackObjectFunc
GES_TIMELINE_OBJECT_DURATION
GES_TIMELINE_OBJECT_INPOINT
ges_timeline_object_set_duration
ges_timeline_object_get_layer
ges_timeline_object_find_track_object
-CreateTrackObjectsFunc
ges_timeline_object_add_track_object
<SUBSECTION Standard>
ges_timeline_object_create_track_objects
* SECTION:ges-timeline-object
* @short_description: Base Class for objects in a #GESTimelineLayer
*
- * Responsible for creating the #GESTrackObject(s) for given #GESTrack(s)
+ * A #GESTimelineObject is a 'natural' object which controls one or more
+ * #GESTrackObject(s) in one or more #GESTrack(s).
*
- * Keeps a reference to the #GESTrackObject(s) it created and sets/updates their properties.
+ * Keeps a reference to the #GESTrackObject(s) it created and
+ * sets/updates their properties.
*/
#include "ges-timeline-object.h"
* @track: The #GESTrack to create each #GESTrackObject for.
*
* Creates all #GESTrackObjects supported by this object and adds them to the
- * provided track. The the track is responsible for calling
+ * provided track. The track is responsible for calling
* #ges_timeline_release_track_object on these objects when it is finished
* with them.
*
- * Returns: True if each track object was created successfully, or false if an
+ * Returns: %TRUE if each track object was created successfully, or %FALSE if an
* error occured.
*/
klass = GES_TIMELINE_OBJECT_GET_CLASS (object);
if (!(klass->create_track_objects)) {
- GST_INFO ("no create_track_objects implentation");
+ GST_WARNING ("no GESTimelineObject::create_track_objects implentation");
return FALSE;
}
return klass->create_track_objects (object, track);
}
+/*
+ * default implementation of GESTimelineObjectClass::create_track_objects
+ */
gboolean
ges_timeline_object_create_track_objects_func (GESTimelineObject * object,
GESTrack * track)
return FALSE;
}
- /* FIXME : Do we need to tell the subclasses ? If so, add a new virtual-method */
+ /* FIXME : Do we need to tell the subclasses ?
+ * If so, add a new virtual-method */
object->priv->trackobjects =
g_list_remove (object->priv->trackobjects, trobj);
* @object: a #GESTimelineObject
* @track: a #GESTrack
*
- * Creates the 'primary track object for this @object.
+ * Creates the 'primary' track object for this @object.
*
- * Implementors should override this function if they only interested in
- * creating a single custom track object per track.
+ * Subclasses should implement this method if they only provide a
+ * single #GESTrackObject per track.
+ *
+ * If the subclass needs to create more than one #GESTrackObject for a
+ * given track, then it should implement the 'create_track_objects'
+ * method instead.
*
* The implementer of this function shall return the proper #GESTrackObject
* that should be controlled by @object for the given @track.
*
- * If the @object can't support the media-type of the @track, this function
- * should return %NULL.
+ * The returned #GESTrackObject will be automatically added to the list
+ * of objects controlled by the #GESTimelineObject.
*
- * Returns: the #GESTrackObject to be used, or %NULL.
+ * Returns: the #GESTrackObject to be used, or %NULL if it can't provide one
+ * for the given @track.
*/
typedef GESTrackObject* (*CreateTrackObjectFunc) (GESTimelineObject * object,
GESTrack * track);
*
* Create all track objects this object handles for this type of track.
*
+ * Subclasses should implement this method if they potentially need to
+ * return more than one #GESTrackObject(s) for a given #GESTrack.
+ *
+ * For each object created, the subclass must call
+ * ges_timeline_object_add_track_object() with the newly created object
+ * and provided @track.
+ *
* Returns: %TRUE on success %FALSE on failure.
*/
typedef gboolean (*CreateTrackObjectsFunc) (GESTimelineObject * object,