Inexor
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Public Member Functions | Public Attributes | List of all members
animmodel::part Struct Reference

#include <animmodel.hpp>

Inheritance diagram for animmodel::part:
md2::md2part skelmodel::skelpart

Public Member Functions

 part (animmodel *model, int index=0)
 
virtual ~part ()
 
virtual void cleanup ()
 
void calcbb (vec &bbmin, vec &bbmax, const matrix4x3 &m)
 
void genBIH (vector< BIH::mesh > &bih, const matrix4x3 &m)
 
bool link (part *p, const char *tag, const vec &translate=vec(0, 0, 0), int anim=-1, int basetime=0, vec *pos=nullptr)
 
bool unlink (part *p)
 
void initskins (Texture *tex=notexture, Texture *masks=notexture, int limit=0)
 
bool envmapped ()
 
bool tangents ()
 
void preloadBIH ()
 
void preloadshaders (bool force)
 
void preloadmeshes ()
 
virtual void getdefaultanim (animinfo &info, int anim, uint varseed, dynent *d)
 
bool calcanim (int animpart, int anim, int basetime, int basetime2, dynent *d, int interp, animinfo &info, int &aitime)
 
void render (int anim, int basetime, int basetime2, float pitch, const vec &axis, const vec &forward, dynent *d)
 
void render (int anim, int basetime, int basetime2, float pitch, const vec &axis, const vec &forward, dynent *d, animstate *as)
 
void setanim (int animpart, int num, int frame, int range, float speed, int priority=0)
 
virtual void loaded ()
 

Public Attributes

animmodelmodel
 
int index
 
meshgroupmeshes
 
vector< linkedpartlinks
 
vector< skinskins
 
vector< animspec > * anims [MAXANIMPARTS]
 
int numanimparts
 
float pitchscale
 
float pitchoffset
 
float pitchmin
 
float pitchmax
 
vec translate
 

Constructor & Destructor Documentation

animmodel::part::part ( animmodel model,
int  index = 0 
)
inline

References anims, loopk, and MAXANIMPARTS.

virtual animmodel::part::~part ( )
inlinevirtual

References anims, DELETEA, loopk, and MAXANIMPARTS.

Member Function Documentation

bool animmodel::part::calcanim ( int  animpart,
int  anim,
int  basetime,
int  basetime2,
dynent d,
int  interp,
animinfo info,
int &  aitime 
)
inline
void animmodel::part::calcbb ( vec bbmin,
vec bbmax,
const matrix4x3 m 
)
inline
virtual void animmodel::part::cleanup ( )
inlinevirtual
bool animmodel::part::envmapped ( )
inline

References loopv, and skins.

Referenced by render().

void animmodel::part::genBIH ( vector< BIH::mesh > &  bih,
const matrix4x3 m 
)
inline
virtual void animmodel::part::getdefaultanim ( animinfo info,
int  anim,
uint  varseed,
dynent d 
)
inlinevirtual

Reimplemented in md2::md2part.

References animinfo::frame, and animinfo::range.

Referenced by calcanim().

void animmodel::part::initskins ( Texture tex = notexture,
Texture masks = notexture,
int  limit = 0 
)
inline
bool animmodel::part::link ( part p,
const char *  tag,
const vec translate = vec(0, 0, 0),
int  anim = -1,
int  basetime = 0,
vec pos = nullptr 
)
inline
virtual void animmodel::part::loaded ( )
inlinevirtual
void animmodel::part::preloadBIH ( )
inline

References loopv, and skins.

void animmodel::part::preloadmeshes ( )
inline
void animmodel::part::preloadshaders ( bool  force)
inline

References loopv, and skins.

void animmodel::part::render ( int  anim,
int  basetime,
int  basetime2,
float  pitch,
const vec axis,
const vec forward,
dynent d 
)
inline

References MAXANIMPARTS.

Referenced by render(), and animmodel::render().

void animmodel::part::render ( int  anim,
int  basetime,
int  basetime2,
float  pitch,
const vec axis,
const vec forward,
dynent d,
animstate as 
)
inline
void animmodel::part::setanim ( int  animpart,
int  num,
int  frame,
int  range,
float  speed,
int  priority = 0 
)
inline
bool animmodel::part::tangents ( )
inline
bool animmodel::part::unlink ( part p)
inline

References links, loopv, loopvrev, and unlink().

Referenced by unlink().

Member Data Documentation

vector<animspec>* animmodel::part::anims[MAXANIMPARTS]

Referenced by calcanim(), part(), setanim(), and ~part().

int animmodel::part::index

Referenced by animmodel::render().

vector<linkedpart> animmodel::part::links
meshgroup* animmodel::part::meshes
animmodel* animmodel::part::model
int animmodel::part::numanimparts
float animmodel::part::pitchmax
float animmodel::part::pitchmin
float animmodel::part::pitchoffset
float animmodel::part::pitchscale
vector<skin> animmodel::part::skins
vec animmodel::part::translate

The documentation for this struct was generated from the following file: