#include <Texture.h>
Inheritance diagram for Texture:
Public Member Functions | |
Texture () | |
Texture (HTreeObject *htreeobject) | |
virtual BOOL | Evaluate (const Vector &evalp, HTexInfo *texinfo)=0 |
virtual BOOL | EvaluateTransparency (const Vector &evalp, HTexInfo *texinfo)=0 |
virtual HObjectListNode * | GetPointerList (HPointerPropertyBase *prop) |
virtual void | CheckOut (HHashObject *cache) |
virtual void | OnNotifyNewProperty (HProperty *prop, const String &matchname) |
HModel * | GetModel () |
HGroup * | GetGroup () |
To write a texture plug-in for Animation Master you must derive a class from the Texture class provided in "Texture.h". The derivation should look something like this:
class MyCoolTexture : public Texture;
Once you have declared your new class, you can begin overriding the virtual functions found in the Texture base class or in the DLLPlugin base class. You will need to override nearly every function in the base classs to have a completely functional new texture.
Definition at line 16 of file Texture.h.
|
|
|
|
|
/note Don't use this function. It will be removed in a future version. |
|
Every time a surface is encountered during rendering that has your texture on it, Evaluate is called. This gives you the ability to set what the surface's parameters are. It is important to note that these textures are not "Shaders". The shading is still done after you have returned from Evaluate. You simply get to dictate what the surface is made of.
|
|
When a scene is rendered, it's done in two passes. The first pass determines what is visible, and the second pass shades the visible objects. During this first pass, it is not necessary to evaluate all of the textures. But it is important to know if something is transparent. So for speed's sake, we call another form of the Evaluate funcion, EvaluateTransparency. If your texture has no possible way of setting transparency, simply return TRUE. Otherwise write as little code as it takes to evaluate the transparency at the given evalp.
|
|
Gets to that HGroup where the Texture instance is currently applied to. The returned pointer may be NULL if the Texture is only part of a material or if the Texture is directly applied to the model and not to a group.
|
|
Gets to that HModel where the Texture instance is currently applied to. The returned pointer may be NULL if the Texture is only part of a material.
|
|
When the user clicks on a HPointerProperty inside one of the properties defined by the plugin user interace, this function is called to retrieve the list of pointers to objects in the PWS that will be displayed in the drop-down list.
|
|
If your plugin allows the user to add custom properties, this function will be called the custom property is created, when the project is loaded or when additional instances of the plugin are later created. This allows you to save a poiner to the custom property for quick access when processing. |
Generated on Thu Oct 27 11:47:03 2005 with
1.4.5 written by Dimitri van Heesch,
© 1997-2001