Class representing a model. More...
Public Member Functions | |
BasicModel (string fileName, int index=0) | |
Creates a model (from a file) | |
BasicModel (byte[] fileImage, int index=0) | |
Creates a model (from a file image) | |
void | Dispose () |
Frees unmanaged resources of a model. | |
void | BindPrograms (BasicProgramContainer container) |
Links a program to a model. | |
void | BindTextures (BasicTextureContainer container) |
Links a texture to a model. | |
void | SetWorldMatrix (ref Matrix4 world) |
Sets a world matrix. | |
void | SetCurrentMotion (int index, float delay=0.0f) |
Sets the current motion. | |
void | Animate (float step) |
Calculates the model animation. | |
void | Update () |
Updates the model matrix. | |
void | Draw (GraphicsContext graphics) |
Renders a model. | |
void | Draw (GraphicsContext graphics, BasicProgram program) |
Renders a model (with the specified program) | |
Public Attributes | |
string | Name |
Model name. | |
Vector4 | BoundingSphere |
Bounding sphere. | |
Matrix4 | WorldMatrix |
World matrix. | |
int | CurrentMotion |
Current motion number. | |
float | TransitionDelay |
Motion transition delay time (units = seconds) | |
BasicBone[] | Bones |
Bone array included in a model. | |
BasicPart[] | Parts |
Part array included in a model. | |
BasicMaterial[] | Materials |
Material array included in a model. | |
BasicTexture[] | Textures |
Texture array included in a model. | |
BasicMotion[] | Motions |
Motion array included in a model. | |
BasicProgram[] | Programs |
Program array included in a model. |
Class representing a model.
BasicModel | ( | string | fileName, |
int | index = 0 |
||
) |
Creates a model (from a file)
fileName | Filename |
index | Model number in a file |
BasicModel | ( | byte[] | fileImage, |
int | index = 0 |
||
) |
Creates a model (from a file image)
fileImage | File image |
index | Model number in a file |
void Animate | ( | float | step | ) |
Calculates the model animation.
step | Step time (unit = s) |
void BindPrograms | ( | BasicProgramContainer | container | ) |
Links a program to a model.
container | Program Container |
void BindTextures | ( | BasicTextureContainer | container | ) |
Links a texture to a model.
container | Texture Container |
void Draw | ( | GraphicsContext | graphics | ) |
Renders a model.
graphics | Graphics Context |
void Draw | ( | GraphicsContext | graphics, |
BasicProgram | program | ||
) |
Renders a model (with the specified program)
graphics | Graphics Context |
program | Specified program |
void SetCurrentMotion | ( | int | index, |
float | delay = 0.0f |
||
) |
Sets the current motion.
index | Motion number |
delay | Delay time (unit = s) |
void SetWorldMatrix | ( | ref Matrix4 | world | ) |
Sets a world matrix.
world | World matrix |