+2007-11-19 Øyvind Kolås <pippin@o-hand.com>
+
+ * clutter/clutter-actor.[ch]: (clutter_actor_set_rotationx),
+ (clutter_actor_set_rotation): swapped axis and angle around,
+ the new argument order is: (axis, angle, x, y, z). Also removed
+ deprecated rotation functions from header.
+
+ Updated use of clutter_actor_set_rotation? in the following files:
+
+ * clutter/clutter-behaviour-rotate.c:
+ * clutter/clutter-effect.c:
+ * tests/test-actors.c:
+ * tests/test-project.c:
+
2007-11-19 Emmanuele Bassi <ebassi@openedhand.com>
* clutter/clutter-label.[ch]: Constify the color argument
* clutter/clutter-stage.c:
* tests/test-events.c:
Parent Actors no longer need to be set reactive for reactive
- children to get events. Also makes groups now pickable.
+ children to get events. Also makes groups now pickable.
(#597, #423)
* clutter/clutter-texture.c:
/**
* clutter_actor_set_rotationx:
* @self: a #ClutterActor
- * @angle: the angle of rotation
* @axis: the axis of rotation
+ * @angle: the angle of rotation
* @x: X coordinate of the rotation center
* @y: Y coordinate of the rotation center
* @z: Z coordinate of the rotation center
*/
void
clutter_actor_set_rotationx (ClutterActor *self,
- ClutterFixed angle,
ClutterRotateAxis axis,
+ ClutterFixed angle,
gint x,
gint y,
gint z)
/**
* clutter_actor_set_rotation:
* @self: a #ClutterActor
- * @angle: the angle of rotation
* @axis: the axis of rotation
+ * @angle: the angle of rotation
* @x: X coordinate of the rotation center
* @y: Y coordinate of the rotation center
* @z: Z coordinate of the rotation center
*/
void
clutter_actor_set_rotation (ClutterActor *self,
- gdouble angle,
ClutterRotateAxis axis,
+ gdouble angle,
gint x,
gint y,
gint z)
{
g_return_if_fail (CLUTTER_IS_ACTOR (self));
- clutter_actor_set_rotationx (self, CLUTTER_FLOAT_TO_FIXED (angle),
- axis,
+ clutter_actor_set_rotationx (self, axis,
+ CLUTTER_FLOAT_TO_FIXED (angle),
x, y, z);
}
gint y);
void clutter_actor_set_rotation (ClutterActor *self,
- gdouble angle,
ClutterRotateAxis axis,
+ gdouble angle,
gint x,
gint y,
- gint z);void clutter_actor_set_rotationx (ClutterActor *self,
- ClutterFixed fixed,
+ gint z);
+void clutter_actor_set_rotationx (ClutterActor *self,
ClutterRotateAxis axis,
+ ClutterFixed fixed,
gint x,
gint y,
gint z);
gint *x,
gint *y,
gint *z);
-void clutter_actor_rotate_x (ClutterActor *self,
- gfloat angle,
- gint y,
- gint z);
-void clutter_actor_rotate_y (ClutterActor *self,
- gfloat angle,
- gint x,
- gint z);
-void clutter_actor_rotate_z (ClutterActor *self,
- gfloat angle,
- gint x,
- gint y);
-void clutter_actor_rotate_xx (ClutterActor *self,
- ClutterFixed angle,
- gint y,
- gint z);
-void clutter_actor_rotate_yx (ClutterActor *self,
- ClutterFixed angle,
- gint x,
- gint z);
-void clutter_actor_rotate_zx (ClutterActor *self,
- ClutterFixed angle,
- gint x,
- gint y);
-gdouble clutter_actor_get_rxang (ClutterActor *self);
-gdouble clutter_actor_get_ryang (ClutterActor *self);
-gdouble clutter_actor_get_rzang (ClutterActor *self);
-ClutterFixed clutter_actor_get_rxangx (ClutterActor *self);
-ClutterFixed clutter_actor_get_ryangx (ClutterActor *self);
-ClutterFixed clutter_actor_get_rzangx (ClutterActor *self);
void clutter_actor_set_opacity (ClutterActor *self,
guint8 opacity);
rotate_behaviour = CLUTTER_BEHAVIOUR_ROTATE (behaviour);
priv = rotate_behaviour->priv;
- clutter_actor_set_rotationx (actor, angle,
- priv->axis,
+ clutter_actor_set_rotationx (actor, priv->axis,
+ angle,
priv->center_x,
priv->center_y,
priv->center_z);
c->completed_data = completed_data;
- clutter_actor_set_rotation (actor, angle_start,
- CLUTTER_X_AXIS,
+ clutter_actor_set_rotation (actor, CLUTTER_X_AXIS,
+ angle_start,
0, center_y, center_z);
c->behave = clutter_behaviour_rotate_new (c->alpha,
c->completed_data = completed_data;
- clutter_actor_set_rotation (actor, angle_start,
- CLUTTER_Y_AXIS,
+ clutter_actor_set_rotation (actor, CLUTTER_Y_AXIS,
+ angle_start,
center_x, 0, center_z);
c->behave = clutter_behaviour_rotate_new (c->alpha,
c->completed_data = completed_data;
- clutter_actor_set_rotation (actor, angle_start,
- CLUTTER_Z_AXIS,
+ clutter_actor_set_rotation (actor, CLUTTER_Z_AXIS,
+ angle_start,
center_x, center_y, 0);
c->behave = clutter_behaviour_rotate_new (c->alpha,
gint i;
/* Rotate everything clockwise about stage center*/
- clutter_actor_set_rotation (CLUTTER_ACTOR (oh->group), frame_num,
+ clutter_actor_set_rotation (CLUTTER_ACTOR (oh->group),
CLUTTER_Z_AXIS,
+ frame_num,
CLUTTER_STAGE_WIDTH() / 2,
CLUTTER_STAGE_HEIGHT() / 2,
0);
* FIXME: scaling causes drift so disabled for now. Need rotation
* unit based functions to fix.
*/
- clutter_actor_set_rotation (oh->hand[i], - 6.0 * frame_num,
- CLUTTER_Z_AXIS,
+ clutter_actor_set_rotation (oh->hand[i], CLUTTER_Z_AXIS,
+ - 6.0 * frame_num,
#if 0
(clutter_actor_get_width (oh->hand[i]) / 2) * scale_x,
(clutter_actor_get_height (oh->hand[i]) / 2) * scale_y,
rect = clutter_rectangle_new_with_color (&white);
clutter_actor_set_size (rect, 320, 240);
clutter_actor_set_position (rect, 180, 120);
- clutter_actor_set_rotation (rect, 60, CLUTTER_Y_AXIS, 0, 0, 0);
+ clutter_actor_set_rotation (rect, CLUTTER_Y_AXIS, 60, 0, 0, 0);
clutter_group_add (CLUTTER_GROUP (main_stage), rect);
label = clutter_label_new_with_text ("Mono 8pt", "Drag the blue rectangles");