mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-26 19:51:11 +00:00
Rename GESStandardTransitionClip to GESTransitionClip
This commit is contained in:
parent
4300876b0d
commit
6f4315b75d
20 changed files with 168 additions and 191 deletions
|
@ -20,7 +20,7 @@ LOCAL_SRC_FILES := \
|
|||
ges-uri-clip.c \
|
||||
ges-operation-clip.c \
|
||||
ges-base-transition-clip.c \
|
||||
ges-standard-transition-clip.c \
|
||||
ges-transition-clip.c \
|
||||
ges-test-clip.c \
|
||||
ges-title-clip.c \
|
||||
ges-overlay-clip.c \
|
||||
|
|
|
@ -57,7 +57,7 @@ platform as well as Windows. It is released under the GNU Library General Public
|
|||
<xi:include href="xml/ges-title-clip.xml"/>
|
||||
<xi:include href="xml/ges-test-clip.xml"/>
|
||||
<xi:include href="xml/ges-text-overlay-clip.xml"/>
|
||||
<xi:include href="xml/ges-standard-transition-clip.xml"/>
|
||||
<xi:include href="xml/ges-transition-clip.xml"/>
|
||||
<xi:include href="xml/ges-standard-effect-clip.xml"/>
|
||||
</chapter>
|
||||
|
||||
|
|
|
@ -548,21 +548,21 @@ GES_STANDARD_EFFECT_CLIP_GET_CLASS
|
|||
</SECTION>
|
||||
|
||||
<SECTION>
|
||||
<FILE>ges-standard-transition-clip</FILE>
|
||||
<TITLE>GESStandardTransitionClip</TITLE>
|
||||
GESStandardTransitionClip
|
||||
ges_standard_transition_clip_new
|
||||
ges_standard_transition_clip_new_for_nick
|
||||
<FILE>ges-transition-clip</FILE>
|
||||
<TITLE>GESTransitionClip</TITLE>
|
||||
GESTransitionClip
|
||||
ges_transition_clip_new
|
||||
ges_transition_clip_new_for_nick
|
||||
<SUBSECTION Standard>
|
||||
GESStandardTransitionClipClass
|
||||
GESStandardTransitionClipPrivate
|
||||
GES_IS_STANDARD_TRANSITION_CLIP
|
||||
GES_IS_STANDARD_TRANSITION_CLIP_CLASS
|
||||
GES_STANDARD_TRANSITION_CLIP
|
||||
GES_STANDARD_TRANSITION_CLIP_CLASS
|
||||
GES_STANDARD_TRANSITION_CLIP_GET_CLASS
|
||||
GES_TYPE_STANDARD_TRANSITION_CLIP
|
||||
ges_standard_transition_clip_get_type
|
||||
GESTransitionClipClass
|
||||
GESTransitionClipPrivate
|
||||
GES_IS_TRANSITION_CLIP
|
||||
GES_IS_TRANSITION_CLIP_CLASS
|
||||
GES_TRANSITION_CLIP
|
||||
GES_TRANSITION_CLIP_CLASS
|
||||
GES_TRANSITION_CLIP_GET_CLASS
|
||||
GES_TYPE_TRANSITION_CLIP
|
||||
ges_transition_clip_get_type
|
||||
</SECTION>
|
||||
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@ ges_timeline_pipeline_get_type
|
|||
ges_source_clip_get_type
|
||||
ges_test_clip_get_type
|
||||
ges_base_transition_clip_get_type
|
||||
ges_standard_transition_clip_get_type
|
||||
ges_transition_clip_get_type
|
||||
ges_effect_clip_get_type
|
||||
ges_standard_effect_clip_get_type
|
||||
ges_uri_clip_get_type
|
||||
|
|
|
@ -24,7 +24,7 @@ libges_@GST_API_VERSION@_la_SOURCES = \
|
|||
ges-uri-clip.c \
|
||||
ges-operation-clip.c \
|
||||
ges-base-transition-clip.c \
|
||||
ges-standard-transition-clip.c \
|
||||
ges-transition-clip.c \
|
||||
ges-test-clip.c \
|
||||
ges-title-clip.c \
|
||||
ges-overlay-clip.c \
|
||||
|
@ -78,7 +78,7 @@ libges_@GST_API_VERSION@include_HEADERS = \
|
|||
ges-standard-effect-clip.h \
|
||||
ges-operation-clip.h \
|
||||
ges-base-transition-clip.h \
|
||||
ges-standard-transition-clip.h \
|
||||
ges-transition-clip.h \
|
||||
ges-test-clip.h \
|
||||
ges-title-clip.h \
|
||||
ges-overlay-clip.h \
|
||||
|
|
|
@ -52,13 +52,13 @@
|
|||
* The identifier represents different things depending on the @extractable_type and you should check
|
||||
* the documentation of each type to know what the ID of #GESAsset actually represents for that type. By default,
|
||||
* we only have one #GESAsset per type, and the @id is the name of the type, but this behaviour is overriden
|
||||
* to be more usefull. For example, for GESStandardTransitionClips, the ID is the vtype of the transition
|
||||
* to be more usefull. For example, for GESTransitionClips, the ID is the vtype of the transition
|
||||
* you will extract from it (ie crossfade, box-wipe-rc etc..) For #GESTrackParseLaunchEffect the id is the
|
||||
* @bin-description property of the extracted objects (ie the gst-launch style description of the bin that
|
||||
* will be used).
|
||||
*
|
||||
* Each and every #GESAsset are cached into GES, and you can query those with the #ges_list_assets function.
|
||||
* Also the system will automatically register #GESAssets for #GESFormatters and #GESStandardTransitionClips
|
||||
* Also the system will automatically register #GESAssets for #GESFormatters and #GESTransitionClips
|
||||
* and standard effects (actually not implemented yet) and you can simply query those calling:
|
||||
* |[
|
||||
* GList *formatter_assets, *tmp;
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
#include "ges-internal.h"
|
||||
#include "ges-asset.h"
|
||||
#include "ges-meta-container.h"
|
||||
#include "ges-standard-transition-clip.h"
|
||||
#include "ges-transition-clip.h"
|
||||
|
||||
#define C_ENUM(v) ((guint) v)
|
||||
|
||||
|
@ -525,7 +525,7 @@ _init_standard_transition_assets (void)
|
|||
guint i;
|
||||
|
||||
for (i = 1; i < G_N_ELEMENTS (transition_types) - 1; i++) {
|
||||
GESAsset *asset = ges_asset_request (GES_TYPE_STANDARD_TRANSITION_CLIP,
|
||||
GESAsset *asset = ges_asset_request (GES_TYPE_TRANSITION_CLIP,
|
||||
transition_types[i].value_nick, NULL);
|
||||
|
||||
ges_meta_container_register_meta_string (GES_META_CONTAINER (asset),
|
||||
|
|
|
@ -676,8 +676,7 @@ create_transition (GESTimeline * timeline, GESTrackObject * previous,
|
|||
|
||||
if (transition == NULL) {
|
||||
/* TODO make it possible to specify a Transition asset in the API */
|
||||
asset = ges_asset_request (GES_TYPE_STANDARD_TRANSITION_CLIP,
|
||||
"crossfade", NULL);
|
||||
asset = ges_asset_request (GES_TYPE_TRANSITION_CLIP, "crossfade", NULL);
|
||||
transition =
|
||||
ges_timeline_layer_add_asset (layer, asset, start, 0, duration, 1,
|
||||
ges_track_object_get_track_type (next));
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
*/
|
||||
|
||||
/**
|
||||
* SECTION: ges-standard-transition-clip
|
||||
* SECTION: ges-transition-clip
|
||||
* @short_description: Transition from one clip to another in a
|
||||
* #GESTimelineLayer
|
||||
*
|
||||
|
@ -33,7 +33,7 @@
|
|||
* supported.
|
||||
*
|
||||
* #GESSimpleTimelineLayer will automatically manage the priorities of sources
|
||||
* and transitions. If you use #GESStandardTransitionClips in another type of
|
||||
* and transitions. If you use #GESTransitionClips in another type of
|
||||
* #GESTimelineLayer, you will need to manage priorities yourself.
|
||||
*
|
||||
* The ID of the ExtractableType is the nickname of the vtype property value. Note
|
||||
|
@ -44,7 +44,7 @@
|
|||
#include <ges/ges.h>
|
||||
#include "ges-internal.h"
|
||||
|
||||
struct _GESStandardTransitionClipPrivate
|
||||
struct _GESTransitionClipPrivate
|
||||
{
|
||||
GSList *track_video_transitions;
|
||||
|
||||
|
@ -59,22 +59,21 @@ enum
|
|||
static GESTrackObject *ges_tl_transition_create_track_object (GESClip
|
||||
* self, GESTrackType type);
|
||||
static void
|
||||
ges_standard_transition_clip_track_object_added (GESClip * obj,
|
||||
GESTrackObject * tckobj);
|
||||
ges_transition_clip_track_object_added (GESClip * obj, GESTrackObject * tckobj);
|
||||
static void
|
||||
ges_standard_transition_clip_track_object_released (GESClip * obj,
|
||||
ges_transition_clip_track_object_released (GESClip * obj,
|
||||
GESTrackObject * tckobj);
|
||||
|
||||
/* Internal methods */
|
||||
static void
|
||||
ges_standard_transition_clip_update_vtype_internal (GESClip *
|
||||
ges_transition_clip_update_vtype_internal (GESClip *
|
||||
self, GESVideoStandardTransitionType value, gboolean set_asset)
|
||||
{
|
||||
GSList *tmp;
|
||||
guint index;
|
||||
GEnumClass *enum_class;
|
||||
const gchar *asset_id = NULL;
|
||||
GESStandardTransitionClip *trself = GES_STANDARD_TRANSITION_CLIP (self);
|
||||
GESTransitionClip *trself = GES_TRANSITION_CLIP (self);
|
||||
|
||||
enum_class = g_type_class_peek (GES_VIDEO_STANDARD_TRANSITION_TYPE_TYPE);
|
||||
for (index = 0; index < enum_class->n_values; index++) {
|
||||
|
@ -103,7 +102,7 @@ ges_standard_transition_clip_update_vtype_internal (GESClip *
|
|||
if (set_asset) {
|
||||
/* We already checked the value, so we can be sure no error will accured */
|
||||
ges_extractable_set_asset (GES_EXTRACTABLE (self),
|
||||
ges_asset_request (GES_TYPE_STANDARD_TRANSITION_CLIP, asset_id, NULL));
|
||||
ges_asset_request (GES_TYPE_TRANSITION_CLIP, asset_id, NULL));
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -144,7 +143,7 @@ extractable_get_id (GESExtractable * self)
|
|||
{
|
||||
guint index;
|
||||
GEnumClass *enum_class;
|
||||
guint value = GES_STANDARD_TRANSITION_CLIP (self)->vtype;
|
||||
guint value = GES_TRANSITION_CLIP (self)->vtype;
|
||||
|
||||
enum_class = g_type_class_peek (GES_VIDEO_STANDARD_TRANSITION_TYPE_TYPE);
|
||||
for (index = 0; index < enum_class->n_values; index++) {
|
||||
|
@ -160,7 +159,7 @@ extractable_set_asset (GESExtractable * self, GESAsset * asset)
|
|||
{
|
||||
GEnumClass *enum_class;
|
||||
GESVideoStandardTransitionType value;
|
||||
GESStandardTransitionClip *trans = GES_STANDARD_TRANSITION_CLIP (self);
|
||||
GESTransitionClip *trans = GES_TRANSITION_CLIP (self);
|
||||
const gchar *vtype = ges_asset_get_id (asset);
|
||||
|
||||
/* Update the transition type if we actually changed it */
|
||||
|
@ -177,8 +176,7 @@ extractable_set_asset (GESExtractable * self, GESAsset * asset)
|
|||
break;
|
||||
}
|
||||
}
|
||||
ges_standard_transition_clip_update_vtype_internal
|
||||
(GES_CLIP (self), value, FALSE);
|
||||
ges_transition_clip_update_vtype_internal (GES_CLIP (self), value, FALSE);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -192,16 +190,16 @@ ges_extractable_interface_init (GESExtractableInterface * iface)
|
|||
iface->set_asset = extractable_set_asset;
|
||||
}
|
||||
|
||||
G_DEFINE_TYPE_WITH_CODE (GESStandardTransitionClip,
|
||||
ges_standard_transition_clip, GES_TYPE_BASE_TRANSITION_CLIP,
|
||||
G_DEFINE_TYPE_WITH_CODE (GESTransitionClip,
|
||||
ges_transition_clip, GES_TYPE_BASE_TRANSITION_CLIP,
|
||||
G_IMPLEMENT_INTERFACE (GES_TYPE_EXTRACTABLE,
|
||||
ges_extractable_interface_init));
|
||||
|
||||
static void
|
||||
ges_standard_transition_clip_get_property (GObject * object,
|
||||
ges_transition_clip_get_property (GObject * object,
|
||||
guint property_id, GValue * value, GParamSpec * pspec)
|
||||
{
|
||||
GESStandardTransitionClip *self = GES_STANDARD_TRANSITION_CLIP (object);
|
||||
GESTransitionClip *self = GES_TRANSITION_CLIP (object);
|
||||
switch (property_id) {
|
||||
case PROP_VTYPE:
|
||||
g_value_set_enum (value, self->vtype);
|
||||
|
@ -212,14 +210,14 @@ ges_standard_transition_clip_get_property (GObject * object,
|
|||
}
|
||||
|
||||
static void
|
||||
ges_standard_transition_clip_set_property (GObject * object,
|
||||
ges_transition_clip_set_property (GObject * object,
|
||||
guint property_id, const GValue * value, GParamSpec * pspec)
|
||||
{
|
||||
GESClip *self = GES_CLIP (object);
|
||||
|
||||
switch (property_id) {
|
||||
case PROP_VTYPE:
|
||||
ges_standard_transition_clip_update_vtype_internal (self,
|
||||
ges_transition_clip_update_vtype_internal (self,
|
||||
g_value_get_enum (value), TRUE);
|
||||
break;
|
||||
default:
|
||||
|
@ -228,18 +226,18 @@ ges_standard_transition_clip_set_property (GObject * object,
|
|||
}
|
||||
|
||||
static void
|
||||
ges_standard_transition_clip_class_init (GESStandardTransitionClipClass * klass)
|
||||
ges_transition_clip_class_init (GESTransitionClipClass * klass)
|
||||
{
|
||||
GObjectClass *object_class = G_OBJECT_CLASS (klass);
|
||||
GESClipClass *timobj_class = GES_CLIP_CLASS (klass);
|
||||
|
||||
g_type_class_add_private (klass, sizeof (GESStandardTransitionClipPrivate));
|
||||
g_type_class_add_private (klass, sizeof (GESTransitionClipPrivate));
|
||||
|
||||
object_class->get_property = ges_standard_transition_clip_get_property;
|
||||
object_class->set_property = ges_standard_transition_clip_set_property;
|
||||
object_class->get_property = ges_transition_clip_get_property;
|
||||
object_class->set_property = ges_transition_clip_set_property;
|
||||
|
||||
/**
|
||||
* GESStandardTransitionClip:vtype:
|
||||
* GESTransitionClip:vtype:
|
||||
*
|
||||
* a #GESVideoStandardTransitionType representing the wipe to use
|
||||
*/
|
||||
|
@ -253,29 +251,27 @@ ges_standard_transition_clip_class_init (GESStandardTransitionClipClass * klass)
|
|||
|
||||
timobj_class->create_track_object = ges_tl_transition_create_track_object;
|
||||
timobj_class->need_fill_track = FALSE;
|
||||
timobj_class->track_object_added =
|
||||
ges_standard_transition_clip_track_object_added;
|
||||
timobj_class->track_object_added = ges_transition_clip_track_object_added;
|
||||
timobj_class->track_object_released =
|
||||
ges_standard_transition_clip_track_object_released;
|
||||
ges_transition_clip_track_object_released;
|
||||
}
|
||||
|
||||
static void
|
||||
ges_standard_transition_clip_init (GESStandardTransitionClip * self)
|
||||
ges_transition_clip_init (GESTransitionClip * self)
|
||||
{
|
||||
|
||||
self->priv = G_TYPE_INSTANCE_GET_PRIVATE (self,
|
||||
GES_TYPE_STANDARD_TRANSITION_CLIP, GESStandardTransitionClipPrivate);
|
||||
GES_TYPE_TRANSITION_CLIP, GESTransitionClipPrivate);
|
||||
|
||||
self->vtype = GES_VIDEO_STANDARD_TRANSITION_TYPE_NONE;
|
||||
self->priv->vtype_name = NULL;
|
||||
}
|
||||
|
||||
static void
|
||||
ges_standard_transition_clip_track_object_released (GESClip * obj,
|
||||
ges_transition_clip_track_object_released (GESClip * obj,
|
||||
GESTrackObject * tckobj)
|
||||
{
|
||||
GESStandardTransitionClipPrivate *priv =
|
||||
GES_STANDARD_TRANSITION_CLIP (obj)->priv;
|
||||
GESTransitionClipPrivate *priv = GES_TRANSITION_CLIP (obj)->priv;
|
||||
|
||||
/* If this is called, we should be sure the tckobj exists */
|
||||
if (GES_IS_TRACK_VIDEO_TRANSITION (tckobj)) {
|
||||
|
@ -287,11 +283,9 @@ ges_standard_transition_clip_track_object_released (GESClip * obj,
|
|||
}
|
||||
|
||||
static void
|
||||
ges_standard_transition_clip_track_object_added (GESClip * obj,
|
||||
GESTrackObject * tckobj)
|
||||
ges_transition_clip_track_object_added (GESClip * obj, GESTrackObject * tckobj)
|
||||
{
|
||||
GESStandardTransitionClipPrivate *priv =
|
||||
GES_STANDARD_TRANSITION_CLIP (obj)->priv;
|
||||
GESTransitionClipPrivate *priv = GES_TRANSITION_CLIP (obj)->priv;
|
||||
|
||||
if (GES_IS_TRACK_VIDEO_TRANSITION (tckobj)) {
|
||||
GST_DEBUG ("GESTrackVideoTransition %p added to %p", tckobj, obj);
|
||||
|
@ -303,7 +297,7 @@ ges_standard_transition_clip_track_object_added (GESClip * obj,
|
|||
static GESTrackObject *
|
||||
ges_tl_transition_create_track_object (GESClip * obj, GESTrackType type)
|
||||
{
|
||||
GESStandardTransitionClip *transition = (GESStandardTransitionClip *) obj;
|
||||
GESTransitionClip *transition = (GESTransitionClip *) obj;
|
||||
GESTrackObject *res = NULL;
|
||||
GESTrackType supportedformats;
|
||||
|
||||
|
@ -340,37 +334,36 @@ ges_tl_transition_create_track_object (GESClip * obj, GESTrackType type)
|
|||
}
|
||||
|
||||
/**
|
||||
* ges_standard_transition_clip_new:
|
||||
* ges_transition_clip_new:
|
||||
* @vtype: the type of transition to create
|
||||
*
|
||||
* Creates a new #GESStandardTransitionClip.
|
||||
* Creates a new #GESTransitionClip.
|
||||
*
|
||||
* Returns: a newly created #GESStandardTransitionClip, or %NULL if something
|
||||
* Returns: a newly created #GESTransitionClip, or %NULL if something
|
||||
* went wrong.
|
||||
*/
|
||||
GESStandardTransitionClip *
|
||||
ges_standard_transition_clip_new (GESVideoStandardTransitionType vtype)
|
||||
GESTransitionClip *
|
||||
ges_transition_clip_new (GESVideoStandardTransitionType vtype)
|
||||
{
|
||||
return g_object_new (GES_TYPE_STANDARD_TRANSITION_CLIP, "vtype",
|
||||
(gint) vtype, NULL);
|
||||
return g_object_new (GES_TYPE_TRANSITION_CLIP, "vtype", (gint) vtype, NULL);
|
||||
}
|
||||
|
||||
/**
|
||||
* ges_standard_transition_clip_new_for_nick:
|
||||
* ges_transition_clip_new_for_nick:
|
||||
* @nick: a string representing the type of transition to create
|
||||
*
|
||||
* Creates a new #GESStandardTransitionClip for the provided @nick.
|
||||
* Creates a new #GESTransitionClip for the provided @nick.
|
||||
*
|
||||
* Returns: The newly created #GESStandardTransitionClip, or %NULL if something
|
||||
* Returns: The newly created #GESTransitionClip, or %NULL if something
|
||||
* went wrong
|
||||
*/
|
||||
|
||||
GESStandardTransitionClip *
|
||||
ges_standard_transition_clip_new_for_nick (gchar * nick)
|
||||
GESTransitionClip *
|
||||
ges_transition_clip_new_for_nick (gchar * nick)
|
||||
{
|
||||
GEnumValue *value;
|
||||
GEnumClass *klass;
|
||||
GESStandardTransitionClip *ret = NULL;
|
||||
GESTransitionClip *ret = NULL;
|
||||
|
||||
klass =
|
||||
G_ENUM_CLASS (g_type_class_ref (GES_VIDEO_STANDARD_TRANSITION_TYPE_TYPE));
|
||||
|
@ -379,7 +372,7 @@ ges_standard_transition_clip_new_for_nick (gchar * nick)
|
|||
|
||||
value = g_enum_get_value_by_nick (klass, nick);
|
||||
if (value) {
|
||||
ret = g_object_new (GES_TYPE_STANDARD_TRANSITION_CLIP, "vtype",
|
||||
ret = g_object_new (GES_TYPE_TRANSITION_CLIP, "vtype",
|
||||
(gint) value->value, NULL);
|
||||
}
|
||||
|
|
@ -18,8 +18,8 @@
|
|||
* Boston, MA 02110-1301, USA.
|
||||
*/
|
||||
|
||||
#ifndef _GES_STANDARD_TRANSITION_CLIP
|
||||
#define _GES_STANDARD_TRANSITION_CLIP
|
||||
#ifndef _GES_TRANSITION_CLIP
|
||||
#define _GES_TRANSITION_CLIP
|
||||
|
||||
#include <glib-object.h>
|
||||
#include <ges/ges-types.h>
|
||||
|
@ -27,31 +27,31 @@
|
|||
|
||||
G_BEGIN_DECLS
|
||||
|
||||
#define GES_TYPE_STANDARD_TRANSITION_CLIP ges_standard_transition_clip_get_type()
|
||||
#define GES_TYPE_TRANSITION_CLIP ges_transition_clip_get_type()
|
||||
|
||||
#define GES_STANDARD_TRANSITION_CLIP(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GES_TYPE_STANDARD_TRANSITION_CLIP, GESStandardTransitionClip))
|
||||
#define GES_TRANSITION_CLIP(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_CAST ((obj), GES_TYPE_TRANSITION_CLIP, GESTransitionClip))
|
||||
|
||||
#define GES_STANDARD_TRANSITION_CLIP_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_CAST ((klass), GES_TYPE_STANDARD_TRANSITION_CLIP, GESStandardTransitionClipClass))
|
||||
#define GES_TRANSITION_CLIP_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_CAST ((klass), GES_TYPE_TRANSITION_CLIP, GESTransitionClipClass))
|
||||
|
||||
#define GES_IS_STANDARD_TRANSITION_CLIP(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GES_TYPE_STANDARD_TRANSITION_CLIP))
|
||||
#define GES_IS_TRANSITION_CLIP(obj) \
|
||||
(G_TYPE_CHECK_INSTANCE_TYPE ((obj), GES_TYPE_TRANSITION_CLIP))
|
||||
|
||||
#define GES_IS_STANDARD_TRANSITION_CLIP_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GES_TYPE_STANDARD_TRANSITION_CLIP))
|
||||
#define GES_IS_TRANSITION_CLIP_CLASS(klass) \
|
||||
(G_TYPE_CHECK_CLASS_TYPE ((klass), GES_TYPE_TRANSITION_CLIP))
|
||||
|
||||
#define GES_STANDARD_TRANSITION_CLIP_GET_CLASS(obj) \
|
||||
(G_TYPE_INSTANCE_GET_CLASS ((obj), GES_TYPE_STANDARD_TRANSITION_CLIP, GESStandardTransitionClipClass))
|
||||
#define GES_TRANSITION_CLIP_GET_CLASS(obj) \
|
||||
(G_TYPE_INSTANCE_GET_CLASS ((obj), GES_TYPE_TRANSITION_CLIP, GESTransitionClipClass))
|
||||
|
||||
typedef struct _GESStandardTransitionClipPrivate GESStandardTransitionClipPrivate;
|
||||
typedef struct _GESTransitionClipPrivate GESTransitionClipPrivate;
|
||||
|
||||
/**
|
||||
* GESStandardTransitionClip:
|
||||
* GESTransitionClip:
|
||||
* @vtype: a #GESVideoStandardTransitionType indicating the type of video transition
|
||||
* to apply.
|
||||
*/
|
||||
struct _GESStandardTransitionClip {
|
||||
struct _GESTransitionClip {
|
||||
/*< private >*/
|
||||
GESBaseTransitionClip parent;
|
||||
|
||||
|
@ -59,18 +59,18 @@ struct _GESStandardTransitionClip {
|
|||
GESVideoStandardTransitionType vtype;
|
||||
|
||||
/*< private >*/
|
||||
GESStandardTransitionClipPrivate *priv;
|
||||
GESTransitionClipPrivate *priv;
|
||||
|
||||
/* Padding for API extension */
|
||||
gpointer _ges_reserved[GES_PADDING];
|
||||
};
|
||||
|
||||
/**
|
||||
* GESStandardTransitionClipClass:
|
||||
* GESTransitionClipClass:
|
||||
*
|
||||
*/
|
||||
|
||||
struct _GESStandardTransitionClipClass {
|
||||
struct _GESTransitionClipClass {
|
||||
/*< private >*/
|
||||
GESBaseTransitionClipClass parent_class;
|
||||
|
||||
|
@ -78,11 +78,11 @@ struct _GESStandardTransitionClipClass {
|
|||
gpointer _ges_reserved[GES_PADDING];
|
||||
};
|
||||
|
||||
GType ges_standard_transition_clip_get_type (void);
|
||||
GType ges_transition_clip_get_type (void);
|
||||
|
||||
GESStandardTransitionClip *ges_standard_transition_clip_new (GESVideoStandardTransitionType vtype);
|
||||
GESStandardTransitionClip *ges_standard_transition_clip_new_for_nick (char *nick);
|
||||
GESTransitionClip *ges_transition_clip_new (GESVideoStandardTransitionType vtype);
|
||||
GESTransitionClip *ges_transition_clip_new_for_nick (char *nick);
|
||||
|
||||
G_END_DECLS
|
||||
|
||||
#endif /* _GES_STANDARD_TRANSITION_CLIP */
|
||||
#endif /* _GES_TRANSITION_CLIP */
|
|
@ -65,8 +65,8 @@ typedef struct _GESUriClipClass GESUriClipClass;
|
|||
typedef struct _GESBaseTransitionClip GESBaseTransitionClip;
|
||||
typedef struct _GESBaseTransitionClipClass GESBaseTransitionClipClass;
|
||||
|
||||
typedef struct _GESStandardTransitionClip GESStandardTransitionClip;
|
||||
typedef struct _GESStandardTransitionClipClass GESStandardTransitionClipClass;
|
||||
typedef struct _GESTransitionClip GESTransitionClip;
|
||||
typedef struct _GESTransitionClipClass GESTransitionClipClass;
|
||||
|
||||
typedef struct _GESTestClip GESTestClip;
|
||||
typedef struct _GESTestClipClass GESTestClipClass;
|
||||
|
|
|
@ -74,7 +74,7 @@ ges_init (void)
|
|||
GES_TYPE_TEST_CLIP;
|
||||
GES_TYPE_URI_CLIP;
|
||||
GES_TYPE_TITLE_CLIP;
|
||||
GES_TYPE_STANDARD_TRANSITION_CLIP;
|
||||
GES_TYPE_TRANSITION_CLIP;
|
||||
GES_TYPE_OVERLAY_CLIP;
|
||||
|
||||
/* register formatter types with the system */
|
||||
|
|
|
@ -40,7 +40,7 @@
|
|||
#include <ges/ges-overlay-clip.h>
|
||||
#include <ges/ges-text-overlay-clip.h>
|
||||
#include <ges/ges-base-transition-clip.h>
|
||||
#include <ges/ges-standard-transition-clip.h>
|
||||
#include <ges/ges-transition-clip.h>
|
||||
#include <ges/ges-standard-effect-clip.h>
|
||||
#include <ges/ges-custom-source-clip.h>
|
||||
#include <ges/ges-effect-clip.h>
|
||||
|
|
|
@ -62,8 +62,7 @@ GST_START_TEST (test_change_asset)
|
|||
gst_init (NULL, NULL);
|
||||
ges_init ();
|
||||
|
||||
a = ges_asset_request (GES_TYPE_STANDARD_TRANSITION_CLIP,
|
||||
"box-wipe-lc", NULL);
|
||||
a = ges_asset_request (GES_TYPE_TRANSITION_CLIP, "box-wipe-lc", NULL);
|
||||
|
||||
fail_unless (GES_IS_ASSET (a));
|
||||
fail_unless_equals_string (ges_asset_get_id (a), "box-wipe-lc");
|
||||
|
@ -88,11 +87,9 @@ GST_START_TEST (test_change_asset)
|
|||
fail_unless_equals_string (ges_asset_get_id (a), "bar-wipe-tb");
|
||||
|
||||
/* Now try to set the a and see if the vtype is properly updated */
|
||||
a = ges_asset_request (GES_TYPE_STANDARD_TRANSITION_CLIP,
|
||||
"box-wipe-lc", NULL);
|
||||
a = ges_asset_request (GES_TYPE_TRANSITION_CLIP, "box-wipe-lc", NULL);
|
||||
ges_extractable_set_asset (extractable, a);
|
||||
fail_unless_equals_int (GES_STANDARD_TRANSITION_CLIP (extractable)->vtype,
|
||||
26);
|
||||
fail_unless_equals_int (GES_TRANSITION_CLIP (extractable)->vtype, 26);
|
||||
|
||||
gst_object_unref (extractable);
|
||||
}
|
||||
|
@ -108,7 +105,7 @@ GST_START_TEST (test_list_asset)
|
|||
fail_unless (ges_init ());
|
||||
fail_if (ges_list_assets (GES_TYPE_OVERLAY_CLIP));
|
||||
|
||||
assets = ges_list_assets (GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assets = ges_list_assets (GES_TYPE_TRANSITION_CLIP);
|
||||
/* note: we do not have a a for value=0 "Transition not set" */
|
||||
assert_equals_int (g_list_length (assets), enum_class->n_values - 1);
|
||||
g_list_free (assets);
|
||||
|
|
|
@ -332,12 +332,12 @@ GST_START_TEST (test_single_layer_automatic_transition)
|
|||
assert_is_type (objects->data, GES_TYPE_TEST_CLIP);
|
||||
|
||||
transition = objects->next->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
transition = objects->next->next->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
g_list_free_full (objects, gst_object_unref);
|
||||
|
@ -362,12 +362,12 @@ GST_START_TEST (test_single_layer_automatic_transition)
|
|||
assert_is_type (objects->data, GES_TYPE_TEST_CLIP);
|
||||
|
||||
transition = objects->next->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 750);
|
||||
|
||||
transition = objects->next->next->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_int (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 750);
|
||||
g_list_free_full (objects, gst_object_unref);
|
||||
|
@ -522,14 +522,14 @@ GST_START_TEST (test_single_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 600);
|
||||
assert_equals_uint64 (_DURATION (transition), 1250 - 600);
|
||||
ASSERT_OBJECT_REFCOUNT (transition, "The layer and ourself own a ref", 2);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 600);
|
||||
assert_equals_uint64 (_DURATION (transition), 1250 - 600);
|
||||
ASSERT_OBJECT_REFCOUNT (transition, "The layer and ourself own a ref", 2);
|
||||
|
@ -539,14 +539,14 @@ GST_START_TEST (test_single_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1250);
|
||||
assert_equals_uint64 (_DURATION (transition), 1400 - 1250);
|
||||
ASSERT_OBJECT_REFCOUNT (transition, "The layer and ourself own a ref", 2);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1250);
|
||||
assert_equals_uint64 (_DURATION (transition), 1400 - 1250);
|
||||
ASSERT_OBJECT_REFCOUNT (transition, "The layer and ourself own a ref", 2);
|
||||
|
@ -569,7 +569,7 @@ GST_START_TEST (test_single_layer_automatic_transition)
|
|||
assert_equals_uint64 (_DURATION (src2), 1000);
|
||||
|
||||
/* We check that the transition as actually been freed */
|
||||
fail_if (GES_IS_STANDARD_TRANSITION_CLIP (transition));
|
||||
fail_if (GES_IS_TRANSITION_CLIP (transition));
|
||||
|
||||
objects = ges_timeline_layer_get_objects (layer);
|
||||
assert_equals_int (g_list_length (objects), 3);
|
||||
|
@ -600,13 +600,13 @@ GST_START_TEST (test_single_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1100);
|
||||
assert_equals_uint64 (_DURATION (transition), 1250 - 1100);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1100);
|
||||
assert_equals_uint64 (_DURATION (transition), 1250 - 1100);
|
||||
|
||||
|
@ -641,25 +641,25 @@ GST_START_TEST (test_single_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 1100 - 1000);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 1100 - 1000);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 1250 - 1000);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 1250 - 1000);
|
||||
|
||||
|
@ -737,13 +737,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
g_list_free_full (objects, gst_object_unref);
|
||||
|
@ -781,13 +781,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
g_list_free_full (objects, gst_object_unref);
|
||||
|
@ -829,13 +829,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
g_list_free_full (objects, gst_object_unref);
|
||||
|
@ -848,13 +848,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
g_list_free_full (objects, gst_object_unref);
|
||||
|
@ -887,13 +887,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
g_list_free_full (objects, gst_object_unref);
|
||||
|
@ -935,13 +935,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
|
@ -950,13 +950,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 1500 - 1000);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 1500 - 1000);
|
||||
|
||||
|
@ -1001,13 +1001,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
|
@ -1052,13 +1052,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
|
@ -1067,13 +1067,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
|
@ -1117,13 +1117,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 1700 - 1000);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 1700 - 1000);
|
||||
|
||||
|
@ -1132,13 +1132,13 @@ GST_START_TEST (test_multi_layer_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1700);
|
||||
assert_equals_uint64 (_DURATION (transition), 2000 - 1700);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1700);
|
||||
assert_equals_uint64 (_DURATION (transition), 2000 - 1700);
|
||||
|
||||
|
@ -1172,7 +1172,7 @@ GST_START_TEST (test_layer_activate_automatic_transition)
|
|||
|
||||
asset = ges_asset_request (GES_TYPE_TEST_CLIP, NULL, NULL);
|
||||
transition_asset =
|
||||
ges_asset_request (GES_TYPE_STANDARD_TRANSITION_CLIP, "crossfade", NULL);
|
||||
ges_asset_request (GES_TYPE_TRANSITION_CLIP, "crossfade", NULL);
|
||||
fail_unless (GES_IS_ASSET (asset));
|
||||
|
||||
GST_DEBUG ("Create timeline");
|
||||
|
@ -1229,7 +1229,7 @@ GST_START_TEST (test_layer_activate_automatic_transition)
|
|||
transition =
|
||||
GES_CLIP (ges_timeline_layer_add_asset (layer,
|
||||
transition_asset, 1000, 0, 500, 1, GES_TRACK_TYPE_VIDEO));
|
||||
fail_unless (GES_IS_STANDARD_TRANSITION_CLIP (transition));
|
||||
fail_unless (GES_IS_TRANSITION_CLIP (transition));
|
||||
objects = ges_clip_get_track_objects (transition);
|
||||
assert_equals_int (g_list_length (objects), 1);
|
||||
g_list_free_full (objects, gst_object_unref);
|
||||
|
@ -1247,7 +1247,7 @@ GST_START_TEST (test_layer_activate_automatic_transition)
|
|||
current = current->next;
|
||||
assert_is_type (current->data, GES_TYPE_TEST_CLIP);
|
||||
current = current->next;
|
||||
assert_is_type (current->data, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (current->data, GES_TYPE_TRANSITION_CLIP);
|
||||
current = current->next;
|
||||
assert_is_type (current->data, GES_TYPE_TEST_CLIP);
|
||||
current = current->next;
|
||||
|
@ -1279,13 +1279,13 @@ GST_START_TEST (test_layer_activate_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
|
@ -1294,13 +1294,13 @@ GST_START_TEST (test_layer_activate_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1000);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
|
@ -1339,13 +1339,13 @@ GST_START_TEST (test_layer_activate_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 500);
|
||||
assert_equals_uint64 (_DURATION (transition), 500);
|
||||
|
||||
|
@ -1354,13 +1354,13 @@ GST_START_TEST (test_layer_activate_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1200);
|
||||
assert_equals_uint64 (_DURATION (transition), 300);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 1200);
|
||||
assert_equals_uint64 (_DURATION (transition), 300);
|
||||
|
||||
|
@ -1369,13 +1369,13 @@ GST_START_TEST (test_layer_activate_automatic_transition)
|
|||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 2000);
|
||||
assert_equals_uint64 (_DURATION (transition), 200);
|
||||
|
||||
current = current->next;
|
||||
transition = current->data;
|
||||
assert_is_type (transition, GES_TYPE_STANDARD_TRANSITION_CLIP);
|
||||
assert_is_type (transition, GES_TYPE_TRANSITION_CLIP);
|
||||
assert_equals_uint64 (_START (transition), 2000);
|
||||
assert_equals_uint64 (_DURATION (transition), 200);
|
||||
|
||||
|
|
|
@ -236,7 +236,7 @@ GST_START_TEST (test_gsl_with_transitions)
|
|||
GESTimelineLayer *layer;
|
||||
GESTrack *track;
|
||||
GESCustomSourceClip *source1, *source2, *source3, *source4;
|
||||
GESStandardTransitionClip *tr1, *tr2, *tr3, *tr4, *tr5;
|
||||
GESTransitionClip *tr1, *tr2, *tr3, *tr4, *tr5;
|
||||
GESSimpleTimelineLayer *gstl;
|
||||
gboolean valid;
|
||||
gint count = 0;
|
||||
|
@ -292,33 +292,23 @@ GST_START_TEST (test_gsl_with_transitions)
|
|||
#define HALF_SECOND ((guint64) (0.5 * GST_SECOND))
|
||||
#define SECOND(a) ((guint64) (a * GST_SECOND))
|
||||
|
||||
tr1 =
|
||||
ges_standard_transition_clip_new
|
||||
(GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
tr1 = ges_transition_clip_new (GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
g_object_set (tr1, "duration", HALF_SECOND, "start", (guint64) 42, NULL);
|
||||
fail_unless_equals_uint64 (_DURATION (tr1), HALF_SECOND);
|
||||
|
||||
tr2 =
|
||||
ges_standard_transition_clip_new
|
||||
(GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
tr2 = ges_transition_clip_new (GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
g_object_set (tr2, "duration", HALF_SECOND, "start", (guint64) 42, NULL);
|
||||
fail_unless_equals_uint64 (_DURATION (tr2), HALF_SECOND);
|
||||
|
||||
tr3 =
|
||||
ges_standard_transition_clip_new
|
||||
(GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
tr3 = ges_transition_clip_new (GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
g_object_set (tr3, "duration", HALF_SECOND, "start", (guint64) 42, NULL);
|
||||
fail_unless_equals_uint64 (_DURATION (tr3), HALF_SECOND);
|
||||
|
||||
tr4 =
|
||||
ges_standard_transition_clip_new
|
||||
(GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
tr4 = ges_transition_clip_new (GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
g_object_set (tr4, "duration", HALF_SECOND, "start", (guint64) 42, NULL);
|
||||
fail_unless_equals_uint64 (_DURATION (tr4), HALF_SECOND);
|
||||
|
||||
tr5 =
|
||||
ges_standard_transition_clip_new
|
||||
(GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
tr5 = ges_transition_clip_new (GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
g_object_set (tr5, "duration", HALF_SECOND, "start", (guint64) 42, NULL);
|
||||
fail_unless_equals_uint64 (_DURATION (tr5), HALF_SECOND);
|
||||
|
||||
|
|
|
@ -27,7 +27,7 @@
|
|||
|
||||
GST_START_TEST (test_transition_basic)
|
||||
{
|
||||
GESStandardTransitionClip *tr1, *tr2;
|
||||
GESTransitionClip *tr1, *tr2;
|
||||
GESTrackObject *trackobject;
|
||||
GESTrack *track;
|
||||
|
||||
|
@ -36,13 +36,11 @@ GST_START_TEST (test_transition_basic)
|
|||
track = ges_track_video_raw_new ();
|
||||
fail_unless (track != 0);
|
||||
|
||||
tr1 =
|
||||
ges_standard_transition_clip_new
|
||||
(GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
tr1 = ges_transition_clip_new (GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
fail_unless (tr1 != 0);
|
||||
fail_unless (tr1->vtype == GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
|
||||
tr2 = ges_standard_transition_clip_new_for_nick ((gchar *) "bar-wipe-lr");
|
||||
tr2 = ges_transition_clip_new_for_nick ((gchar *) "bar-wipe-lr");
|
||||
fail_unless (tr2 != 0);
|
||||
fail_unless (tr2->vtype == 1);
|
||||
|
||||
|
@ -73,7 +71,7 @@ GST_START_TEST (test_transition_properties)
|
|||
ges_init ();
|
||||
|
||||
object =
|
||||
GES_CLIP (ges_standard_transition_clip_new
|
||||
GES_CLIP (ges_transition_clip_new
|
||||
(GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE));
|
||||
|
||||
track = ges_track_video_raw_new ();
|
||||
|
@ -119,7 +117,7 @@ GST_START_TEST (test_transition_properties)
|
|||
GST_DEBUG ("Setting to crossfade");
|
||||
g_object_set (object, "vtype", GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE,
|
||||
NULL);
|
||||
assert_equals_int (GES_STANDARD_TRANSITION_CLIP (object)->vtype,
|
||||
assert_equals_int (GES_TRANSITION_CLIP (object)->vtype,
|
||||
GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE);
|
||||
assert_equals_int (ges_track_video_transition_get_transition_type
|
||||
(GES_TRACK_VIDEO_TRANSITION (trackobject)),
|
||||
|
@ -130,7 +128,7 @@ GST_START_TEST (test_transition_properties)
|
|||
GST_DEBUG ("Setting back to 1 (should fail)");
|
||||
g_object_set (object, "vtype", 1, NULL);
|
||||
|
||||
assert_equals_int (GES_STANDARD_TRANSITION_CLIP (object)->vtype, 1);
|
||||
assert_equals_int (GES_TRANSITION_CLIP (object)->vtype, 1);
|
||||
assert_equals_int (ges_track_video_transition_get_transition_type
|
||||
(GES_TRACK_VIDEO_TRANSITION (trackobject)), 1);
|
||||
|
||||
|
@ -150,7 +148,7 @@ GST_START_TEST (test_transition_properties)
|
|||
GST_DEBUG ("Setting to vtype:1");
|
||||
assert_equals_int (ges_track_video_transition_get_transition_type
|
||||
(GES_TRACK_VIDEO_TRANSITION (trackobject)), 1);
|
||||
assert_equals_int (GES_STANDARD_TRANSITION_CLIP (object)->vtype, 1);
|
||||
assert_equals_int (GES_TRANSITION_CLIP (object)->vtype, 1);
|
||||
|
||||
ges_clip_release_track_object (object, trackobject);
|
||||
g_object_unref (object);
|
||||
|
|
|
@ -1216,7 +1216,7 @@ app_add_transition (App * app)
|
|||
|
||||
GST_DEBUG ("adding transition");
|
||||
|
||||
obj = GES_CLIP (ges_standard_transition_clip_new
|
||||
obj = GES_CLIP (ges_transition_clip_new
|
||||
(GES_VIDEO_STANDARD_TRANSITION_TYPE_CROSSFADE));
|
||||
g_object_set (G_OBJECT (obj), "duration", GST_SECOND, NULL);
|
||||
|
||||
|
|
|
@ -99,7 +99,7 @@ make_timeline (gchar * nick, gdouble tdur, gchar * patha, gfloat adur,
|
|||
GESClip *srca, *srcb;
|
||||
GESTimelinePipeline *pipeline;
|
||||
guint64 aduration, bduration, tduration, tstart, ainpoint, binpoint;
|
||||
GESStandardTransitionClip *tr = NULL;
|
||||
GESTransitionClip *tr = NULL;
|
||||
|
||||
pipeline = ges_timeline_pipeline_new ();
|
||||
|
||||
|
@ -137,7 +137,7 @@ make_timeline (gchar * nick, gdouble tdur, gchar * patha, gfloat adur,
|
|||
g_print ("creating transition at %" GST_TIME_FORMAT " of %f duration (%"
|
||||
GST_TIME_FORMAT ")\n", GST_TIME_ARGS (tstart), tdur,
|
||||
GST_TIME_ARGS (tduration));
|
||||
if (!(tr = ges_standard_transition_clip_new_for_nick (nick)))
|
||||
if (!(tr = ges_transition_clip_new_for_nick (nick)))
|
||||
g_error ("invalid transition type %s\n", nick);
|
||||
|
||||
g_object_set (tr,
|
||||
|
|
|
@ -178,7 +178,7 @@ create_timeline (int nbargs, gchar ** argv, gchar * audio, gchar * video)
|
|||
goto build_failure;
|
||||
}
|
||||
|
||||
obj = GES_CLIP (ges_standard_transition_clip_new_for_nick (arg0));
|
||||
obj = GES_CLIP (ges_transition_clip_new_for_nick (arg0));
|
||||
|
||||
if (!obj) {
|
||||
g_error ("invalid transition type\n");
|
||||
|
|
Loading…
Reference in a new issue