My Project
|
for a dynamic attribute field. More...
#include <DynamicAttributeField.h>
Public Member Functions | |
CDynamicAttributeField (const std::string &name, DWORD dwType=FieldType_unknown) | |
const std::string & | GetName () const |
void | operator= (const CVariable &val) |
Public Member Functions inherited from ParaEngine::CRefCounted | |
void | addref () const |
add reference count of the object. More... | |
bool | delref () const |
decrease reference count of the object. More... | |
int | GetRefCount () const |
get the reference count | |
virtual int | Release () |
CRefCounted * | AddToAutoReleasePool () |
addref and releases the ownership sometime soon automatically (usually at the end of the current frame). More... | |
Public Member Functions inherited from ParaEngine::CVariable | |
CVariable (DWORD dwType=FieldType_unknown) | |
void | Clone (const CVariable &value) |
clone from given variable | |
const char * | GetTypeName () const |
ATTRIBUTE_FIELDTYPE | GetType () const |
bool | IsNil () const |
bool | IsStringType () const |
bool | IsAnimated () |
whether the key is animated or not | |
void | ChangeType (ATTRIBUTE_FIELDTYPE newType) |
change type to given type | |
void | ToNPLString (std::string &output) |
In case of nil, it is "nil", in case of string, it is in quotation mark. More... | |
void | operator= (const CVariable &val) |
operator double () | |
void | operator= (double value) |
operator float () | |
void | operator= (float value) |
operator int () | |
operator DWORD () | |
void | operator= (int value) |
operator Vector3 () | |
void | operator= (const Vector3 &value) |
operator Quaternion () | |
void | operator= (const Quaternion &value) |
operator bool () | |
void | operator= (bool value) |
operator const string & () | |
operator const char * () | |
bool | operator== (const string &value) |
bool | operator== (const char *value) |
void | operator= (const std::string &value) |
void | operator= (const char *value) |
int | GetNumKeys () |
get total number of animated keys. More... | |
void | SetNumKeys (int nKeyCount) |
get set the total number of animated keys. More... | |
int | AddKey (int nTime, bool *isKeyExist=NULL) |
add a given key with default value at specified time if there is already a key at the index, we will return the old index. More... | |
void | SetTime (int nIndex, int nTime) |
only applied to Animated attribute More... | |
int | GetTime (int nIndex) |
void | SetValue (int nIndex, const Quaternion &val) |
bool | GetValue (int nIndex, Quaternion &val) |
bool | GetValueByTime (int nTime, Quaternion &val) |
get interpolated value at the given time. More... | |
void | SetValue (int nIndex, const Vector3 &val) |
bool | GetValue (int nIndex, Vector3 &val) |
bool | GetValueByTime (int nTime, Vector3 &val) |
void | SetValue (int nIndex, double val) |
bool | GetValue (int nIndex, double &val) |
bool | GetValueByTime (int nTime, double &val) |
void | SetValue (int nIndex, float val) |
bool | GetValue (int nIndex, float &val) |
bool | GetValueByTime (int nTime, float &val) |
void | SetValue (int nIndex, const std::string &val) |
bool | GetValue (int nIndex, std::string &val) |
Public Attributes | |
std::string | m_sName |
Additional Inherited Members | |
Static Public Member Functions inherited from ParaEngine::CVariable | |
static const char * | GetTypeAsString (DWORD dwType) |
Get Type as string. More... | |
Protected Member Functions inherited from ParaEngine::CVariable | |
int | GetNextKeyIndex (int nTime) |
return the index of the first key whose time is larger than or equal to time. More... | |
Protected Attributes inherited from ParaEngine::CRefCounted | |
int | m_refcount |
Protected Attributes inherited from ParaEngine::CVariable | |
DWORD | m_type |
union { | |
double m_doubleVal | |
float m_floatVal | |
int m_intVal | |
bool m_boolVal | |
float m_vector3 [3] | |
float m_vector4 [4] | |
}; | |
IAnimated * | m_pAnimated |
std::string | m_strVal |
for a dynamic attribute field.
dynamic attribute can be created at runtime,which is different from CAttributeField which is compile-time attribute. Dynamic attribute can also be animated or key framed. see also: Animated