int BitmapSetImage(int bi, int im);

 

Draws a loaded Image on a Bitmap surface.

 

Return Value

 

Return value not used.

 

Parameters

 

bi

Handle to the Bitmap surface (from BitmapAdd()) to receive the Image.

 

im

Handle to the Image (from ImageAdd()) to draw on the Bitmap surface.

 

Remarks

 

BitmapSetImage() draws an Image loaded with ImageAdd() on a Bitmap's surface.  After calling this function, be sure to call BitmapUpdate() when you are ready for the Bitmap surface to be rendered.

 

NOTE: The Image will not be drawn if it is larger (in terms of height an width) than the Bitmap surface created in BitmapAdd().

 

Availability

 

Available in DragonFireSDK 1.3 and later.

 

Example

 

The following example creates a 100 x 100 Bitmap surface and loads the Image of a ball onto its surface.

 

#include "DragonFireSDK.h"

 

int MyBitmap;

int MyImage;

 

void AppMain()

{  

  MyBitmap = BitmapAdd(0, 0, 100, 100);

  MyImage = ImageAdd("Images/Ball.png");

  BitmapSetImage(MyBitmap, MyImage);

}

 

void AppExit()

{

 

}

 

void OnTimer()

{

 

}