![]() |
![]() |
![]() |
Clutter 0.3 Reference Manual | ![]() |
---|---|---|---|---|
ClutterEffectTemplate; ClutterEffectTemplate* clutter_effect_template_new (ClutterTimeline *timeline, ClutterAlphaFunc alpha_func); void (*ClutterEffectCompleteFunc) (ClutterActor *actor, gpointer user_data); ClutterTimeline* clutter_effect_fade (ClutterEffectTemplate *template_, ClutterActor *actor, guint8 start_opacity, guint8 end_opacity, ClutterEffectCompleteFunc completed_func, gpointer completed_data); ClutterTimeline* clutter_effect_move (ClutterEffectTemplate *template_, ClutterActor *actor, const ClutterKnot *knots, guint n_knots, ClutterEffectCompleteFunc completed_func, gpointer completed_data); ClutterTimeline* clutter_effect_scale (ClutterEffectTemplate *template_, ClutterActor *actor, gdouble scale_begin, gdouble scale_end, ClutterGravity gravity, ClutterEffectCompleteFunc completed_func, gpointer completed_data);
The ClutterEffectTemplate class provides a simple API for applying pre-defined effects to a single actor. It works as a wrapper around the ClutterBehaviour objects
ClutterEffectTemplate* clutter_effect_template_new (ClutterTimeline *timeline, ClutterAlphaFunc alpha_func);
Creates a template for use with clutter effect functions.
timeline : |
A ClutterTimeline for the template (will be cloned) |
alpha_func : |
An alpha func to use for the template. |
Returns : | a ClutterEffectTemplate |
Since 0.4
void (*ClutterEffectCompleteFunc) (ClutterActor *actor, gpointer user_data);
actor : |
|
user_data : |
ClutterTimeline* clutter_effect_fade (ClutterEffectTemplate *template_, ClutterActor *actor, guint8 start_opacity, guint8 end_opacity, ClutterEffectCompleteFunc completed_func, gpointer completed_data);
Simple effect for fading a single ClutterActor.
template_ : |
A ClutterEffectTemplate |
actor : |
A ClutterActor to apply the effect to. |
start_opacity : |
Initial opacity value to apply to actor |
end_opacity : |
Final opacity value to apply to actor |
completed_func : |
A ClutterEffectCompleteFunc to call on effect
completion or NULL
|
completed_data : |
Data to pass to supplied ClutterEffectCompleteFunc
or NULL
|
Returns : | a ClutterTimeline for the effect. Will be unrefed by the effect when completed. |
Since 0.4
ClutterTimeline* clutter_effect_move (ClutterEffectTemplate *template_, ClutterActor *actor, const ClutterKnot *knots, guint n_knots, ClutterEffectCompleteFunc completed_func, gpointer completed_data);
Simple effect for moving a single ClutterActor along a path.
template_ : |
A ClutterEffectTemplate |
actor : |
A ClutterActor to apply the effect to. |
knots : |
An array of ClutterKnots representing path for the actor |
n_knots : |
Number of ClutterKnots in passed array. |
completed_func : |
A ClutterEffectCompleteFunc to call on effect
completion or NULL
|
completed_data : |
Data to pass to supplied ClutterEffectCompleteFunc
or NULL
|
Returns : | a ClutterTimeline for the effect. Will be unreferenced by the effect when completed. |
Since 0.4
ClutterTimeline* clutter_effect_scale (ClutterEffectTemplate *template_, ClutterActor *actor, gdouble scale_begin, gdouble scale_end, ClutterGravity gravity, ClutterEffectCompleteFunc completed_func, gpointer completed_data);
Simple effect for scaling a single ClutterActor.
template_ : |
A ClutterEffectTemplate |
actor : |
A ClutterActor to apply the effect to. |
scale_begin : |
Initial scale factor to apply to actor |
scale_end : |
Final scale factor to apply to actor |
gravity : |
A ClutterGravity for the scale. |
completed_func : |
A ClutterEffectCompleteFunc to call on effect completion or NULL |
completed_data : |
Data to pass to supplied ClutterEffectCompleteFunc or NULL |
Returns : | a ClutterTimeline for the effect. Will be unreferenced by the effect when completed. |
Since 0.4