1rotate_sprite(3) Allegro manual rotate_sprite(3)
2
3
4
6 rotate_sprite - Rotates a sprite. Allegro game programming library.
7
9 #include <allegro.h>
10
11
12 void rotate_sprite(BITMAP *bmp, BITMAP *sprite, int x, int y, fixed
13 angle);
14
16 Draws the sprite image onto the bitmap. It is placed with its top left
17 corner at the specified position, then rotated by the specified angle
18 around its centre. The angle is a fixed point 16.16 number in the same
19 format used by the fixed point trig routines, with 256 equal to a full
20 circle, 64 a right angle, etc. All rotation functions can draw between
21 any two bitmaps, even screen bitmaps or bitmaps of different color
22 depth.
23
24 Positive increments of the angle will make the sprite rotate clockwise
25 on the screen, as demonstrated by the Allegro example.
26
27
29 draw_sprite(3), rotate_scaled_sprite(3), rotate_sprite_v_flip(3),
30 rotate_scaled_sprite_v_flip(3), pivot_sprite(3),
31 pivot_sprite_v_flip(3), pivot_scaled_sprite(3),
32 pivot_scaled_sprite_v_flip(3), itofix(3), exsprite(3)
33
34
35
36Allegro version 4.2.2 rotate_sprite(3)