Sfairadora

  • Reference Guide

draw_bitmap

var_bmp <- draw_bitmap(x, y, img)
var_bmp <- draw_bitmap(x, y, img, ix, iy, idx, idy)
var_bmp <- draw_bitmap(x, y, img, ix, iy, idx, idy, mode)
var_bmp <- draw_bitmap(x, y, dx, dy, img)
var_bmp <- draw_bitmap(x, y, dx, dy, img, ix, iy, idx, idy)
var_bmp <- draw_bitmap(x, y, dx, dy, img, ix, iy, idx, idy, mode)
The var_bmp parameter is an l-value referring to a variable of the type Bitmap. The function draws an image specified by the parameter img (the type Bitmap) to the bitmap stored in the variable var_bmp.

Parameters

var_bmp
An l-value of the type Bitmap to which the function draws.
x, y
The coordinates in the var_bmp bitmap where to draw the image.
dx, dy
The size of the rectangle to which is the image to be drawn. These parameters enable resizing the image. If they are not specified, the image is drawn in its original size. If one of the parameters is negative, the image is flipped in that direction.
ix, iy
The coordinates of the upper left corner of a rectangle within the img parameter, which is to be drawn. This enables to draw only a portion of the image specified.
idx, idy
The size of the rectangle within the img parameter that is to be drawn.
mode
One of the bitmap resize mode constants.

Return Value

The return value is an l-value referring to the modified bitmap.

Remarks

The parameters dx and dy enable to resize and flip the image. The parameter ix, iy, idx, and idy enable to draw only a portion of the image specified. If the image drawn overlaps the border of the target bitmap, it is clipped to target bitmap size.

See Also