gnomemm r2050 - in cluttermm/branches/cluttermm-0.8: . clutter/src examples tests
- From: murrayc svn gnome org
- To: svn-commits-list gnome org
- Subject: gnomemm r2050 - in cluttermm/branches/cluttermm-0.8: . clutter/src examples tests
- Date: Tue, 17 Feb 2009 08:28:27 +0000 (UTC)
Author: murrayc
Date: Tue Feb 17 08:28:27 2009
New Revision: 2050
URL: http://svn.gnome.org/viewvc/gnomemm?rev=2050&view=rev
Log:
Back-ported some changes from trunk.
Modified:
cluttermm/branches/cluttermm-0.8/ChangeLog
cluttermm/branches/cluttermm-0.8/clutter/src/actor.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/actor.hg
cluttermm/branches/cluttermm-0.8/clutter/src/alpha.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/alpha.hg
cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-depth.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-depth.hg
cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-ellipse.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-opacity.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-rotate.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-scale.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/behaviour.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/clone-texture.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/clutter_methods.defs
cluttermm/branches/cluttermm-0.8/clutter/src/container.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/container.hg
cluttermm/branches/cluttermm-0.8/clutter/src/effecttemplate.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/entry.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/group.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/label.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/media.hg
cluttermm/branches/cluttermm-0.8/clutter/src/rectangle.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/score.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/score.hg
cluttermm/branches/cluttermm-0.8/clutter/src/script.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/script.hg
cluttermm/branches/cluttermm-0.8/clutter/src/scriptable.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/scriptable.hg
cluttermm/branches/cluttermm-0.8/clutter/src/shader.hg
cluttermm/branches/cluttermm-0.8/clutter/src/stage.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/stage.hg
cluttermm/branches/cluttermm-0.8/clutter/src/texture.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/texture.hg
cluttermm/branches/cluttermm-0.8/clutter/src/timeline.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/types.ccg
cluttermm/branches/cluttermm-0.8/clutter/src/types.hg
cluttermm/branches/cluttermm-0.8/examples/effect.cc
cluttermm/branches/cluttermm-0.8/examples/test-actors.cc
cluttermm/branches/cluttermm-0.8/tests/test-alpha-creation.cc
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/actor.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/actor.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/actor.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-actor.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/actor.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/actor.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/actor.hg Tue Feb 17 08:28:27 2009
@@ -20,7 +20,7 @@
#include <cluttermm/scriptable.h>
#include <cluttermm/shader.h>
#include <cluttermm/types.h> // For Event*
-#include <clutter/clutter-actor.h> // For ClutterActorBox
+#include <clutter/clutter.h> // For ClutterActorBox
_DEFS(cluttermm,clutter)
_PINCLUDE(glibmm/private/object_p.h)
@@ -135,7 +135,8 @@
_WRAP_METHOD(Glib::RefPtr<Shader> get_shader(), clutter_actor_get_shader)
_WRAP_METHOD(Glib::RefPtr<const Shader> get_shader() const, clutter_actor_get_shader, constversion)
_WRAP_METHOD(void set_shader(const Glib::RefPtr<Shader>& shader), clutter_actor_set_shader)
- _WRAP_METHOD(void set_shader_param(const Glib::ustring& param, float value), clutter_actor_set_shader_param)
+ _WRAP_METHOD_DOCS_ONLY(clutter_actor_set_shader_param)
+ template <class ParamType> void set_shader_param(const Glib::ustring& param, const ParamType& value);
//_WRAP_METHOD_DOCS_ONLY(clutter_actor_get_paint_area)
//ActorBox get_paint_area() const;
_WRAP_METHOD(bool is_rotated() const, clutter_actor_is_rotated)
@@ -255,7 +256,9 @@
_WRAP_PROPERTY("x", int)
_WRAP_PROPERTY("y", int)
- protected:
+protected:
+ _WRAP_METHOD(void set_shader_param_value(const Glib::ustring& param, float value),
+ clutter_actor_set_shader_param)
// according to the clutter docs, these functions should never be called
// directly and are only for subclasses
_WRAP_METHOD(void pick(const Color& color), clutter_actor_pick)
@@ -276,5 +279,16 @@
};
-} // namespace Clutter
+#ifndef DOXYGEN_SHOULD_SKIP_THIS
+template <class ParamType>
+void Actor::set_shader_param(const Glib::ustring& param, const ParamType& value)
+{
+ Glib::Value<ParamType> param_value;
+ param_value.init(Glib::Value<ParamType>::value_type());
+ param_value.set(value);
+ this->set_shader_param_value(param, param_value);
+}
+#endif /* DOXYGEN_SHOULD_SKIP_THIS */
+
+} // namespace Clutter
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/alpha.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/alpha.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/alpha.ccg Tue Feb 17 08:28:27 2009
@@ -15,27 +15,29 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-alpha.h>
+#include <clutter/clutter.h>
+
+namespace
+{
static guint32 SignalProxy_Alpha_callback(ClutterAlpha *alpha, gpointer user_data)
{
guint32 value;
Clutter::Alpha::SlotAlphaFunc* the_slot = static_cast<Clutter::Alpha::SlotAlphaFunc*>(user_data);
- #ifdef GLIBMM_EXCEPTIONS_ENABLED
+#ifdef GLIBMM_EXCEPTIONS_ENABLED
try
{
- #endif //GLIBMM_EXCEPTIONS_ENABLED
+#endif
Glib::RefPtr<Clutter::Alpha> cpp_alpha = Glib::wrap(alpha, true /* take reference */);
value = (*the_slot)(cpp_alpha);
- #ifdef GLIBMM_EXCEPTIONS_ENABLED
+#ifdef GLIBMM_EXCEPTIONS_ENABLED
}
catch(...)
{
Glib::exception_handlers_invoke();
}
- #endif //GLIBMM_EXCEPTIONS_ENABLED
-
+#endif
return value;
}
@@ -44,33 +46,85 @@
delete static_cast<Clutter::Alpha::SlotAlphaFunc*>(data);
}
+} // anonymous namespace
+
namespace Clutter
{
-Alpha::Alpha(const Glib::RefPtr<Timeline>& timeline, const SlotAlphaFunc& slot)
-:
- _CONSTRUCT()
+guint32 Alpha::ramp_inc_func(const Glib::RefPtr<Alpha>& alpha)
{
- _INITIALLY_UNOWNED_SINK
- set_timeline(timeline);
- set_func(slot);
+ return clutter_ramp_inc_func(alpha->gobj(), 0);
+}
+
+guint32 Alpha::ramp_dec_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_ramp_dec_func(alpha->gobj(), 0);
+}
+
+guint32 Alpha::ramp_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_ramp_func(alpha->gobj(), 0);
+}
+
+guint32 Alpha::sine_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_sine_func(alpha->gobj(), 0);
+}
+
+guint32 Alpha::sine_inc_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_sine_inc_func(alpha->gobj(), 0);
+}
+
+guint32 Alpha::sine_dec_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_sine_dec_func(alpha->gobj(), 0);
+}
+
+guint32 Alpha::sine_half_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_sine_half_func(alpha->gobj(), 0);
+}
+
+guint32 Alpha::square_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_square_func(alpha->gobj(), 0);
+}
+
+guint32 Alpha::smoothstep_inc_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_smoothstep_inc_func(alpha->gobj(), 0);
}
-Alpha::Alpha(const Glib::RefPtr<Timeline>& timeline, ClutterAlphaFunc callback)
+guint32 Alpha::smoothstep_dec_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_smoothstep_dec_func(alpha->gobj(), 0);
+}
+
+guint32 Alpha::exp_inc_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_exp_inc_func(alpha->gobj(), 0);
+}
+
+guint32 Alpha::exp_dec_func(const Glib::RefPtr<Alpha>& alpha)
+{
+ return clutter_exp_dec_func(alpha->gobj(), 0);
+}
+
+Alpha::Alpha(const Glib::RefPtr<Timeline>& timeline, const SlotAlphaFunc& slot)
:
_CONSTRUCT()
{
_INITIALLY_UNOWNED_SINK
set_timeline(timeline);
- clutter_alpha_set_func(gobj(), callback, NULL, NULL);
+ set_func(slot);
}
-
void Alpha::set_func(const SlotAlphaFunc& slot)
{
//Create a copy of the slot. A pointer to this will be passed through the callback's data parameter.
//It will be deleted when SignalProxy_Alpha_callback_destroy() is called.
- SlotAlphaFunc* slot_copy = new SlotAlphaFunc(slot);
+ SlotAlphaFunc *const slot_copy = new SlotAlphaFunc(slot);
clutter_alpha_set_func(
gobj(),
@@ -78,30 +132,4 @@
&SignalProxy_Alpha_callback_destroy);
}
-static guint32
-alpha_slot_proxy(const Glib::RefPtr<Alpha>& alpha, ClutterAlphaFunc c_func)
-{
- return c_func(alpha->gobj (), NULL);
-}
-
-inline static
-Alpha::SlotAlphaFunc generate_alpha_slot_proxy (ClutterAlphaFunc func)
-{
- return sigc::bind (sigc::ptr_fun(alpha_slot_proxy), func);
-}
-
-Alpha::SlotAlphaFunc ALPHA_RAMP_INC = generate_alpha_slot_proxy(CLUTTER_ALPHA_RAMP_INC);
-Alpha::SlotAlphaFunc ALPHA_RAMP_DEC = generate_alpha_slot_proxy(CLUTTER_ALPHA_RAMP_DEC);
-Alpha::SlotAlphaFunc ALPHA_RAMP = generate_alpha_slot_proxy(CLUTTER_ALPHA_RAMP);
-Alpha::SlotAlphaFunc ALPHA_SINE = generate_alpha_slot_proxy(CLUTTER_ALPHA_SINE);
-Alpha::SlotAlphaFunc ALPHA_SINE_INC = generate_alpha_slot_proxy(CLUTTER_ALPHA_SINE_INC);
-Alpha::SlotAlphaFunc ALPHA_SINE_DEC = generate_alpha_slot_proxy(CLUTTER_ALPHA_SINE_DEC);
-Alpha::SlotAlphaFunc ALPHA_SINE_HALF = generate_alpha_slot_proxy(CLUTTER_ALPHA_SINE_HALF);
-Alpha::SlotAlphaFunc ALPHA_SQUARE = generate_alpha_slot_proxy(CLUTTER_ALPHA_SQUARE);
-Alpha::SlotAlphaFunc ALPHA_SMOOTHSTEP_INC = generate_alpha_slot_proxy(CLUTTER_ALPHA_SMOOTHSTEP_INC);
-Alpha::SlotAlphaFunc ALPHA_SMOOTHSTEP_DEC = generate_alpha_slot_proxy(CLUTTER_ALPHA_SMOOTHSTEP_DEC);
-Alpha::SlotAlphaFunc ALPHA_EXP_INC = generate_alpha_slot_proxy(CLUTTER_ALPHA_EXP_INC);
-Alpha::SlotAlphaFunc ALPHA_EXP_DEC = generate_alpha_slot_proxy(CLUTTER_ALPHA_EXP_DEC);
-
-} //namespace Clutter
-
+} // namespace Clutter
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/alpha.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/alpha.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/alpha.hg Tue Feb 17 08:28:27 2009
@@ -17,12 +17,11 @@
#include <glibmm/object.h>
#include <cluttermm/timeline.h>
-#include <clutter/clutter-alpha.h>
+#include <clutter/clutter.h>
_DEFS(cluttermm,clutter)
_PINCLUDE(glibmm/private/object_p.h)
-
namespace Clutter
{
@@ -31,42 +30,47 @@
_CLASS_GOBJECT(Alpha, ClutterAlpha, CLUTTER_ALPHA, Glib::Object, GObject)
_DERIVES_INITIALLY_UNOWNED()
-protected:
- _CTOR_DEFAULT()
-
public:
-
/** For instance,
* guint32 on_alpha(const Glib::RefPtr<Alpha>& alpha);
*/
- typedef sigc::slot<guint32, const Glib::RefPtr<Alpha>& > SlotAlphaFunc;
+ typedef sigc::slot<guint32, const Glib::RefPtr<Alpha>&> SlotAlphaFunc;
+
+ //! @name Pre-defined Alpha Functions
+ //! @{
+ static guint32 ramp_inc_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 ramp_dec_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 ramp_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 sine_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 sine_inc_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 sine_dec_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 sine_half_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 square_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 smoothstep_inc_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 smoothstep_dec_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 exp_inc_func(const Glib::RefPtr<Alpha>& alpha);
+ static guint32 exp_dec_func(const Glib::RefPtr<Alpha>& alpha);
+ //! @}
protected:
- /** Creates a new Alpha instance and sets the timeline and the alpha function.
- * @param timeline Timeline.
- * @param slot Alpha function.
- */
- Alpha(const Glib::RefPtr<Timeline>& timeline, const SlotAlphaFunc& slot);
+ _CTOR_DEFAULT()
/** Creates a new Alpha instance and sets the timeline and the alpha function.
* @param timeline Timeline.
* @param slot Alpha function.
*/
- Alpha(const Glib::RefPtr<Timeline>& timeline, ClutterAlphaFunc callback);
+ Alpha(const Glib::RefPtr<Timeline>& timeline, const SlotAlphaFunc& slot);
public:
_WRAP_CREATE()
_WRAP_CREATE(const Glib::RefPtr<Timeline>& timeline, const SlotAlphaFunc& slot)
- _WRAP_CREATE(const Glib::RefPtr<Timeline>& timeline, ClutterAlphaFunc callback)
-
-
_WRAP_METHOD(void set_timeline(const Glib::RefPtr<Timeline>& timeline), clutter_alpha_set_timeline)
_WRAP_METHOD(Glib::RefPtr<Timeline> get_timeline() const, clutter_alpha_get_timeline)
_WRAP_METHOD(guint32 get_alpha() const, clutter_alpha_get_alpha)
- void set_func(const SlotAlphaFunc& slot);
_IGNORE(clutter_alpha_set_func)
+ void set_func(const SlotAlphaFunc& slot);
_WRAP_PROPERTY("alpha", guint)
_WRAP_PROPERTY("timeline", Glib::RefPtr<Timeline>)
@@ -75,22 +79,4 @@
_IGNORE(clutter_alpha_set_closure)
};
-/// @name Pre-defined Alpha functions
-/// @related Alpha
-/// @{
-extern Alpha::SlotAlphaFunc ALPHA_RAMP_INC;
-extern Alpha::SlotAlphaFunc ALPHA_RAMP_DEC;
-extern Alpha::SlotAlphaFunc ALPHA_RAMP;
-extern Alpha::SlotAlphaFunc ALPHA_SINE;
-extern Alpha::SlotAlphaFunc ALPHA_SINE_INC;
-extern Alpha::SlotAlphaFunc ALPHA_SINE_DEC;
-extern Alpha::SlotAlphaFunc ALPHA_SINE_HALF;
-extern Alpha::SlotAlphaFunc ALPHA_SQUARE;
-extern Alpha::SlotAlphaFunc ALPHA_SMOOTHSTEP_INC;
-extern Alpha::SlotAlphaFunc ALPHA_SMOOTHSTEP_DEC;
-extern Alpha::SlotAlphaFunc ALPHA_EXP_INC;
-extern Alpha::SlotAlphaFunc ALPHA_EXP_DEC;
-/// @}
-
} // namespace Clutter
-// vim:ts=2,sw=2
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-depth.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-depth.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-depth.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-behaviour-depth.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-depth.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-depth.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-depth.hg Tue Feb 17 08:28:27 2009
@@ -30,7 +30,7 @@
_CLASS_GOBJECT(BehaviourDepth, ClutterBehaviourDepth, CLUTTER_BEHAVIOUR_DEPTH, Behaviour, ClutterBehaviour)
protected:
- _WRAP_CTOR(BehaviourDepth(const Glib::RefPtr<Alpha>& alpha, int start_depth, int end_depth), clutter_behaviour_depth_new)
+ _WRAP_CTOR(BehaviourDepth(const Glib::RefPtr<Alpha>& alpha, int depth_start, int depth_end), clutter_behaviour_depth_new)
public:
_WRAP_CREATE(const Glib::RefPtr<Alpha>& alpha, int start_depth, int end_depth)
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-ellipse.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-ellipse.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-ellipse.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-behaviour-ellipse.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-opacity.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-opacity.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-opacity.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-behaviour-opacity.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-rotate.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-rotate.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-rotate.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-behaviour-rotate.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-scale.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-scale.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/behaviour-scale.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-behaviour-scale.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/behaviour.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/behaviour.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/behaviour.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-behaviour.h>
+#include <clutter/clutter.h>
static void SignalProxy_behaviours_foreach_callback(ClutterBehaviour* behaviour, ClutterActor *actor, gpointer user_data)
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/clone-texture.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/clone-texture.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/clone-texture.ccg Tue Feb 17 08:28:27 2009
@@ -15,8 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-clone-texture.h>
-#include <clutter/clutter-enum-types.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/clutter_methods.defs
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/clutter_methods.defs (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/clutter_methods.defs Tue Feb 17 08:28:27 2009
@@ -4941,7 +4941,7 @@
(c-name "clutter_score_remove")
(return-type "none")
(parameters
- '("guint" "id")
+ '("gulong" "id")
)
)
@@ -4956,7 +4956,7 @@
(c-name "clutter_score_get_timeline")
(return-type "ClutterTimeline*")
(parameters
- '("guint" "id")
+ '("gulong" "id")
)
)
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/container.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/container.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/container.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-container.h>
+#include <clutter/clutter.h>
static void SignalProxy_Container_foreach_callback(ClutterActor *actor, gpointer user_data)
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/container.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/container.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/container.hg Tue Feb 17 08:28:27 2009
@@ -18,7 +18,7 @@
#include <cluttermm/actor.h>
#include <glibmm/interface.h>
#include <glibmm/ustring.h>
-#include <clutter/clutter-container.h>
+#include <clutter/clutter.h>
_DEFS(cluttermm,clutter)
_PINCLUDE(glibmm/private/interface_p.h)
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/effecttemplate.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/effecttemplate.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/effecttemplate.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-effect.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/entry.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/entry.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/entry.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-entry.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/group.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/group.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/group.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-group.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/label.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/label.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/label.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-label.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/media.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/media.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/media.hg Tue Feb 17 08:28:27 2009
@@ -17,7 +17,7 @@
#include <glibmm/interface.h>
#include <glibmm/ustring.h>
-#include <clutter/clutter-media.h>
+#include <clutter/clutter.h>
_DEFS(cluttermm,clutter)
_PINCLUDE(glibmm/private/interface_p.h)
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/rectangle.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/rectangle.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/rectangle.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-rectangle.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/score.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/score.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/score.ccg Tue Feb 17 08:28:27 2009
@@ -15,15 +15,14 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-score.h>
+#include <clutter/clutter.h>
namespace Clutter
{
-guint Score::append(const Glib::RefPtr<Timeline>& timeline)
+gulong Score::append(const Glib::RefPtr<Timeline>& timeline)
{
- return clutter_score_append(gobj(), NULL, timeline->gobj());
+ return clutter_score_append(gobj(), NULL, timeline->gobj());
}
-} //namespace Clutter
-
+} // namespace Clutter
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/score.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/score.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/score.hg Tue Feb 17 08:28:27 2009
@@ -17,7 +17,7 @@
#include <glibmm/object.h>
#include <cluttermm/timeline.h>
-#include <clutter/clutter-score.h>
+#include <clutter/clutter.h>
_DEFS(cluttermm,clutter)
_PINCLUDE(glibmm/private/object_p.h)
@@ -47,15 +47,15 @@
* @param timeline the Timeline to append
* @return the id of the newly added timeline, to be used with get_timeline() and remove().
*/
- guint append(const Glib::RefPtr<Timeline>& timeline);
+ gulong append(const Glib::RefPtr<Timeline>& timeline);
_WRAP_METHOD(void append_at_marker(const Glib::RefPtr<Timeline>& parent, const Glib::ustring& marker_name, const Glib::RefPtr<Timeline>& timeline), clutter_score_append_at_marker)
- _WRAP_METHOD(void remove(guint id), clutter_score_remove)
+ _WRAP_METHOD(void remove(gulong id), clutter_score_remove)
_WRAP_METHOD(void remove_all(), clutter_score_remove_all)
- _WRAP_METHOD(Glib::RefPtr<Timeline> get_timeline(guint id), clutter_score_get_timeline, refreturn)
- _WRAP_METHOD(Glib::RefPtr<const Timeline> get_timeline(guint id) const, clutter_score_get_timeline, , refreturn, constversion)
+ _WRAP_METHOD(Glib::RefPtr<Timeline> get_timeline(gulong id), clutter_score_get_timeline, refreturn)
+ _WRAP_METHOD(Glib::RefPtr<const Timeline> get_timeline(gulong id) const, clutter_score_get_timeline, , refreturn, constversion)
#m4 _CONVERSION(`GSList*', `Glib::SListHandle<Glib::RefPtr<Timeline> >', `$2(($3), Glib::OWNERSHIP_SHALLOW)')
#m4 _CONVERSION(`GSList*', `Glib::SListHandle<Glib::RefPtr<const Timeline> >', `$2(($3), Glib::OWNERSHIP_SHALLOW)')
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/script.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/script.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/script.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-script.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/script.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/script.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/script.hg Tue Feb 17 08:28:27 2009
@@ -17,7 +17,7 @@
#include <glibmm/object.h>
#include <cluttermm/timeline.h>
-#include <clutter/clutter-script.h>
+#include <clutter/clutter.h>
_DEFS(cluttermm,clutter)
_PINCLUDE(glibmm/private/object_p.h)
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/scriptable.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/scriptable.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/scriptable.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-scriptable.h>
+#include <clutter/clutter.h>
namespace Clutter
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/scriptable.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/scriptable.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/scriptable.hg Tue Feb 17 08:28:27 2009
@@ -18,7 +18,7 @@
#include <glibmm/interface.h>
#include <glibmm/ustring.h>
#include <cluttermm/script.h>
-#include <clutter/clutter-scriptable.h>
+#include <clutter/clutter.h>
_DEFS(cluttermm,clutter)
_PINCLUDE(glibmm/private/interface_p.h)
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/shader.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/shader.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/shader.hg Tue Feb 17 08:28:27 2009
@@ -16,7 +16,7 @@
*/
#include <glibmm/object.h>
-#include <clutter/clutter-shader.h>
+#include <clutter/clutter.h>
_DEFS(cluttermm,clutter)
_PINCLUDE(glibmm/private/object_p.h)
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/stage.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/stage.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/stage.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-stage.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/stage.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/stage.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/stage.hg Tue Feb 17 08:28:27 2009
@@ -17,7 +17,7 @@
#include <cluttermm/group.h>
#include <cluttermm/color.h>
-#include <clutter/clutter-stage.h> // For ClutterPerspective
+#include <clutter/clutter.h> // For ClutterPerspective
_DEFS(cluttermm,clutter)
_PINCLUDE(cluttermm/private/group_p.h)
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/texture.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/texture.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/texture.ccg Tue Feb 17 08:28:27 2009
@@ -15,8 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-texture.h>
-#include <clutter/clutter-enum-types.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/texture.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/texture.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/texture.hg Tue Feb 17 08:28:27 2009
@@ -17,7 +17,7 @@
#include <cluttermm/actor.h>
#include <cluttermm/types.h>
-#include <clutter/clutter-texture.h> // For CoglHandle
+#include <clutter/clutter.h> // For CoglHandle
_DEFS(cluttermm,clutter)
_PINCLUDE(cluttermm/private/actor_p.h)
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/timeline.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/timeline.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/timeline.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-timeline.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/types.ccg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/types.ccg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/types.ccg Tue Feb 17 08:28:27 2009
@@ -15,7 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-types.h>
+#include <clutter/clutter.h>
namespace Clutter
{
Modified: cluttermm/branches/cluttermm-0.8/clutter/src/types.hg
==============================================================================
--- cluttermm/branches/cluttermm-0.8/clutter/src/types.hg (original)
+++ cluttermm/branches/cluttermm-0.8/clutter/src/types.hg Tue Feb 17 08:28:27 2009
@@ -15,11 +15,7 @@
* Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#include <clutter/clutter-types.h>
-#include <clutter/clutter-event.h>
-#include <clutter/clutter-units.h>
-#include <clutter/clutter-color.h>
-#include <clutter/clutter-main.h>
+#include <clutter/clutter.h>
_DEFS(cluttermm,clutter)
Modified: cluttermm/branches/cluttermm-0.8/examples/effect.cc
==============================================================================
--- cluttermm/branches/cluttermm-0.8/examples/effect.cc (original)
+++ cluttermm/branches/cluttermm-0.8/examples/effect.cc Tue Feb 17 08:28:27 2009
@@ -2,37 +2,38 @@
#include <cluttermm/init.h>
#include <iostream>
-void on_move_finished(const Glib::RefPtr<Clutter::Actor>& actor, const Glib::RefPtr<Clutter::EffectTemplate>& effect)
+void on_move_finished(const Glib::RefPtr<Clutter::Actor>& actor,
+ const Glib::RefPtr<Clutter::EffectTemplate>& effect)
{
// Restart
- effect->move(actor, 450, 450, sigc::bind(sigc::ptr_fun(on_move_finished), effect));
+ effect->move(actor, 450, 450, sigc::bind(sigc::ptr_fun(&on_move_finished), effect));
}
-int
-main (int argc, char *argv[])
+int main(int argc, char** argv)
{
// Initialize the C++ wrapper types:
Clutter::init(&argc, &argv);
Clutter::Color stage_color (0x61, 0x64, 0x8c, 0xff);
- Glib::RefPtr<Clutter::Stage> stage = Clutter::Stage::get_default ();
- stage->set_size (800, 600);
+ Glib::RefPtr<Clutter::Stage> stage = Clutter::Stage::get_default();
+ stage->set_size(800, 600);
- stage->set_title ("Effect Test");
- stage->set_color (stage_color);
+ stage->set_title("Effect Test");
+ stage->set_color(stage_color);
Glib::RefPtr<Clutter::Timeline> timeline =
- Clutter::Timeline::create (360, 60); // num frames, fps
- Glib::RefPtr<Clutter::EffectTemplate> effect = Clutter::EffectTemplate::create(timeline, Clutter::ALPHA_RAMP);
+ Clutter::Timeline::create(360, 60); // num frames, fps
+ Glib::RefPtr<Clutter::EffectTemplate> effect =
+ Clutter::EffectTemplate::create(timeline, &Clutter::Alpha::ramp_func);
- Glib::RefPtr<Clutter::Texture> texture(Clutter::Texture::create());
+ Glib::RefPtr<Clutter::Texture> texture = Clutter::Texture::create();
texture->set_from_file("actor.png");
stage->add_actor(texture);
stage->show_all();
timeline->start();
- effect->move(texture, 450, 450, sigc::bind(sigc::ptr_fun(on_move_finished), effect));
+ effect->move(texture, 450, 450, sigc::bind(sigc::ptr_fun(&on_move_finished), effect));
Clutter::main();
return 0;
Modified: cluttermm/branches/cluttermm-0.8/examples/test-actors.cc
==============================================================================
--- cluttermm/branches/cluttermm-0.8/examples/test-actors.cc (original)
+++ cluttermm/branches/cluttermm-0.8/examples/test-actors.cc Tue Feb 17 08:28:27 2009
@@ -128,7 +128,7 @@
// Set up some behaviours to handle scaling
Glib::RefPtr<Clutter::Alpha> alpha =
- Clutter::Alpha::create(timeline, Clutter::ALPHA_SINE);
+ Clutter::Alpha::create(timeline, &Clutter::Alpha::sine_func);
Glib::RefPtr<Clutter::BehaviourScale> scaler_1 =
Clutter::BehaviourScale::create(alpha,
Modified: cluttermm/branches/cluttermm-0.8/tests/test-alpha-creation.cc
==============================================================================
--- cluttermm/branches/cluttermm-0.8/tests/test-alpha-creation.cc (original)
+++ cluttermm/branches/cluttermm-0.8/tests/test-alpha-creation.cc Tue Feb 17 08:28:27 2009
@@ -1,40 +1,30 @@
#include <cluttermm.h>
-#include <clutter/clutter.h>
-#include <iostream>
-Glib::RefPtr<Clutter::Actor> hand;
-
-int
-main (int argc, char *argv[])
+int main(int argc, char** argv)
{
- // initialize the C++ wrapper types
- Clutter::init(&argc, &argv);
+ // initialize the C++ wrapper types
+ Clutter::init(&argc, &argv);
- Glib::RefPtr<Clutter::Stage> stage = Clutter::Stage::get_default ();
+ Glib::RefPtr<Clutter::Stage> stage = Clutter::Stage::get_default();
- // Create a timeline to manage animation
- Glib::RefPtr<Clutter::Timeline> timeline =
- Clutter::Timeline::create (360, 60); // num frames, fps
+ // Create a timeline to manage animation
+ Glib::RefPtr<Clutter::Timeline> timeline =
+ Clutter::Timeline::create(360, 60); // num frames, fps
- // Set up some behaviours to handle scaling
- //Causes a Gobject (refcount?) warning: Glib::RefPtr<Clutter::Alpha> alpha =
- // Clutter::Alpha::create (timeline, Clutter::ALPHA_SINE);
- Glib::RefPtr<Clutter::Alpha> alpha =
- Clutter::Alpha::create (timeline, CLUTTER_ALPHA_SINE);
+ // Set up some behaviours to handle scaling
+ Glib::RefPtr<Clutter::Alpha> alpha =
+ Clutter::Alpha::create(timeline, sigc::ptr_fun(Clutter::Alpha::sine_inc_func));
- Glib::RefPtr<Clutter::BehaviourScale> scaler_1 =
- Clutter::BehaviourScale::create (alpha,
- 0.5, 0.5,
- 1.0, 1.0);
+ Glib::RefPtr<Clutter::BehaviourScale> scaler_1 =
+ Clutter::BehaviourScale::create(alpha, 0.5, 0.5, 1.0, 1.0);
- // Show everying ( and map window )
- stage->show ();
+ // Show everying ( and map window )
+ stage->show();
- // and start it
- timeline->start ();
+ // and start it
+ timeline->start();
- clutter_main ();
+ Clutter::main();
- return 0;
+ return 0;
}
-
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]