#include <W3DModelDraw.h>
Inherits DrawModule, and ObjectDrawInterface.
Inherited by W3DDependencyModelDraw, W3DOverlordAircraftDraw, W3DScienceModelDraw, W3DSupplyDraw, W3DTankDraw, W3DTankTruckDraw, and W3DTruckDraw.
Public Member Functions | |
| W3DModelDraw (Thing *thing, const ModuleData *moduleData) | |
| virtual void | preloadAssets (TimeOfDay timeOfDay) |
| preloading assets | |
| virtual void | doDrawModule (const Matrix3D *transformMtx) |
| the draw method | |
| virtual void | setShadowsEnabled (Bool enable) |
| virtual void | releaseShadows (void) |
| frees all shadow resources used by this module - used by Options screen. | |
| virtual void | allocateShadows (void) |
| create shadow resources if not already present. Used by Options screen. | |
| virtual void | setFullyObscuredByShroud (Bool fullyObscured) |
| virtual void | setTerrainDecal (TerrainDecalType type) |
| virtual Bool | isVisible () const |
| for limiting tree sway, etc to visible objects | |
| virtual void | reactToTransformChange (const Matrix3D *oldMtx, const Coord3D *oldPos, Real oldAngle) |
| virtual void | reactToGeometryChange () |
| virtual Bool | clientOnly_getRenderObjInfo (Coord3D *pos, Real *boundingSphereRadius, Matrix3D *transform) const |
| virtual Bool | clientOnly_getRenderObjBoundBox (OBBoxClass *boundbox) const |
| virtual Bool | clientOnly_getRenderObjBoneTransform (const AsciiString &boneName, Matrix3D *set_tm) const |
| virtual Int | getPristineBonePositionsForConditionState (const ModelConditionFlags &condition, const char *boneNamePrefix, Int startIndex, Coord3D *positions, Matrix3D *transforms, Int maxBones) const |
| virtual Int | getCurrentBonePositions (const char *boneNamePrefix, Int startIndex, Coord3D *positions, Matrix3D *transforms, Int maxBones) const |
| virtual Bool | getCurrentWorldspaceClientBonePositions (const char *boneName, Matrix3D &transform) const |
| virtual Bool | getProjectileLaunchOffset (const ModelConditionFlags &condition, WeaponSlotType wslot, Int specificBarrelToUse, Matrix3D *launchPos, WhichTurretType tur, Coord3D *turretRotPos, Coord3D *turretPitchPos=NULL) const |
| virtual void | updateProjectileClipStatus (UnsignedInt shotsRemaining, UnsignedInt maxShots, WeaponSlotType slot) |
| This will do the show/hide work if ProjectileBoneFeedbackEnabled is set. | |
| virtual void | updateDrawModuleSupplyStatus (Int maxSupply, Int currentSupply) |
| This will do visual feedback on Supplies carried. | |
| virtual void | notifyDrawModuleDependencyCleared () |
| if you were waiting for something before you drew, it's ready now | |
| virtual void | setHidden (Bool h) |
| virtual void | replaceModelConditionState (const ModelConditionFlags &c) |
| virtual void | replaceIndicatorColor (Color color) |
| virtual Bool | handleWeaponFireFX (WeaponSlotType wslot, Int specificBarrelToUse, const FXList *fxl, Real weaponSpeed, const Coord3D *victimPos, Real damageRadius) |
| virtual Int | getBarrelCount (WeaponSlotType wslot) const |
| virtual void | setSelectable (Bool selectable) |
| virtual void | setAnimationLoopDuration (UnsignedInt numFrames) |
| virtual void | setAnimationCompletionTime (UnsignedInt numFrames) |
| virtual void | setPauseAnimation (Bool pauseAnim) |
| virtual void | setAnimationFrame (int frame) |
| virtual void | updateSubObjects () |
| virtual void | showSubObject (const AsciiString &name, Bool show) |
| virtual ObjectDrawInterface * | getObjectDrawInterface () |
| virtual const ObjectDrawInterface * | getObjectDrawInterface () const |
| RenderObjClass * | getRenderObject () |
| virtual Bool | updateBonesForClientParticleSystems (void) |
| this will reposition particle systems on the fly ML | |
| virtual void | onDrawableBoundToObject () |
| virtual void | setTerrainDecalSize (Real x, Real y) |
| virtual void | setTerrainDecalOpacity (Real o) |
Public Member Functions inherited from DrawModule | |
| DrawModule (Thing *thing, const ModuleData *moduleData) | |
| virtual Bool | isLaser () const |
| virtual DebrisDrawInterface * | getDebrisDrawInterface () |
| virtual const DebrisDrawInterface * | getDebrisDrawInterface () const |
| virtual TracerDrawInterface * | getTracerDrawInterface () |
| virtual const TracerDrawInterface * | getTracerDrawInterface () const |
| virtual RopeDrawInterface * | getRopeDrawInterface () |
| virtual const RopeDrawInterface * | getRopeDrawInterface () const |
| virtual LaserDrawInterface * | getLaserDrawInterface () |
| virtual const LaserDrawInterface * | getLaserDrawInterface () const |
Public Member Functions inherited from DrawableModule | |
| DrawableModule (Thing *thing, const ModuleData *moduleData) | |
| < this abstract class needs memory pool hooks | |
Public Member Functions inherited from Module | |
| Module (const ModuleData *moduleData) | |
| < this abstract class needs memory pool hooks | |
| virtual NameKeyType | getModuleNameKey () const =0 |
| NameKeyType | getModuleTagNameKey () const |
| virtual void | onObjectCreated () |
| virtual void | onDelete (void) |
Public Member Functions inherited from MemoryPoolObject | |
| void | deleteInstance () |
Public Member Functions inherited from Snapshot | |
| Snapshot (void) | |
| ~Snapshot (void) | |
Additional Inherited Members | |
Static Public Member Functions inherited from DrawModule | |
| static ModuleType | getModuleType () |
| static Int | getInterfaceMask () |
Static Public Member Functions inherited from Module | |
| static ModuleData * | friend_newModuleData (INI *ini) |
Definition at line 340 of file W3DModelDraw.h.
| W3DModelDraw::W3DModelDraw | ( | Thing * | thing, |
| const ModuleData * | moduleData ) |
Definition at line 1720 of file W3DModelDraw.cpp.
|
protectedvirtual |
Reimplemented in W3DDependencyModelDraw.
Definition at line 1994 of file W3DModelDraw.cpp.
|
virtual |
create shadow resources if not already present. Used by Options screen.
Create shadow resources if not already present. This is used to dynamically enable/disable shadows by the options screen
Implements DrawModule.
Definition at line 1853 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3537 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3516 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3236 of file W3DModelDraw.cpp.
|
virtual |
the draw method
Implements DrawModule.
Reimplemented in W3DDependencyModelDraw, W3DOverlordAircraftDraw, W3DOverlordTankDraw, W3DOverlordTruckDraw, W3DPoliceCarDraw, W3DScienceModelDraw, W3DTankDraw, W3DTankTruckDraw, and W3DTruckDraw.
Definition at line 2040 of file W3DModelDraw.cpp.
|
protected |
Definition at line 2342 of file W3DModelDraw.cpp.
|
protected |
Definition at line 3683 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3689 of file W3DModelDraw.cpp.
|
protected |
Definition at line 2256 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3569 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3555 of file W3DModelDraw.cpp.
|
inlineprotected |
Definition at line 437 of file W3DModelDraw.h.
|
inlineprotected |
Definition at line 452 of file W3DModelDraw.h.
|
inlinevirtual |
Reimplemented from DrawModule.
Definition at line 422 of file W3DModelDraw.h.
|
inlinevirtual |
Reimplemented from DrawModule.
Definition at line 423 of file W3DModelDraw.h.
|
virtual |
Find the bone(s) with the given name and return their positions and/or transforms in the given arrays. We look for a bone named "boneNamePrefixQQ", where QQ is 01, 02, 03, etc, starting at the value of "startIndex". Want to look for just a specific boneName with no numeric suffix? just pass zero (0) for startIndex. (no, we never look for "boneNamePrefix00".) We copy up to 'maxBones' into the array(s), and return the total count found.
NOTE: this returns the positions and transform for the "ideal" model... that is, at its default rotation and scale, located at (0,0,0). You'll have to concatenate an Object's position and transform onto these in order to move 'em into "world space"!
NOTE: this isn't very fast. Please call it sparingly and cache the result.
Implements ObjectDrawInterface.
Definition at line 3403 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3253 of file W3DModelDraw.cpp.
|
inline |
Definition at line 426 of file W3DModelDraw.h.
|
protected |
Definition at line 2491 of file W3DModelDraw.cpp.
|
protected |
Definition at line 2415 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3696 of file W3DModelDraw.cpp.
|
virtual |
for limiting tree sway, etc to visible objects
Reimplemented from DrawModule.
Definition at line 3916 of file W3DModelDraw.cpp.
|
inlinevirtual |
if you were waiting for something before you drew, it's ready now
Implements ObjectDrawInterface.
Reimplemented in W3DDependencyModelDraw.
Definition at line 382 of file W3DModelDraw.h.
|
virtual |
this is called whenever a drawable is bound to the object. drawable is NOT guaranteed to be non-null.
Reimplemented from Module.
Definition at line 1782 of file W3DModelDraw.cpp.
|
inlineprotectedvirtual |
Reimplemented in W3DTankDraw, W3DTankTruckDraw, and W3DTruckDraw.
Definition at line 435 of file W3DModelDraw.h.
|
virtual |
preloading assets
Preload any assets for the time of day requested
Reimplemented from Module.
Definition at line 3907 of file W3DModelDraw.cpp.
|
inlinevirtual |
Implements DrawModule.
Reimplemented in W3DSupplyDraw, W3DTankTruckDraw, and W3DTruckDraw.
Definition at line 370 of file W3DModelDraw.h.
|
virtual |
Implements DrawModule.
Definition at line 3649 of file W3DModelDraw.cpp.
|
protected |
Definition at line 2589 of file W3DModelDraw.cpp.
|
virtual |
frees all shadow resources used by this module - used by Options screen.
Free all data used by this model's shadow. This is used to dynamically enable/disable shadows by the options screen
Implements DrawModule.
Definition at line 1845 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3212 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3184 of file W3DModelDraw.cpp.
|
virtual |
similar to the above, but assumes that the current state is a "ONCE", and is smart about transition states... if there is a transition state "inbetween", it is included in the completion time.
Implements ObjectDrawInterface.
Definition at line 3799 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3821 of file W3DModelDraw.cpp.
|
virtual |
This call says, "I want the current animation (if any) to take n frames to complete a single cycle". If it's a looping anim, each loop will take n frames. someday, we may want to add the option to insert "pad" frames at the start and/or end, but for now, we always just "stretch" the animation to fit. Note that you must call this AFTER setting the condition codes.
Implements ObjectDrawInterface.
Definition at line 3772 of file W3DModelDraw.cpp.
Definition at line 2234 of file W3DModelDraw.cpp.
|
virtual |
collect some stats about the rendering cost of this draw module recurse through sub-objs to collect stats about the rendering cost of this draw module
Implements DrawModule.
Reimplemented in W3DTankDraw, W3DTankTruckDraw, and W3DTruckDraw.
Definition at line 1939 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Reimplemented in W3DOverlordAircraftDraw, W3DOverlordTankDraw, W3DOverlordTruckDraw, W3DTankDraw, W3DTankTruckDraw, and W3DTruckDraw.
Definition at line 1823 of file W3DModelDraw.cpp.
|
protected |
Change the model for this drawable. If color is non-zero, it will also apply team color to the model
Definition at line 2911 of file W3DModelDraw.cpp.
|
virtual |
This call is used to pause or resume an animation.
Implements ObjectDrawInterface.
Definition at line 3833 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3196 of file W3DModelDraw.cpp.
|
virtual |
Implements DrawModule.
Definition at line 1880 of file W3DModelDraw.cpp.
|
virtual |
Reimplemented from DrawModule.
Definition at line 2731 of file W3DModelDraw.cpp.
|
virtual |
Reimplemented from DrawModule.
Definition at line 2777 of file W3DModelDraw.cpp.
Reimplemented from DrawModule.
Definition at line 2769 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 1308 of file W3DModelDraw.cpp.
|
protected |
Definition at line 2385 of file W3DModelDraw.cpp.
|
virtual |
this will reposition particle systems on the fly ML
Implements ObjectDrawInterface.
Definition at line 2677 of file W3DModelDraw.cpp.
This will do visual feedback on Supplies carried.
Implements ObjectDrawInterface.
Reimplemented in W3DSupplyDraw.
Definition at line 3931 of file W3DModelDraw.cpp.
|
virtual |
This will do the show/hide work if ProjectileBoneFeedbackEnabled is set.
Implements ObjectDrawInterface.
Definition at line 3922 of file W3DModelDraw.cpp.
|
virtual |
Implements ObjectDrawInterface.
Definition at line 3978 of file W3DModelDraw.cpp.