Torque 3D - Script Manual: GuiChunkedBitmapCtrl Class Reference

TorqueScript

Main   Class List   Namespace List   Online

GuiChunkedBitmapCtrl Class Reference
[Image and Video Controls]

This is a control that will render a specified bitmap or a bitmap specified in a referenced variable. More...

Inheritance diagram for GuiChunkedBitmapCtrl:

List of all members.

Public Member Functions

void setBitmap (string filename)
 Set the image rendered in this control.

Public Attributes

GuiChunkedBitmapCtrl

filename bitmap
 This is the bitmap to render to the control.
bool tile
 This is no longer in use.
bool useVariable
 This decides whether to use the "bitmap" file or a bitmap stored in "variable".

Detailed Description

This is a control that will render a specified bitmap or a bitmap specified in a referenced variable.

This control allows you to either set a bitmap with the "bitmap" field or with the setBitmap method. You can also choose to reference a variable in the "variable" field such as "$image" and then set "useVariable" to true. This will cause it to synchronize the variable with the bitmap displayed (if the variable holds a valid image). You can then change the variable and effectively changed the displayed image.

Example:
$image = "anotherbackground.png";
new GuiChunkedBitmapCtrl(ChunkedBitmap)
{
   bitmap = "background.png";
   variable = "$image";
   useVariable = false;
}

// This will result in the control rendering "background.png"
// If we now set the useVariable to true it will now render "anotherbackground.png"
ChunkedBitmap.useVariable = true;
See also:
GuiControl::variable

Member Function Documentation

void GuiChunkedBitmapCtrl::setBitmap ( string  filename  ) 

Set the image rendered in this control.

Parameters:
filename The image name you want to set
Example:
ChunkedBitmap.setBitmap("images/background.png");

Member Data Documentation

This is the bitmap to render to the control.

This is no longer in use.

This decides whether to use the "bitmap" file or a bitmap stored in "variable".



Copyright © GarageGames, LLC. All Rights Reserved.