Files
build
clutter
doc
common
cookbook
examples
Makefile.am
actors-composite-main.c
animations-complex-overlapping.json
animations-complex.c
animations-complex.json
animations-looping-animator.c
animations-looping-implicit.c
animations-looping-state.c
animations-moving-animator.c
animations-moving-implicit.c
animations-moving-state.c
animations-path-circle.c
animations-path-easing.c
animations-path.c
animations-reuse-animation.json
animations-reuse-ui.json
animations-reuse.c
animations-rotating.c
animations-scaling-zoom.c
animations-scaling.c
cb-background-effect.c
cb-background-effect.h
cb-border-effect.c
cb-border-effect.h
cb-button.c
cb-button.h
cb-page-fold-effect.c
cb-page-fold-effect.h
effects-basic.c
effects-built-in.c
effects-custom-deform.c
events-buttons-click.c
events-buttons-lasso.c
events-buttons.c
events-mouse-scroll.c
events-pointer-motion-crossing.c
events-pointer-motion-scribbler.c
events-pointer-motion-stacked.c
events-pointer-motion.c
layouts-bind-constraint-allocation.c
layouts-bind-constraint-overlay.c
layouts-bind-constraint-stage.c
layouts-box-menu.c
layouts-box-property-effects.c
layouts-box.c
layouts-stacking-diff-sized-actors.c
layouts-stacking.c
script-signals.c
script-signals.json
script-states.c
script-states.json
script-ui.c
script-ui.json
smiley.png
text-shadow.c
textures-crossfade-cogl.c
textures-crossfade-slideshow.c
textures-crossfade.c
textures-reflection.c
textures-split-go.c
textures-sub-texture.c
images
videos
Makefile.am
actors.xml
animations.xml
clutter-cookbook.xml.in
effects.xml
events.xml
introduction.xml
layouts.xml
recipe-template.xml
script.xml
text.xml
textures.xml
version.xml.in
reference
AUTHORS.old
CODING_STYLE
HACKING
HACKING.backends
Makefile.am
RELEASING
actor-invariants.txt
size-negotiation.txt
examples
po
tests
.gitignore
COPYING
ChangeLog.pre-git-import
Makefile.am
NEWS
README.in
README.md
autogen.sh
clutter.doap
configure.ac
mutter/doc/cookbook/examples/cb-page-fold-effect.h
Elliot Smith 74de3cfdf3 docs: Add effects chapter, with introduction and first recipe
Add an effects chapter which gives a broad overview of
the abstract classes in the effects API, plus a short
example of how to apply one of the stock Clutter
effects (ClutterColorizeEffect).

The recipe explains how to create a custom ClutterDeformEffect
to produce a page fold (code based on ClutterPageTurnEffect).

The example code includes the effect class plus a small
application to apply it to a texture.
2011-02-21 16:44:09 +00:00

50 lines
2.3 KiB
C

#ifndef __CB_PAGE_FOLD_EFFECT_H__
#define __CB_PAGE_FOLD_EFFECT_H__
#include <clutter/clutter.h>
GType cb_page_fold_effect_get_type (void);
#define CB_TYPE_PAGE_FOLD_EFFECT (cb_page_fold_effect_get_type ())
#define CB_PAGE_FOLD_EFFECT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), \
CB_TYPE_PAGE_FOLD_EFFECT, \
CbPageFoldEffect))
#define CB_IS_PAGE_FOLD_EFFECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), \
CB_TYPE_PAGE_FOLD_EFFECT))
#define CB_PAGE_FOLD_EFFECT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), \
CB_TYPE_PAGE_FOLD_EFFECT, \
CbPageFoldEffectClass))
#define CB_IS_PAGE_FOLD_EFFECT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), \
CB_TYPE_PAGE_FOLD_EFFECT))
#define CB_PAGE_FOLD_EFFECT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), \
CB_TYPE_PAGE_FOLD_EFFECT, \
CbPageFoldEffectClass))
typedef struct _CbPageFoldEffectPrivate CbPageFoldEffectPrivate;
typedef struct _CbPageFoldEffect CbPageFoldEffect;
typedef struct _CbPageFoldEffectClass CbPageFoldEffectClass;
/* object */
struct _CbPageFoldEffect
{
ClutterDeformEffect parent_instance;
CbPageFoldEffectPrivate *priv;
};
/* class */
struct _CbPageFoldEffectClass
{
ClutterDeformEffectClass parent_class;
};
ClutterEffect *cb_page_fold_effect_new (gdouble angle,
gdouble period);
void cb_page_fold_effect_set_angle (CbPageFoldEffect *effect,
gdouble angle);
void cb_page_fold_effect_set_period (CbPageFoldEffect *effect,
gdouble period);
gdouble cb_page_fold_effect_get_period (CbPageFoldEffect *effect);
gdouble cb_page_fold_effect_get_angle (CbPageFoldEffect *effect);
#endif /* __CB_PAGE_FOLD_EFFECT_H__ */