1
0
Fork 0
mutter-performance-source/clutter/clutter.h

116 lines
3.4 KiB
C
Raw Normal View History

/*
* Clutter.
*
* An OpenGL based 'interactive canvas' library.
*
* Authored By Matthew Allum <mallum@openedhand.com>
*
* Copyright (C) 2006 OpenedHand
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library. If not, see <http://www.gnu.org/licenses/>.
*
*
*/
#ifndef __CLUTTER_H__
#define __CLUTTER_H__
#define __CLUTTER_H_INSIDE__
2006-05-29 08:59:36 +00:00
#include "clutter-deprecated.h"
#include "clutter-action.h"
#include "clutter-actor.h"
#include "clutter-actor-meta.h"
#include "clutter-align-constraint.h"
#include "clutter-alpha.h"
#include "clutter-animatable.h"
2008-11-17 Emmanuele Bassi <ebassi@linux.intel.com> Bug 1014 - Clutter Animation API Improvements * clutter/Makefile.am: * clutter/clutter.h: Update the build * clutter/clutter-types.h: Add AnimationMode, an enumeration for easing functions. * clutter/clutter-alpha.[ch]: Add the :mode property to control the function bound to an Alpha instance using an enumeration value. Also add six new alpha functions: - ease-in, ease-out, ease-in-out - sine-in, sine-out, sine-in-out * clutter/clutter-deprecated.h: Deprecate the #defines for the alpha functions. They will be replaced by entries in the ClutterAnimationMode. * clutter/clutter-interval.[ch]: Add ClutterInterval, an object for defining, validating and computing an interval between two values. * clutter/clutter-animation.[ch]: Add ClutterAnimation, an object responsible for animation the properties of a single actor along an interval of values. ClutterAnimation memory management is automatic. A simple wrapper method for ClutterActor is provided: clutter_actor_animate() which will create, or update, an animation for the passed actor. * clutter/clutter-debug.h: * clutter/clutter-main.c: Add a new 'animation' debug note. * clutter/clutter-script.c: Clean up the alpha functions whitelist, and add the new functions. * doc/reference/clutter/Makefile.am: * doc/reference/clutter/clutter-sections.txt: Update the API reference. * doc/reference/clutter/clutter-animation.xml: Renamed to doc/reference/clutter/clutter-animation-tutorial.xml to avoid clashes with the ClutterAnimation section. * doc/reference/clutter/clutter-docs.sgml: Renamed to doc/reference/clutter/clutter-docs.xml, as it was an XML file and not a SGML file. * tests/Makefile.am: * tests/interactive/Makefile.am: * tests/interactive/test-animation.c: * tests/interactive/test-easing.c: Add two tests for the new simple animation API and the easing functions. * tests/interactive/test-actors.c: * tests/interactive/test-behave.c: * tests/interactive/test-depth.c: * tests/interactive/test-effects.c: * tests/interactive/test-layout.c: * tests/interactive/test-multistage.c: * tests/interactive/test-paint-wrapper.c: * tests/interactive/test-rotate.c: * tests/interactive/test-scale.c: * tests/interactive/test-texture-quality.c: * tests/interactive/test-threads.c: * tests/interactive/test-viewport.c: Update interactive tests to the deprecations and new alpha API.
2008-11-18 09:50:03 +00:00
#include "clutter-animation.h"
#include "clutter-animator.h"
#include "clutter-backend.h"
#include "clutter-behaviour-depth.h"
#include "clutter-behaviour-ellipse.h"
#include "clutter-behaviour.h"
2006-11-15 Emmanuele Bassi <ebassi@openedhand.com> * clutter/clutter-alpha.h: * clutter/clutter-alpha.c: Add a data parameter to the ClutterAlphaFunc; add a data+destroy parameter to clutter_alpha_set_func() and to clutter_alpha_new(), and turned the latter into clutter_alpha_new_full(); add a simple, empty constructor clutter_alpha_new(). These changes makes writing bindings a tad more easy, as bindings require passing their own functions in order to call the real alpha function. * clutter/clutter-behaviour.h: Clean up the header. * clutter/clutter-behaviours.[ch]: * clutter/clutter-behaviour-opacity.[ch]: * clutter/clutter-behaviour-path.[ch]: * clutter/clutter-behaviour-scale.[ch]: Split the ClutterBehaviourPath, ClutterBehaviourOpacity and ClutterBehaviourScale into their own files as they have been growing a bit. Fix ClutterBehaviourPath API. * clutter/clutter-media.h: Remove the commented "metadata_available" signal: gtk-doc chokes up on that. * clutter/clutter-timeline.h: * clutter/clutter-timeline.c: Remove the useless ClutterTimelineAlphaFunc signature; add missing accessor methods for the properties; clean up a bit. * clutter/clutter-util.h: * clutter/clutter-util.c: Remove unneeded function clutter_util_can_create_texture(). * clutter/clutter-feature.h: Sync the name of clutter_feature_get_all() with the name declared in clutter-feature.h. * clutter/Makefile.am: * clutter/clutter.h: Update. * examples/behave.c: Update to the new ClutterAlpha constructor. * examples/super-oh.c: Use the right pointer and avoid the compiler making a fuss about it.
2006-11-15 23:37:53 +00:00
#include "clutter-behaviour-opacity.h"
#include "clutter-behaviour-path.h"
#include "clutter-behaviour-rotate.h"
2006-11-15 Emmanuele Bassi <ebassi@openedhand.com> * clutter/clutter-alpha.h: * clutter/clutter-alpha.c: Add a data parameter to the ClutterAlphaFunc; add a data+destroy parameter to clutter_alpha_set_func() and to clutter_alpha_new(), and turned the latter into clutter_alpha_new_full(); add a simple, empty constructor clutter_alpha_new(). These changes makes writing bindings a tad more easy, as bindings require passing their own functions in order to call the real alpha function. * clutter/clutter-behaviour.h: Clean up the header. * clutter/clutter-behaviours.[ch]: * clutter/clutter-behaviour-opacity.[ch]: * clutter/clutter-behaviour-path.[ch]: * clutter/clutter-behaviour-scale.[ch]: Split the ClutterBehaviourPath, ClutterBehaviourOpacity and ClutterBehaviourScale into their own files as they have been growing a bit. Fix ClutterBehaviourPath API. * clutter/clutter-media.h: Remove the commented "metadata_available" signal: gtk-doc chokes up on that. * clutter/clutter-timeline.h: * clutter/clutter-timeline.c: Remove the useless ClutterTimelineAlphaFunc signature; add missing accessor methods for the properties; clean up a bit. * clutter/clutter-util.h: * clutter/clutter-util.c: Remove unneeded function clutter_util_can_create_texture(). * clutter/clutter-feature.h: Sync the name of clutter_feature_get_all() with the name declared in clutter-feature.h. * clutter/Makefile.am: * clutter/clutter.h: Update. * examples/behave.c: Update to the new ClutterAlpha constructor. * examples/super-oh.c: Use the right pointer and avoid the compiler making a fuss about it.
2006-11-15 23:37:53 +00:00
#include "clutter-behaviour-scale.h"
#include "clutter-bind-constraint.h"
#include "clutter-binding-pool.h"
#include "clutter-bin-layout.h"
#include "clutter-blur-effect.h"
#include "clutter-box.h"
#include "clutter-box-layout.h"
#include "clutter-cairo-texture.h"
#include "clutter-child-meta.h"
#include "clutter-click-action.h"
#include "clutter-clone.h"
#include "clutter-color.h"
#include "clutter-color-static.h"
#include "clutter-colorize-effect.h"
#include "clutter-constraint.h"
#include "clutter-container.h"
#include "clutter-deform-effect.h"
#include "clutter-desaturate-effect.h"
#include "clutter-device-manager.h"
#include "clutter-drag-action.h"
#include "clutter-effect.h"
#include "clutter-event.h"
#include "clutter-feature.h"
#include "clutter-fixed-layout.h"
#include "clutter-flow-layout.h"
#include "clutter-frame-source.h"
2006-05-29 08:59:36 +00:00
#include "clutter-group.h"
#include "clutter-input-device.h"
2008-11-17 Emmanuele Bassi <ebassi@linux.intel.com> Bug 1014 - Clutter Animation API Improvements * clutter/Makefile.am: * clutter/clutter.h: Update the build * clutter/clutter-types.h: Add AnimationMode, an enumeration for easing functions. * clutter/clutter-alpha.[ch]: Add the :mode property to control the function bound to an Alpha instance using an enumeration value. Also add six new alpha functions: - ease-in, ease-out, ease-in-out - sine-in, sine-out, sine-in-out * clutter/clutter-deprecated.h: Deprecate the #defines for the alpha functions. They will be replaced by entries in the ClutterAnimationMode. * clutter/clutter-interval.[ch]: Add ClutterInterval, an object for defining, validating and computing an interval between two values. * clutter/clutter-animation.[ch]: Add ClutterAnimation, an object responsible for animation the properties of a single actor along an interval of values. ClutterAnimation memory management is automatic. A simple wrapper method for ClutterActor is provided: clutter_actor_animate() which will create, or update, an animation for the passed actor. * clutter/clutter-debug.h: * clutter/clutter-main.c: Add a new 'animation' debug note. * clutter/clutter-script.c: Clean up the alpha functions whitelist, and add the new functions. * doc/reference/clutter/Makefile.am: * doc/reference/clutter/clutter-sections.txt: Update the API reference. * doc/reference/clutter/clutter-animation.xml: Renamed to doc/reference/clutter/clutter-animation-tutorial.xml to avoid clashes with the ClutterAnimation section. * doc/reference/clutter/clutter-docs.sgml: Renamed to doc/reference/clutter/clutter-docs.xml, as it was an XML file and not a SGML file. * tests/Makefile.am: * tests/interactive/Makefile.am: * tests/interactive/test-animation.c: * tests/interactive/test-easing.c: Add two tests for the new simple animation API and the easing functions. * tests/interactive/test-actors.c: * tests/interactive/test-behave.c: * tests/interactive/test-depth.c: * tests/interactive/test-effects.c: * tests/interactive/test-layout.c: * tests/interactive/test-multistage.c: * tests/interactive/test-paint-wrapper.c: * tests/interactive/test-rotate.c: * tests/interactive/test-scale.c: * tests/interactive/test-texture-quality.c: * tests/interactive/test-threads.c: * tests/interactive/test-viewport.c: Update interactive tests to the deprecations and new alpha API.
2008-11-18 09:50:03 +00:00
#include "clutter-interval.h"
#include "clutter-keysyms.h"
#include "clutter-layout-manager.h"
#include "clutter-layout-meta.h"
#include "clutter-list-model.h"
#include "clutter-main.h"
#include "clutter-media.h"
#include "clutter-model.h"
effect: Add OffscreenEffect The OffscreenEffect class is meant to be used to implement Effect sub-classes that create an offscreen framebuffer and redirect the actor's paint sequence there. The OffscreenEffect is useful for effects using fragment shaders. Any shader-based effect being applied to an actor through an offscreen buffer should be used before painting the resulting target material and not for every actor. This means that doing: pre_paint: cogl_program_use(program) set up offscreen buffer paint: [ actors ] → offscreen buffer → target material post_paint: paint target material cogl_program_use(null) Is not correct. Unfortunately, we cannot really do: post_paint: cogl_program_use(program) paint target material cogl_program_use(null) Because the OffscreenEffect::post_paint() implementation also pops the offscreen buffer and re-instates the previous framebuffer: post_paint: cogl_program_use(program) change frame buffer ← ouch! paint target material cogl_program_use(null) One way to fix it is to allow using the shader right before painting the target material - which means adding a new virtual inside the OffscreenEffect class vtable in additions to the ones defined by the parent Effect class. The newly-added paint_target() virtual allows the correct sequence of actions by adding an entry point for sub-classes to wrap the "paint target material" operation with custom code, in order to implement the case above correctly as: post_paint: change frame buffer cogl_program_use(program) paint target material cogl_program_use(null) The added upside is that sub-classes of OffscreenEffect involving shaders really just need to override the prepare() and paint_target() virtuals, since the pre_paint() and post_paint() do all that's needed.
2010-05-17 10:39:27 +00:00
#include "clutter-offscreen-effect.h"
#include "clutter-page-turn-effect.h"
#include "clutter-path-constraint.h"
#include "clutter-path.h"
#include "clutter-rectangle.h"
#include "clutter-score.h"
#include "clutter-scriptable.h"
#include "clutter-script.h"
#include "clutter-settings.h"
#include "clutter-shader.h"
#include "clutter-shader-effect.h"
#include "clutter-shader-types.h"
#include "clutter-snap-constraint.h"
#include "clutter-stage.h"
#include "clutter-stage-manager.h"
#include "clutter-stage-window.h"
2010-05-11 14:04:34 +00:00
#include "clutter-state.h"
#include "clutter-table-layout.h"
#include "clutter-texture.h"
#include "clutter-text.h"
#include "clutter-timeline.h"
#include "clutter-timeout-pool.h"
#include "clutter-types.h"
#include "clutter-units.h"
#include "clutter-util.h"
#include "clutter-version.h"
2006-05-29 08:59:36 +00:00
#include "clutter-enum-types.h"
#undef __CLUTTER_H_INSIDE__
#endif /* __CLUTTER_H__ */