On Thu, 2009-08-13 at 10:25 -0500, Uday Verma wrote: > If you use variables to pass these values to clutter_actor_animate and > if any of these variables is of incorrect type, the function just > segfaults. > > gint angle = 360; // instead of a double > clutter_actor_animate (myactor, CLUTTER_EASE_IN, 100, > "rotation-angle-z", x, NULL); // will segfault
yes, it's expected; and there's nothing Clutter can do, since it's we're using variable length arguments to read the property (name, value) pairs. it's the burden of C developers to pass sensible stuff to the functions or expect a segmentation fault. if you want type safety for variable list of arguments I can suggest you use Python or Perl: the Clutter 1.0 bindings are quite good. ciao, Emmanuele. > -- > > On Thu, Aug 13, 2009 at 3:50 AM, Samuel Degrande<samuel.degra...@lifl.fr> > wrote: > > On 13/08/2009 01:41, Ian Walberg wrote: > >> > >> Neil, > >> > >> Thanks that helps. > >> > >> However I am getting this following error :- > >> > >> 'Cannot bind property '' objects of type 'ClutterTexture' do not have > >> this property' > >> > >> When I try the rotation example :- > >> > >> clutter_actor_animate (actor, CLUTTER_EASE_IN, 100, > >> "rotation-angle-z", 360, > >> "fixed::rotation-center-z",¢er, > >> NULL); > >> Thanks > >> > >> Ian > >> > > > > I was caught by such an error several times !! > > > > You have to take care to provide the right type of values. > > So you need, for example > > > > clutter_actor_animate (actor, CLUTTER_EASE_IN, 100, > > "rotation-angle-z", 360.0, > > "fixed::rotation-center-z",¢er, > > NULL); > > > > This is rather very annoying, because we are so used to implicit > > type conversion... > > > > -- > > Samuel Degrande LIFL - UMR8022 CNRS - INRIA Futurs - Bat M3 > > Phone: (33)3.28.77.85.30 USTL - Universite de Lille 1 > > (33)3.62.53.15.70 59655 VILLENEUVE D'ASCQ CEDEX - FRANCE > > [CA certs: http://igc.services.cnrs.fr/CNRS-Standard/recherche.html ] > > -- > > To unsubscribe send a mail to clutter+unsubscr...@o-hand.com > > > > > > > > -- > Uday > http://soundc.de/ -- Emmanuele Bassi, Senior Engineer | emmanuele.ba...@intel.com Intel Open Source Technology Center | http://oss.intel.com -- To unsubscribe send a mail to clutter+unsubscr...@o-hand.com