148 void prepareTempBlendBuffers(
void);
151 void markBuffersUnusedForAnimation(
void);
155 void restoreBuffersForUnusedAnimation(
bool hardwareAnimation);
164 void bindMissingHardwarePoseBuffers(
const VertexData* srcData,
171 bool animateNormals);
187 void updateAnimation(
void);
204 bool cacheBoneMatrices(
void);
280 void detachAllObjectsImpl(
void);
283 void reevaluateVertexProcessing(
void);
291 bool calcVertexProcessing(
void);
294 void applyVertexAnimation(
bool hardwareAnimation,
bool stencilShadows);
298 bool tempVertexAnimBuffersBound(
void)
const;
300 bool tempSkelAnimBuffersBound(
bool requestNormals)
const;
334 bool createSeparateLightCap,
SubEntity* subent,
bool isLightCap =
false);
338 void _createSeparateLightCap();
340 void getWorldTransforms(
Matrix4* xform)
const;
344 void rebindPositionBuffer(
const VertexData* vertexData,
bool force);
346 bool isVisible(
void)
const;
357 const MeshPtr& getMesh(
void)
const;
361 SubEntity* getSubEntity(
unsigned int index)
const;
371 unsigned int getNumSubEntities(
void)
const;
407 void _notifyCurrentCamera(
Camera* cam);
410 void setRenderQueueGroup(
uint8 queueID);
413 void setRenderQueueGroupAndPriority(
uint8 queueID,
ushort priority);
427 const String& getMovableType(
void)
const;
437 bool hasAnimationState(
const String& name)
const;
451 void setDisplaySkeleton(
bool display);
455 bool getDisplaySkeleton(
void)
const;
463 Entity* getManualLodLevel(
size_t index)
const;
470 size_t getNumManualLodLevels(
void)
const;
505 void setMeshLodBias(
Real factor,
ushort maxDetailIndex = 0,
ushort minDetailIndex = 99);
536 void setMaterialLodBias(
Real factor,
ushort maxDetailIndex = 0,
ushort minDetailIndex = 99);
541 void setPolygonModeOverrideable(
bool PolygonModeOverrideable);
582 void detachAllObjectsFromBone(
void);
588 Real getBoundingRadius(
void)
const;
591 const AxisAlignedBox& getWorldBoundingBox(
bool derive =
false)
const;
593 const Sphere& getWorldBoundingSphere(
bool derive =
false)
const;
598 bool hasEdgeList(
void);
603 bool extrudeVertices,
Real extrusionDistance,
unsigned long flags = 0 );
628 bool isHardwareAnimationEnabled(
void);
631 void _notifyAttached(
Node* parent,
bool isTagPoint =
false);
667 void addSoftwareAnimationRequest(
bool normalsAlso);
676 void removeSoftwareAnimationRequest(
bool normalsAlso);
682 void shareSkeletonInstanceWith(
Entity* entity);
686 bool hasVertexAnimation(
void)
const;
691 void stopSharingSkeletonInstance();
713 void refreshAvailableAnimationState(
void);
722 void _updateAnimation(
void);
729 bool _isAnimated(
void)
const;
733 bool _isSkeletonAnimated(
void)
const;
744 VertexData* _getSkelAnimVertexData(
void)
const;
753 VertexData* _getSoftwareVertexAnimVertexData(
void)
const;
758 VertexData* _getHardwareVertexAnimVertexData(
void)
const;
768 uint32 getTypeFlags(
void)
const;
781 VertexDataBindChoice chooseVertexDataForBinding(
bool hasVertexAnim);
787 void _markBuffersUsedForAnimation(
void);
810 void _initialise(
bool forceReinitialise =
false);
812 void _deinitialise(
void);
817 void backgroundLoadingComplete(
Resource* res);
821 bool debugRenderables =
false);
824 Real _getMeshLodFactorTransformed()
const;
830 mSkipAnimStateUpdates = skip;
837 return mSkipAnimStateUpdates;
845 mAlwaysUpdateMainSkeleton = update;
853 return mAlwaysUpdateMainSkeleton;
870 const String& getType(
void)
const;
881 #endif // __Entity_H__
Class encapsulating a set of AnimationState objects.
HardwareVertexBufferSharedPtr getPositionBuffer(void)
A viewpoint from which the scene will be rendered.
vector< SubEntity * >::type SubEntityList
List of SubEntities (point to SubMeshes).
LODEntityList mLodEntityList
Class encapsulating a standard 4x4 homogeneous matrix.
float Real
Software floating point type.
const EntitySet * getSkeletonInstanceSharingSet() const
Returns a pointer to the set of entities which share a SkeletonInstance.
ushort getCurrentLodIndex()
Returns the current LOD used to render.
int mSoftwareAnimationNormalsRequests
Counter indicating number of requests for software blended normals.
ushort mMinMeshLodIndex
Index of minimum detail LOD (NB higher index is lower detail).
SkeletonInstance * getSkeleton(void) const
Get this Entity's personal skeleton instance.
map< String, String >::type NameValuePairList
Name / value parameter pair (first = name, second = value)
bool mVertexAnimationAppliedThisFrame
Have we applied any vertex animation to shared geometry?
SubEntityList mSubEntityList
Structure for recording the use of temporary blend buffers.
bool mCurrentHWAnimationState
Current state of the hardware animation as represented by the entities parameters.
bool isInitialised(void) const
Has this Entity been initialised yet?
TempBlendedBufferInfo mTempVertexAnimInfo
Temp buffer details for software vertex anim of shared geometry.
int getSoftwareAnimationNormalsRequests(void) const
Returns the number of requests that have been made for software animation of normals.
VertexData * mHardwareVertexAnimVertexData
Vertex data details for hardware vertex anim of shared geometry.
Matrix4 mLastParentXform
Last parent transform.
HardwareVertexBufferSharedPtr getWBuffer(void)
bool mInitialised
Has this entity been initialised yet?
static String AUTODETECT_RESOURCE_GROUP_NAME
Special resource group name which causes resource group to be automatically determined based on searc...
map< String, MovableObject * >::type ChildObjectList
Contains the child objects (attached to bones) indexed by name.
static const Vector3 ZERO
vector< Entity * >::type LODEntityList
List of LOD Entity instances (for manual LODs).
Shared pointer implementation used to share vertex buffers.
int mSoftwareAnimationRequests
Counter indicating number of requests for software animation.
A 3D box aligned with the x/y/z axes.
bool mAlwaysUpdateMainSkeleton
Flag indicating whether to update the main entity skeleton even when an LOD is displayed.
VertexDataBindChoice
Identify which vertex data we should be sending to the renderer.
Represents the state of an animation and the weight of its influence.
bool mVertexProgramInUse
Flag indicating whether we have a vertex program in use on any of our subentities.
bool _getBuffersMarkedForAnimation(void) const
Are buffers already marked as vertex animated?
ChildObjectList mChildObjectList
EntitySet * mSharedSkeletonEntities
A set of all the entities which shares a single SkeletonInstance.
int getSoftwareAnimationRequests(void) const
Returns the number of requests that have been made for software animation.
Interface definition for a factory class which produces a certain kind of MovableObject, and can be registered with Root in order to allow all clients to produce new instances of this object, integrated with the standard Ogre processing.
SchemeHardwareAnimMap mSchemeHardwareAnim
Flag indicating whether hardware animation is supported by this entities materials data is saved per ...
size_t mMeshStateCount
Mesh state count, used to detect differences.
Abstract class defining a movable object in a scene.
MapIterator< ChildObjectList > ChildObjectListIterator
bool mPreparedForShadowVolumes
Have the temp buffers already had their geometry prepared for use in rendering shadow volumes...
Implementation of a Quaternion, i.e.
Concrete IteratorWrapper for nonconst access to the underlying key-value container.
unsigned short mOriginalPosBufferBinding
Original position buffer source binding.
bool sharesSkeletonInstance() const
Returns whether this entity shares it's SkeltonInstance with other entity instances.
void setAlwaysUpdateMainSkeleton(bool update)
The skeleton of the main entity will be updated even if the an LOD entity is being displayed...
Shared pointer implementation used to share index buffers.
Representation of a dynamic light source in the scene.
VertexData * mSkelAnimVertexData
Vertex data details for software skeletal anim of shared geometry.
static const Quaternion IDENTITY
ShadowTechnique
An enumeration of broad shadow techniques.
map< unsigned short, bool >::type SchemeHardwareAnimMap
bool mSkipAnimStateUpdates
Flag indicating whether to skip automatic updating of the Skeleton's AnimationState.
Real mMeshLodFactorTransformed
LOD bias factor, transformed for optimisation when calculating adjusted LOD value.
static String FACTORY_TYPE_NAME
Utility class which defines the sub-parts of an Entity.
MeshPtr mMesh
The Mesh that this Entity is based on.
const VertexData * mCurrentVertexData
Link to current vertex data used to bind (maybe changes).
AxisAlignedBox mFullBoundingBox
Bounding box that 'contains' all the mesh of each child entity.
ushort mMaxMaterialLodIndex
Index of maximum detail LOD (NB lower index is higher detail).
Class which represents the renderable aspects of a set of shadow volume faces.
A sphere primitive, mostly used for bounds checking.
Defines an instance of a discrete, movable object based on a Mesh.
Nested class to allow entity shadows.
A tagged point on a skeleton, which can be used to attach entities to on specific other entities...
Visitor object that can be used to iterate over a collection of Renderable instances abstractly...
Real mMaterialLodFactorTransformed
LOD bias factor, transformed for optimisation when calculating adjusted LOD value.
ushort mHardwarePoseCount
Number of hardware poses supported by materials.
const Matrix4 * _getBoneMatrices(void) const
Internal method for retrieving bone matrix information.
unsigned long * mFrameBonesLastUpdated
Records the last frame in which the bones was updated.
Standard 3-dimensional vector.
Abstract class representing a loadable resource (e.g.
bool getSkipAnimationStateUpdate() const
Entity's skeleton's AnimationState will not be automatically updated when set to true.
ushort mMaxMeshLodIndex
Index of maximum detail LOD (NB lower index is higher detail).
Summary class collecting together vertex source information.
TempBlendedBufferInfo mTempSkelAnimInfo
Temp buffer details for software skeletal anim of shared geometry.
bool getAlwaysUpdateMainSkeleton() const
The skeleton of the main entity will be updated even if the an LOD entity is being displayed...
Matrix4 * mBoneMatrices
Cached bone matrices in skeleton local space, might shares with other entity instances.
Matrix4 * mBoneWorldMatrices
Cached bone matrices, including any world transform.
Real mMaterialLodFactor
LOD bias factor, not transformed.
ShadowRenderableList mShadowRenderables
Factory object for creating Entity instances.
Class to manage the scene object rendering queue.
bool mDisplaySkeleton
Flag determines whether or not to display skeleton.
This class contains the information required to describe the edge connectivity of a given set of vert...
HardwareVertexBufferSharedPtr mPositionBuffer
Shared link to position buffer.
VertexData * mSoftwareVertexAnimVertexData
Vertex data details for software vertex anim of shared geometry.
ushort mMeshLodIndex
The LOD number of the mesh to use, calculated by _notifyCurrentCamera.
void setSkipAnimationStateUpdate(bool skip)
Entity's skeleton's AnimationState will not be automatically updated when set to true.
AnimationStateSet * mAnimationState
State of animation for animable meshes.
SkeletonInstance * mSkeletonInstance
This Entity's personal copy of the skeleton, if skeletally animated.
unsigned long mFrameAnimationLastUpdated
Records the last frame in which animation was updated.
Concrete IteratorWrapper for nonconst access to the underlying container.
SubEntity * mSubEntity
Link to SubEntity, only present if SubEntity has it's own geometry.
bool hasSkeleton(void) const
Returns whether or not this entity is skeletally animated.
Class representing a general-purpose node an articulated scene graph.
unsigned short _getNumBoneMatrices(void) const
Internal method for retrieving bone matrix information.
A SkeletonInstance is a single instance of a Skeleton used by a world object.
ushort mMinMaterialLodIndex
Index of minimum detail LOD (NB higher index is lower detail).
HardwareVertexBufferSharedPtr mWBuffer
Shared link to w-coord buffer (optional).
set< Entity * >::type EntitySet
vector< ShadowRenderable * >::type ShadowRenderableList
unsigned short mNumBoneMatrices