mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-01-10 17:35:59 +00:00
Rename GESTimelineTransition to GESTransitionClip
This commit is contained in:
parent
192d8a6f4d
commit
b73cf7c3d7
20 changed files with 79 additions and 79 deletions
|
@ -19,7 +19,7 @@ LOCAL_SRC_FILES := \
|
|||
ges-timeline-source.c \
|
||||
ges-uri-clip.c \
|
||||
ges-timeline-operation.c \
|
||||
ges-timeline-transition.c \
|
||||
ges-transition-clip.c \
|
||||
ges-timeline-standard-transition.c \
|
||||
ges-timeline-test-source.c \
|
||||
ges-timeline-title-source.c \
|
||||
|
|
|
@ -47,7 +47,7 @@ platform as well as Windows. It is released under the GNU Library General Public
|
|||
<xi:include href="xml/ges-track-source.xml"/>
|
||||
<xi:include href="xml/ges-track-effect.xml"/>
|
||||
<xi:include href="xml/ges-track-operation.xml"/>
|
||||
<xi:include href="xml/ges-timeline-transition.xml"/>
|
||||
<xi:include href="xml/ges-transition-clip.xml"/>
|
||||
<xi:include href="xml/ges-asset.xml"/>
|
||||
</chapter>
|
||||
|
||||
|
|
|
@ -495,19 +495,19 @@ GES_TYPE_TIMELINE_OVERLAY
|
|||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>ges-timeline-transition</FILE>
|
||||
<TITLE>GESTimelineTransition</TITLE>
|
||||
GESTimelineTransition
|
||||
<FILE>ges-transition-clip</FILE>
|
||||
<TITLE>GESTransitionClip</TITLE>
|
||||
GESTransitionClip
|
||||
<SUBSECTION Standard>
|
||||
GESTimelineTransitionClass
|
||||
GESTimelineTransitionPrivate
|
||||
GES_TIMELINE_TRANSITION
|
||||
GES_IS_TIMELINE_TRANSITION
|
||||
GES_TYPE_TIMELINE_TRANSITION
|
||||
ges_timeline_transition_get_type
|
||||
GES_TIMELINE_TRANSITION_CLASS
|
||||
GES_IS_TIMELINE_TRANSITION_CLASS
|
||||
GES_TIMELINE_TRANSITION_GET_CLASS
|
||||
GESTransitionClipClass
|
||||
GESTransitionClipPrivate
|
||||
GES_TRANSITION_CLIP
|
||||
GES_IS_TRANSITION_CLIP
|
||||
GES_TYPE_TRANSITION_CLIP
|
||||
ges_transition_clip_get_type
|
||||
GES_TRANSITION_CLIP_CLASS
|
||||
GES_IS_TRANSITION_CLIP_CLASS
|
||||
GES_TRANSITION_CLIP_GET_CLASS
|
||||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
|
|
|
@ -14,7 +14,7 @@ ges_timeline_overlay_get_type
|
|||
ges_timeline_pipeline_get_type
|
||||
ges_timeline_source_get_type
|
||||
ges_timeline_test_source_get_type
|
||||
ges_timeline_transition_get_type
|
||||
ges_transition_clip_get_type
|
||||
ges_timeline_standard_transition_get_type
|
||||
ges_effect_clip_get_type
|
||||
ges_timeline_parse_launch_effect_get_type
|
||||
|
|
|
@ -23,7 +23,7 @@ libges_@GST_API_VERSION@_la_SOURCES = \
|
|||
ges-timeline-parse-launch-effect.c \
|
||||
ges-uri-clip.c \
|
||||
ges-timeline-operation.c \
|
||||
ges-timeline-transition.c \
|
||||
ges-transition-clip.c \
|
||||
ges-timeline-standard-transition.c \
|
||||
ges-timeline-test-source.c \
|
||||
ges-timeline-title-source.c \
|
||||
|
@ -77,7 +77,7 @@ libges_@GST_API_VERSION@include_HEADERS = \
|
|||
ges-effect-clip.h \
|
||||
ges-timeline-parse-launch-effect.h \
|
||||
ges-timeline-operation.h \
|
||||
ges-timeline-transition.h \
|
||||
ges-transition-clip.h \
|
||||
ges-timeline-standard-transition.h \
|
||||
ges-timeline-test-source.h \
|
||||
ges-timeline-title-source.h \
|
||||
|
|
|
@ -17,8 +17,8 @@
|
|||
* along with this program. If not, see <http://www.gnu.org/licenses/>.";
|
||||
*/
|
||||
|
||||
/* This class warps a GESTimelineTransition, letting any implementation
|
||||
* of a GESTimelineTransition to be used.
|
||||
/* This class warps a GESTransitionClip, letting any implementation
|
||||
* of a GESTransitionClip to be used.
|
||||
*
|
||||
* NOTE: This is for internal use exclusively
|
||||
*/
|
||||
|
@ -61,10 +61,9 @@ neighbour_changed_cb (GESClip * obj, GParamSpec * arg G_GNUC_UNUSED,
|
|||
return;
|
||||
}
|
||||
|
||||
_set_start0 (GES_TIMELINE_ELEMENT (self->timeline_transition),
|
||||
_set_start0 (GES_TIMELINE_ELEMENT (self->transition_clip),
|
||||
_START (self->next_source));
|
||||
_set_duration0 (GES_TIMELINE_ELEMENT (self->timeline_transition),
|
||||
new_duration);
|
||||
_set_duration0 (GES_TIMELINE_ELEMENT (self->transition_clip), new_duration);
|
||||
}
|
||||
|
||||
static void
|
||||
|
@ -141,7 +140,7 @@ ges_auto_transition_new (GESTrackObject * transition,
|
|||
|
||||
self->previous_clip = ges_track_object_get_clip (previous_source);
|
||||
self->next_clip = ges_track_object_get_clip (next_source);
|
||||
self->timeline_transition = ges_track_object_get_clip (transition);
|
||||
self->transition_clip = ges_track_object_get_clip (transition);
|
||||
|
||||
g_signal_connect (previous_source, "notify::start",
|
||||
G_CALLBACK (neighbour_changed_cb), self);
|
||||
|
|
|
@ -60,7 +60,7 @@ struct _GESAutoTransition
|
|||
|
||||
GESClip *previous_clip;
|
||||
GESClip *next_clip;
|
||||
GESClip *timeline_transition;
|
||||
GESClip *transition_clip;
|
||||
|
||||
gchar *key;
|
||||
|
||||
|
|
|
@ -14,7 +14,8 @@ static GQuark ges_meta_key;
|
|||
|
||||
G_DEFINE_INTERFACE_WITH_CODE (GESMetaContainer, ges_meta_container,
|
||||
G_TYPE_OBJECT, ges_meta_key =
|
||||
g_quark_from_static_string ("ges-meta-container-data"););
|
||||
g_quark_from_static_string ("ges-meta-container-data");
|
||||
);
|
||||
|
||||
enum
|
||||
{
|
||||
|
|
|
@ -27,9 +27,9 @@
|
|||
* GESSimpleTimelineLayer, and the layer will automatically compute the
|
||||
* appropriate start times.
|
||||
*
|
||||
* Users should be aware that GESTimelineTransition objects are considered to
|
||||
* Users should be aware that GESTransitionClip objects are considered to
|
||||
* have a negative duration for the purposes of positioning GESTimelineSource
|
||||
* objects (i.e., adding a GESTimelineTransition creates an overlap between
|
||||
* objects (i.e., adding a GESTransitionClip creates an overlap between
|
||||
* the two adjacent sources.
|
||||
*/
|
||||
|
||||
|
@ -174,7 +174,7 @@ gstl_recalculate (GESSimpleTimelineLayer * self)
|
|||
|
||||
GST_DEBUG ("recalculating values");
|
||||
|
||||
if (priv->objects && GES_IS_TIMELINE_TRANSITION (priv->objects->data)) {
|
||||
if (priv->objects && GES_IS_TRANSITION_CLIP (priv->objects->data)) {
|
||||
valid = FALSE;
|
||||
}
|
||||
|
||||
|
@ -205,7 +205,7 @@ gstl_recalculate (GESSimpleTimelineLayer * self)
|
|||
|
||||
g_assert (priority != -1);
|
||||
|
||||
} else if (GES_IS_TIMELINE_TRANSITION (obj)) {
|
||||
} else if (GES_IS_TRANSITION_CLIP (obj)) {
|
||||
|
||||
pos -= dur;
|
||||
if (pos < 0)
|
||||
|
@ -227,7 +227,7 @@ gstl_recalculate (GESSimpleTimelineLayer * self)
|
|||
/* sanity checks */
|
||||
l_next = g_list_next (tmp);
|
||||
|
||||
if (GES_IS_TIMELINE_TRANSITION (prev_object)) {
|
||||
if (GES_IS_TRANSITION_CLIP (prev_object)) {
|
||||
GST_ERROR ("two transitions in sequence!");
|
||||
valid = FALSE;
|
||||
}
|
||||
|
@ -261,7 +261,7 @@ gstl_recalculate (GESSimpleTimelineLayer * self)
|
|||
|
||||
}
|
||||
|
||||
if (prev_object && GES_IS_TIMELINE_TRANSITION (prev_object)) {
|
||||
if (prev_object && GES_IS_TRANSITION_CLIP (prev_object)) {
|
||||
valid = FALSE;
|
||||
}
|
||||
|
||||
|
@ -307,14 +307,14 @@ ges_simple_timeline_layer_add_object (GESSimpleTimelineLayer * layer,
|
|||
|
||||
nth = g_list_nth (priv->objects, position);
|
||||
|
||||
if (GES_IS_TIMELINE_TRANSITION (object)) {
|
||||
if (GES_IS_TRANSITION_CLIP (object)) {
|
||||
GList *lprev = g_list_previous (nth);
|
||||
|
||||
GESClip *prev = GES_CLIP (lprev ? lprev->data : NULL);
|
||||
GESClip *next = GES_CLIP (nth ? nth->data : NULL);
|
||||
|
||||
if ((prev && GES_IS_TIMELINE_TRANSITION (prev)) ||
|
||||
(next && GES_IS_TIMELINE_TRANSITION (next))) {
|
||||
if ((prev && GES_IS_TRANSITION_CLIP (prev)) ||
|
||||
(next && GES_IS_TRANSITION_CLIP (next))) {
|
||||
GST_ERROR ("Not adding transition: Only insert transitions between two"
|
||||
" sources, or at the begining or end the layer\n");
|
||||
return FALSE;
|
||||
|
|
|
@ -374,8 +374,8 @@ ges_timeline_pipeline_change_state (GstElement * element,
|
|||
ret = GST_STATE_CHANGE_FAILURE;
|
||||
goto done;
|
||||
}
|
||||
if (self->
|
||||
priv->mode & (TIMELINE_MODE_RENDER | TIMELINE_MODE_SMART_RENDER))
|
||||
if (self->priv->
|
||||
mode & (TIMELINE_MODE_RENDER | TIMELINE_MODE_SMART_RENDER))
|
||||
GST_DEBUG ("rendering => Updating pipeline caps");
|
||||
if (!ges_timeline_pipeline_update_caps (self)) {
|
||||
GST_ERROR_OBJECT (element, "Error setting the caps for rendering");
|
||||
|
|
|
@ -196,7 +196,7 @@ ges_extractable_interface_init (GESExtractableInterface * iface)
|
|||
}
|
||||
|
||||
G_DEFINE_TYPE_WITH_CODE (GESTimelineStandardTransition,
|
||||
ges_timeline_standard_transition, GES_TYPE_TIMELINE_TRANSITION,
|
||||
ges_timeline_standard_transition, GES_TYPE_TRANSITION_CLIP,
|
||||
G_IMPLEMENT_INTERFACE (GES_TYPE_EXTRACTABLE,
|
||||
ges_extractable_interface_init));
|
||||
|
||||
|
|
|
@ -23,7 +23,7 @@
|
|||
|
||||
#include <glib-object.h>
|
||||
#include <ges/ges-types.h>
|
||||
#include <ges/ges-timeline-transition.h>
|
||||
#include <ges/ges-transition-clip.h>
|
||||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
|
@ -53,7 +53,7 @@ typedef struct _GESTimelineStandardTransitionPrivate GESTimelineStandardTransiti
|
|||
*/
|
||||
struct _GESTimelineStandardTransition {
|
||||
/*< private >*/
|
||||
GESTimelineTransition parent;
|
||||
GESTransitionClip parent;
|
||||
|
||||
/*< public >*/
|
||||
GESVideoStandardTransitionType vtype;
|
||||
|
@ -72,7 +72,7 @@ struct _GESTimelineStandardTransition {
|
|||
|
||||
struct _GESTimelineStandardTransitionClass {
|
||||
/*< private >*/
|
||||
GESTimelineTransitionClass parent_class;
|
||||
GESTransitionClipClass parent_class;
|
||||
|
||||
/* Padding for API extension */
|
||||
gpointer _ges_reserved[GES_PADDING];
|
||||
|
|
|
@ -653,7 +653,7 @@ _destroy_auto_transition_cb (GESAutoTransition * auto_transition,
|
|||
GESTimeline * timeline)
|
||||
{
|
||||
GESTimelinePrivate *priv = timeline->priv;
|
||||
GESClip *transition = auto_transition->timeline_transition;
|
||||
GESClip *transition = auto_transition->transition_clip;
|
||||
GESTimelineLayer *layer = ges_clip_get_layer (transition);
|
||||
|
||||
ges_timeline_layer_remove_object (layer, transition);
|
||||
|
|
|
@ -19,31 +19,31 @@
|
|||
*/
|
||||
|
||||
/**
|
||||
* SECTION: ges-timeline-transition
|
||||
* SECTION: ges-transition-clip
|
||||
* @short_description: Base classes for transitions
|
||||
*/
|
||||
|
||||
#include <ges/ges.h>
|
||||
#include "ges-internal.h"
|
||||
|
||||
struct _GESTimelineTransitionPrivate
|
||||
struct _GESTransitionClipPrivate
|
||||
{
|
||||
/* Dummy variable */
|
||||
void *nothing;
|
||||
};
|
||||
|
||||
G_DEFINE_ABSTRACT_TYPE (GESTimelineTransition, ges_timeline_transition,
|
||||
G_DEFINE_ABSTRACT_TYPE (GESTransitionClip, ges_transition_clip,
|
||||
GES_TYPE_TIMELINE_OPERATION);
|
||||
|
||||
static void
|
||||
ges_timeline_transition_class_init (GESTimelineTransitionClass * klass)
|
||||
ges_transition_clip_class_init (GESTransitionClipClass * klass)
|
||||
{
|
||||
g_type_class_add_private (klass, sizeof (GESTimelineTransitionPrivate));
|
||||
g_type_class_add_private (klass, sizeof (GESTransitionClipPrivate));
|
||||
}
|
||||
|
||||
static void
|
||||
ges_timeline_transition_init (GESTimelineTransition * self)
|
||||
ges_transition_clip_init (GESTransitionClip * self)
|
||||
{
|
||||
self->priv = G_TYPE_INSTANCE_GET_PRIVATE (self,
|
||||
GES_TYPE_TIMELINE_TRANSITION, GESTimelineTransitionPrivate);
|
||||
GES_TYPE_TRANSITION_CLIP, GESTransitionClipPrivate);
|
||||
}
|
|
@ -18,8 +18,8 @@
|
|||
* Boston, MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
#ifndef _GES_TIMELINE_TRANSITION
|
||||
#define _GES_TIMELINE_TRANSITION
|
||||
#ifndef _GES_TRANSITION_CLIP
|
||||
#define _GES_TRANSITION_CLIP
|
||||
|
||||
#include "ges-timeline-operation.h"
|
||||
|
||||
|
@ -28,45 +28,45 @@
|
|||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GES_TYPE_TIMELINE_TRANSITION ges_timeline_transition_get_type()
|
||||
#define GES_TYPE_TRANSITION_CLIP ges_transition_clip_get_type()
|
||||
|
||||
#define GES_TIMELINE_TRANSITION(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GES_TYPE_TIMELINE_TRANSITION, GESTimelineTransition))
|
||||
#define GES_TRANSITION_CLIP(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GES_TYPE_TRANSITION_CLIP, GESTransitionClip))
|
||||
|
||||
#define GES_TIMELINE_TRANSITION_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_CAST ((klass), GES_TYPE_TIMELINE_TRANSITION, GESTimelineTransitionClass))
|
||||
#define GES_TRANSITION_CLIP_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_CAST ((klass), GES_TYPE_TRANSITION_CLIP, GESTransitionClipClass))
|
||||
|
||||
#define GES_IS_TIMELINE_TRANSITION(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GES_TYPE_TIMELINE_TRANSITION))
|
||||
#define GES_IS_TRANSITION_CLIP(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GES_TYPE_TRANSITION_CLIP))
|
||||
|
||||
#define GES_IS_TIMELINE_TRANSITION_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GES_TYPE_TIMELINE_TRANSITION))
|
||||
#define GES_IS_TRANSITION_CLIP_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GES_TYPE_TRANSITION_CLIP))
|
||||
|
||||
#define GES_TIMELINE_TRANSITION_GET_CLASS(obj) \
|
||||
(G_TYPE_INSTANCE_GET_CLASS ((obj), GES_TYPE_TIMELINE_TRANSITION, GESTimelineTransitionClass))
|
||||
#define GES_TRANSITION_CLIP_GET_CLASS(obj) \
|
||||
(G_TYPE_INSTANCE_GET_CLASS ((obj), GES_TYPE_TRANSITION_CLIP, GESTransitionClipClass))
|
||||
|
||||
typedef struct _GESTimelineTransitionPrivate GESTimelineTransitionPrivate;
|
||||
typedef struct _GESTransitionClipPrivate GESTransitionClipPrivate;
|
||||
|
||||
/**
|
||||
* GESTimelineTransition:
|
||||
* GESTransitionClip:
|
||||
*/
|
||||
struct _GESTimelineTransition {
|
||||
struct _GESTransitionClip {
|
||||
/*< private >*/
|
||||
GESTimelineOperation parent;
|
||||
|
||||
/*< private >*/
|
||||
GESTimelineTransitionPrivate *priv;
|
||||
GESTransitionClipPrivate *priv;
|
||||
|
||||
/* Padding for API extension */
|
||||
gpointer _ges_reserved[GES_PADDING];
|
||||
};
|
||||
|
||||
/**
|
||||
* GESTimelineTransitionClass:
|
||||
* GESTransitionClipClass:
|
||||
*
|
||||
*/
|
||||
|
||||
struct _GESTimelineTransitionClass {
|
||||
struct _GESTransitionClipClass {
|
||||
/*< private >*/
|
||||
GESTimelineOperationClass parent_class;
|
||||
|
||||
|
@ -74,8 +74,8 @@ struct _GESTimelineTransitionClass {
|
|||
gpointer _ges_reserved[GES_PADDING];
|
||||
};
|
||||
|
||||
GType ges_timeline_transition_get_type (void);
|
||||
GType ges_transition_clip_get_type (void);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* _GES_TIMELINE_TRANSITION */
|
||||
#endif /* _GES_TRANSITION_CLIP */
|
|
@ -62,8 +62,8 @@ typedef struct _GESEffectClipClass GESEffectClipClass;
|
|||
typedef struct _GESUriClip GESUriClip;
|
||||
typedef struct _GESUriClipClass GESUriClipClass;
|
||||
|
||||
typedef struct _GESTimelineTransition GESTimelineTransition;
|
||||
typedef struct _GESTimelineTransitionClass GESTimelineTransitionClass;
|
||||
typedef struct _GESTransitionClip GESTransitionClip;
|
||||
typedef struct _GESTransitionClipClass GESTransitionClipClass;
|
||||
|
||||
typedef struct _GESTimelineStandardTransition GESTimelineStandardTransition;
|
||||
typedef struct _GESTimelineStandardTransitionClass GESTimelineStandardTransitionClass;
|
||||
|
|
|
@ -39,7 +39,7 @@
|
|||
#include <ges/ges-effect-clip.h>
|
||||
#include <ges/ges-timeline-overlay.h>
|
||||
#include <ges/ges-timeline-text-overlay.h>
|
||||
#include <ges/ges-timeline-transition.h>
|
||||
#include <ges/ges-transition-clip.h>
|
||||
#include <ges/ges-timeline-standard-transition.h>
|
||||
#include <ges/ges-timeline-parse-launch-effect.h>
|
||||
#include <ges/ges-custom-timeline-source.h>
|
||||
|
|
|
@ -220,8 +220,8 @@ GST_START_TEST (test_effect_clip)
|
|||
GES_TRACK_EFFECT (tmp->data));
|
||||
fail_unless (priority > effect_prio);
|
||||
fail_unless (GES_IS_TRACK_EFFECT (tmp->data));
|
||||
fail_unless (ges_track_object_get_track (GES_TRACK_OBJECT (tmp->
|
||||
data))->type == track_type[i]);
|
||||
fail_unless (ges_track_object_get_track (GES_TRACK_OBJECT (tmp->data))->
|
||||
type == track_type[i]);
|
||||
effect_prio = priority;
|
||||
|
||||
g_object_unref (tmp->data);
|
||||
|
|
|
@ -206,10 +206,10 @@ _test_project (GESProject * project, GESTimeline * timeline)
|
|||
assert_equals_string (ges_meta_container_get_string (GES_META_CONTAINER
|
||||
(project), "name"), "Example project");
|
||||
clips =
|
||||
ges_timeline_layer_get_objects (GES_TIMELINE_LAYER (timeline->layers->
|
||||
data));
|
||||
fail_unless (ges_meta_container_get_uint (GES_META_CONTAINER (timeline->
|
||||
layers->data), "a", &a_meta));
|
||||
ges_timeline_layer_get_objects (GES_TIMELINE_LAYER (timeline->
|
||||
layers->data));
|
||||
fail_unless (ges_meta_container_get_uint (GES_META_CONTAINER
|
||||
(timeline->layers->data), "a", &a_meta));
|
||||
assert_equals_int (a_meta, 3);
|
||||
assert_equals_int (g_list_length (clips), 1);
|
||||
media_uri = ges_test_file_uri ("audio_video.ogg");
|
||||
|
|
|
@ -364,7 +364,7 @@ layer_object_added_cb (GESTimelineLayer * layer, GESClip * object, App * app)
|
|||
gtk_list_store_set (app->model, &iter, 2, object, 0, "Test Source", -1);
|
||||
}
|
||||
|
||||
else if (GES_IS_TIMELINE_TRANSITION (object)) {
|
||||
else if (GES_IS_TRANSITION_CLIP (object)) {
|
||||
gtk_list_store_set (app->model, &iter, 2, object, 0, "Transition", -1);
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue