1stretch_blit(3)                 Allegro manual                 stretch_blit(3)
2
3
4

NAME

6       stretch_blit  -  Scales  a rectangular area from one bitmap to another.
7       Allegro game programming library.
8

SYNOPSIS

10       #include <allegro.h>
11
12
13       void stretch_blit(BITMAP *source, BITMAP *dest, int source_x, source_y,
14       source_width,    source_height,   int   dest_x,   dest_y,   dest_width,
15       dest_height);
16

DESCRIPTION

18       Like blit(), except it can scale images (so the source and  destination
19       rectangles  don't need to be the same size) and requires the source and
20       destination bitmaps to be of the same color depth. This routine doesn't
21       do  as  much  safety  checking as the regular blit(): in particular you
22       must take care not to copy from areas outside the  source  bitmap,  and
23       you cannot blit between overlapping regions, ie. you must use different
24       bitmaps for the source and the destination. Moreover, the  source  must
25       be a memory bitmap. Example:
26
27          BITMAP *bmp;
28          ...
29          /* Stretch bmp to fill the screen. */
30          stretch_blit(bmp, screen, 0, 0, bmp->w, bmp->h,
31                       0, 0, SCREEN_W, SCREEN_H);
32
33

SEE ALSO

35       blit(3),  masked_stretch_blit(3), stretch_sprite(3), exalpha(3), excon‐
36       fig(3), exscale(3), extrans(3)
37
38
39
40Allegro                          version 4.2.3                 stretch_blit(3)
Impressum