From e1580128ab2a42ecd4019ef35069f9e939dc4ff2 Mon Sep 17 00:00:00 2001 From: Don Kjer Date: Sun, 9 Sep 2012 12:12:19 +0000 Subject: Fixed crashes on login. Moved most of the remaining character/skeleton generation code into llappearance. Moved non-rendering related LLViewerJoint functionality into LLAvatarJoint. --- indra/llappearance/llavatarjoint.h | 24 ++++++++++++++++++------ 1 file changed, 18 insertions(+), 6 deletions(-) (limited to 'indra/llappearance/llavatarjoint.h') diff --git a/indra/llappearance/llavatarjoint.h b/indra/llappearance/llavatarjoint.h index cbfc1b73ea..1dfbd37456 100644 --- a/indra/llappearance/llavatarjoint.h +++ b/indra/llappearance/llavatarjoint.h @@ -36,6 +36,8 @@ class LLFace; class LLAvatarJointMesh; +extern const F32 DEFAULT_AVATAR_JOINT_LOD; + //----------------------------------------------------------------------------- // class LLViewerJoint //----------------------------------------------------------------------------- @@ -44,6 +46,8 @@ class LLAvatarJoint : { public: LLAvatarJoint(); + LLAvatarJoint(S32 joint_num); + // *TODO: Only used for LLVOAvatarSelf::mScreenp. *DOES NOT INITIALIZE mResetAfterRestoreOldXform* LLAvatarJoint(const std::string &name, LLJoint *parent = NULL); virtual ~LLAvatarJoint(); @@ -55,12 +59,11 @@ public: // Returns true if this object is transparent. // This is used to determine in which order to draw objects. - virtual BOOL isTransparent(); + virtual BOOL isTransparent() { return FALSE; } // Returns true if this object should inherit scale modifiers from its immediate parent virtual BOOL inheritScale() { return FALSE; } - enum Components { SC_BONE = 1, @@ -83,7 +86,7 @@ public: // of this node under the same parent will be. F32 getLOD() { return mMinPixelArea; } void setLOD( F32 pixelArea ) { mMinPixelArea = pixelArea; } - + void setPickName(LLJointPickName name) { mPickName = name; } LLJointPickName getPickName() { return mPickName; } @@ -92,9 +95,18 @@ public: // Takes meshes in mMeshParts and sets each one as a child joint void setMeshesToChildren(); + // LLViewerJoint interface + virtual U32 render( F32 pixelArea, BOOL first_pass = TRUE, BOOL is_dummy = FALSE ) = 0; + virtual void updateFaceSizes(U32 &num_vertices, U32& num_indices, F32 pixel_area); + virtual void updateFaceData(LLFace *face, F32 pixel_area, BOOL damp_wind = FALSE, bool terse_update = false); + virtual BOOL updateLOD(F32 pixel_area, BOOL activate); + virtual void updateJointGeometry(); + virtual void dump(); + + public: static BOOL sDisableLOD; - std::vector mMeshParts; //LLViewerJointMesh* + avatar_joint_mesh_list_t mMeshParts; //LLViewerJointMesh* void setMeshID( S32 id ) {mMeshID = id;} protected: @@ -112,10 +124,10 @@ class LLAvatarJointCollisionVolume : public LLAvatarJoint { public: LLAvatarJointCollisionVolume(); - LLAvatarJointCollisionVolume(const std::string &name, LLJoint *parent = NULL); virtual ~LLAvatarJointCollisionVolume() {}; - virtual BOOL inheritScale() { return TRUE; } + /*virtual*/ BOOL inheritScale() { return TRUE; } + /*virtual*/ U32 render( F32 pixelArea, BOOL first_pass = TRUE, BOOL is_dummy = FALSE ); void renderCollision(); -- cgit v1.2.3