CREATES A SYSTEM OBJECT IMAGE AND ALLOCATES IT NUMBER N AS REFERENCE
ACTION
The command IMAGE N creates a system object IMAGE, and allocates it a number N. An IMAGE is a picture in memory. The number N will be used to designate the IMAGE.
The created IMAGE can then be used through the appropriated commands.
An IMAGE can load a picture in memory (a bitmap file BMP) with command FILE_LOAD.
An IMAGE can load a picture in memory by grabbing the screen with the command 2D_IMAGE_COPY.
An IMAGE can save the picture in memory with command FILE_SAVE.
An IMAGE can display the picture in memory with command 2D_IMAGE_PASTE.
A SPRITE can display the picture from an IMAGE with command SPRITE_IMAGE_LOAD.
A 3D object can take the picture from an IMAGE as a texture with the command 3D_IMAGE_TEXTURE.
SYNTAX:
IMAGE N
USE ERROR EXAMPLE
rem multiply the buttons!
button 1:caption 1,"False button"
top 1,10:left 1,10
image 2
rem grab the screen
2d_image_copy 2,0,0,100,100
rem paste the screen
2d_image_paste 2,80,0
caption 1,"True button"
IMAGE
IMAGE N
SEE ALSO
FILE_LOAD
FILE_SAVE
2D_IMAGE_COPY
2D_IMAGE_PASTE
SPRITE_IMAGE_LOAD
3D_IMAGE_TEXTURE