csProcTexture Class Reference
Generic superclass for procedural textures. More...
#include <cstool/proctex.h>
Inheritance diagram for csProcTexture:

Public Member Functions | |
virtual void | Animate (csTicks current_time)=0 |
Animate this texture. | |
void | DisableAutoUpdate () |
Disable auto-update. | |
virtual void | GetDimension (int &w, int &h) const |
get dimension | |
iGraphics2D * | GetG2D () |
iGraphics3D * | GetG3D () |
iTextureWrapper * | GetTextureWrapper () |
Get the texture corresponding with this procedural texture. | |
iMaterialWrapper * | Initialize (iObjectRegistry *object_reg, iEngine *engine, iTextureManager *txtmgr, const char *name) |
Initialize this procedural texture, create a material associated with it, properly register the texture and material and prepare them. | |
virtual bool | Initialize (iObjectRegistry *object_reg) |
Do everything needed to initialize this texture. | |
virtual bool | PrepareAnim () |
Prepare the animation for use. | |
void | SetKeyColor (int red, int green, int blue) |
Set the key color to use for this texture. | |
Static Public Member Functions | |
static int | GetRandom (int max) |
Public Attributes | |
csTicks | last_cur_time |
Protected Attributes | |
bool | always_animate |
bool | anim_prepared |
csRef< iGraphics2D > | g2d |
csRef< iGraphics3D > | g3d |
int | key_blue |
bool | key_color |
int | key_green |
int | key_red |
int | mat_h |
int | mat_w |
iObjectRegistry * | object_reg |
csRef< iImage > | proc_image |
bool | ptReady |
iTextureWrapper * | tex |
int | texFlags |
bool | use_cb |
bool | visible |
Friends | |
struct | csProcTexCallback |
class | csProcTexEventHandler |
struct | eiProcTexture |
struct | eiTextureWrapper |
Classes | |
struct | eiProcTexture |
struct | eiTextureWrapper |
Detailed Description
Generic superclass for procedural textures.This class takes care of scheduling when a procedural texture needs updating.
Definition at line 57 of file proctex.h.
Member Function Documentation
|
Animate this texture. Subclasses of csProcTexture must implement this to implement some kind of animation on the procedural texture. Implemented in csProcAnimated. |
|
Disable auto-update. By default csProcTexture will register a callback so that every time the texture is visible Animate will automatically be called. If you don't want this and you want to call Animate on your own then you can disable this feature. You need to call DisableAutoUpdate() before calling Initialize(). |
|
get dimension
|
|
Get the texture corresponding with this procedural texture.
|
|
Initialize this procedural texture, create a material associated with it, properly register the texture and material and prepare them. This function assumes that the texture manager has already been set up. It is a convenience function that offers less flexibility but is sufficient for most cases. The texture and material will get the name that is given by this routine. |
|
Do everything needed to initialize this texture. At this stage only will settings like the key color be used. The correct init sequence is: Alternatively you can use Initialize(engine,name) which does all this work for you. |
|
Prepare the animation for use.
Reimplemented in csProcAnimated. |
|
Set the key color to use for this texture.
|
The documentation for this class was generated from the following file:
- cstool/proctex.h
Generated for Crystal Space by doxygen 1.4.4