diff options
| author | Jonathan "Geenz" Goodman <geenz@geenzo.com> | 2026-08-11 21:39:19 -0400 |
|---|---|---|
| committer | Jonathan "Geenz" Goodman <geenz@geenzo.com> | 2026-08-11 21:39:19 -0400 |
| commit | 8cabc33e960ca93fdc1a32c77cf611269d95d51b (patch) | |
| tree | 931fcecac10bf73214efa07cc3d704ba2bd01272 /indra/llappearance | |
| parent | 9b7ab49575b54523128952af6686d17eb6696725 (diff) | |
| parent | d045f9aa32789a35628aced166145c182751acbf (diff) | |
Merge remote-tracking branch 'origin/develop-linux' into geenz/linux-to-develop
Diffstat (limited to 'indra/llappearance')
| -rw-r--r-- | indra/llappearance/CMakeLists.txt | 11 | ||||
| -rw-r--r-- | indra/llappearance/llavatarappearancedefines.cpp | 4 | ||||
| -rw-r--r-- | indra/llappearance/llavatarappearancedefines.h | 4 | ||||
| -rw-r--r-- | indra/llappearance/llavatarjoint.h | 6 | ||||
| -rw-r--r-- | indra/llappearance/llavatarjointmesh.h | 3 | ||||
| -rw-r--r-- | indra/llappearance/lldriverparam.h | 2 | ||||
| -rw-r--r-- | indra/llappearance/llpolymesh.cpp | 2 | ||||
| -rw-r--r-- | indra/llappearance/llpolymorph.h | 2 | ||||
| -rw-r--r-- | indra/llappearance/llpolyskeletaldistortion.h | 4 | ||||
| -rw-r--r-- | indra/llappearance/lltexlayer.cpp | 25 | ||||
| -rw-r--r-- | indra/llappearance/lltexlayer.h | 2 | ||||
| -rw-r--r-- | indra/llappearance/lltexlayerparams.h | 6 | ||||
| -rw-r--r-- | indra/llappearance/llviewervisualparam.h | 5 |
13 files changed, 57 insertions, 19 deletions
diff --git a/indra/llappearance/CMakeLists.txt b/indra/llappearance/CMakeLists.txt index 6744c8d8a4..5b6d68fa37 100644 --- a/indra/llappearance/CMakeLists.txt +++ b/indra/llappearance/CMakeLists.txt @@ -28,7 +28,7 @@ set(llappearance_SOURCE_FILES llviewervisualparam.cpp llavatarappearancedefines.cpp ) - + set(llappearance_HEADER_FILES CMakeLists.txt @@ -69,6 +69,10 @@ target_link_libraries(llappearance ) target_include_directories( llappearance INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}) +if (USE_PRECOMPILED_HEADERS) + target_precompile_headers(llappearance REUSE_FROM llprecompiled) +endif () + if (BUILD_HEADLESS) add_library (llappearanceheadless ${llappearance_SOURCE_FILES}) target_include_directories( llappearanceheadless INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}) @@ -77,6 +81,7 @@ if (BUILD_HEADLESS) llcharacter llinventory llimage + llrenderheadless llfilesystem llmath llxml @@ -84,4 +89,8 @@ if (BUILD_HEADLESS) llcorehttp llcommon ) + + if (USE_PRECOMPILED_HEADERS) + target_precompile_headers(llappearanceheadless REUSE_FROM llprecompiled) + endif () endif (BUILD_HEADLESS) diff --git a/indra/llappearance/llavatarappearancedefines.cpp b/indra/llappearance/llavatarappearancedefines.cpp index 47798844bc..f26795123f 100644 --- a/indra/llappearance/llavatarappearancedefines.cpp +++ b/indra/llappearance/llavatarappearancedefines.cpp @@ -260,7 +260,7 @@ ETextureIndex LLAvatarAppearanceDictionary::bakedToLocalTextureIndex(EBakedTextu return getBakedTexture(index)->mTextureIndex; } -EBakedTextureIndex LLAvatarAppearanceDictionary::findBakedByRegionName(std::string name) +EBakedTextureIndex LLAvatarAppearanceDictionary::findBakedByRegionName(const std::string& name) const { U8 index = 0; while (index < BAKED_NUM_INDICES) @@ -277,7 +277,7 @@ EBakedTextureIndex LLAvatarAppearanceDictionary::findBakedByRegionName(std::stri return BAKED_NUM_INDICES; } -EBakedTextureIndex LLAvatarAppearanceDictionary::findBakedByImageName(std::string name) +EBakedTextureIndex LLAvatarAppearanceDictionary::findBakedByImageName(const std::string& name) const { U8 index = 0; while (index < BAKED_NUM_INDICES) diff --git a/indra/llappearance/llavatarappearancedefines.h b/indra/llappearance/llavatarappearancedefines.h index 50a72a45a5..0f9edc1ca0 100644 --- a/indra/llappearance/llavatarappearancedefines.h +++ b/indra/llappearance/llavatarappearancedefines.h @@ -238,8 +238,8 @@ public: ETextureIndex bakedToLocalTextureIndex(EBakedTextureIndex t) const; // find a baked texture index based on its name - EBakedTextureIndex findBakedByRegionName(std::string name); - EBakedTextureIndex findBakedByImageName(std::string name); + EBakedTextureIndex findBakedByRegionName(const std::string& name) const; + EBakedTextureIndex findBakedByImageName(const std::string& name) const; // Given a texture entry, determine which wearable type owns it. LLWearableType::EType getTEWearableType(ETextureIndex index) const; diff --git a/indra/llappearance/llavatarjoint.h b/indra/llappearance/llavatarjoint.h index 13f025fd5f..71fe4b61b6 100644 --- a/indra/llappearance/llavatarjoint.h +++ b/indra/llappearance/llavatarjoint.h @@ -41,9 +41,10 @@ extern const F32 DEFAULT_AVATAR_JOINT_LOD; //----------------------------------------------------------------------------- // class LLViewerJoint //----------------------------------------------------------------------------- -class LLAvatarJoint : +class alignas(16) LLAvatarJoint : public LLJoint { + LL_ALIGN_NEW public: LLAvatarJoint(); LLAvatarJoint(S32 joint_num); @@ -121,8 +122,9 @@ protected: S32 mMeshID; }; -class LLAvatarJointCollisionVolume : public LLAvatarJoint +class alignas(16) LLAvatarJointCollisionVolume : public LLAvatarJoint { + LL_ALIGN_NEW public: LLAvatarJointCollisionVolume(); virtual ~LLAvatarJointCollisionVolume() {}; diff --git a/indra/llappearance/llavatarjointmesh.h b/indra/llappearance/llavatarjointmesh.h index 33f50fce00..153a2b88fe 100644 --- a/indra/llappearance/llavatarjointmesh.h +++ b/indra/llappearance/llavatarjointmesh.h @@ -59,8 +59,9 @@ public: //----------------------------------------------------------------------------- // class LLViewerJointMesh //----------------------------------------------------------------------------- -class LLAvatarJointMesh : public virtual LLAvatarJoint +class alignas(16) LLAvatarJointMesh : public virtual LLAvatarJoint { + LL_ALIGN_NEW protected: LLColor4 mColor; // color value // LLColor4 mSpecular; // specular color (always white for now) diff --git a/indra/llappearance/lldriverparam.h b/indra/llappearance/lldriverparam.h index 59092988dd..df8733dde7 100644 --- a/indra/llappearance/lldriverparam.h +++ b/indra/llappearance/lldriverparam.h @@ -128,7 +128,7 @@ protected: void setDrivenWeight(LLDrivenEntry* driven, F32 driven_weight); - LL_ALIGN_16(LLVector4a mDefaultVec); // temp holder + LLVector4a mDefaultVec; // temp holder entry_list_t mDriven; LLViewerVisualParam* mCurrentDistortionParam{ nullptr }; // Backlink only; don't make this an LLPointer. diff --git a/indra/llappearance/llpolymesh.cpp b/indra/llappearance/llpolymesh.cpp index 1162efb868..b93a232419 100644 --- a/indra/llappearance/llpolymesh.cpp +++ b/indra/llappearance/llpolymesh.cpp @@ -280,7 +280,7 @@ bool LLPolyMeshSharedData::loadMesh( const std::string& fileName ) LL_ERRS() << "Filename is Empty!" << LL_ENDL; return false; } - LLFILE* fp = LLFile::fopen(fileName, "rb"); /*Flawfinder: ignore*/ + LLFILE* fp = LLFile::fopen(fileName, LLFILE_MODE("rb")); /*Flawfinder: ignore*/ if (!fp) { LLError::LLUserWarningMsg::showMissingFiles(); diff --git a/indra/llappearance/llpolymorph.h b/indra/llappearance/llpolymorph.h index 8c76689f2c..64434bd5d9 100644 --- a/indra/llappearance/llpolymorph.h +++ b/indra/llappearance/llpolymorph.h @@ -71,7 +71,7 @@ public: private: void freeData(); -} LL_ALIGN_POSTFIX(16); +}; //----------------------------------------------------------------------------- diff --git a/indra/llappearance/llpolyskeletaldistortion.h b/indra/llappearance/llpolyskeletaldistortion.h index 9ba4cf66e9..37f35d50ba 100644 --- a/indra/llappearance/llpolyskeletaldistortion.h +++ b/indra/llappearance/llpolyskeletaldistortion.h @@ -111,13 +111,13 @@ public: protected: LLPolySkeletalDistortion(const LLPolySkeletalDistortion& pOther); - LL_ALIGN_16(LLVector4a mDefaultVec); + LLVector4a mDefaultVec; typedef std::map<LLJoint*, LLVector3> joint_vec_map_t; joint_vec_map_t mJointScales; joint_vec_map_t mJointOffsets; // Backlink only; don't make this an LLPointer. LLAvatarAppearance *mAvatar; -} LL_ALIGN_POSTFIX(16); +}; #endif // LL_LLPOLYSKELETALDISTORTION_H diff --git a/indra/llappearance/lltexlayer.cpp b/indra/llappearance/lltexlayer.cpp index 19e4e8ed9d..5a02dfe716 100644 --- a/indra/llappearance/lltexlayer.cpp +++ b/indra/llappearance/lltexlayer.cpp @@ -435,6 +435,31 @@ const std::string LLTexLayerSet::getBodyRegionName() const return mInfo->mBodyRegion; } +// virtual +void LLTexLayerSet::asLLSD(LLSD& sd) const +{ + sd["visible"] = LLSD::Boolean(isVisible()); + LLSD layer_list_sd; + layer_list_t::const_iterator layer_iter = mLayerList.begin(); + layer_list_t::const_iterator layer_end = mLayerList.end(); + for(; layer_iter != layer_end; ++layer_iter) + { + LLSD layer_sd; + LLTexLayerInterface* layer = (*layer_iter); + if (layer) + { + layer->asLLSD(layer_sd); + } + layer_list_sd.append(layer_sd); + } + LLSD mask_list_sd; + LLSD info_sd; + sd["layers"] = layer_list_sd; + sd["masks"] = mask_list_sd; + sd["info"] = info_sd; +} + + void LLTexLayerSet::destroyComposite() { if( mComposite ) diff --git a/indra/llappearance/lltexlayer.h b/indra/llappearance/lltexlayer.h index 876ea6f600..6b501474d6 100644 --- a/indra/llappearance/lltexlayer.h +++ b/indra/llappearance/lltexlayer.h @@ -220,6 +220,8 @@ public: static bool sHasCaches; + virtual void asLLSD(LLSD& sd) const; + protected: typedef std::vector<LLTexLayerInterface *> layer_list_t; layer_list_t mLayerList; diff --git a/indra/llappearance/lltexlayerparams.h b/indra/llappearance/lltexlayerparams.h index 5e785e4f3e..2c243d0e9b 100644 --- a/indra/llappearance/lltexlayerparams.h +++ b/indra/llappearance/lltexlayerparams.h @@ -30,6 +30,7 @@ #include "llpointer.h" #include "v4color.h" #include "llviewervisualparam.h" +#include <atomic> class LLAvatarAppearance; class LLImageRaw; @@ -62,7 +63,6 @@ protected: // LLTexLayerParamAlpha // //~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -LL_ALIGN_PREFIX(16) class alignas(16) LLTexLayerParamAlpha : public LLTexLayerParam { LL_ALIGN_NEW @@ -102,7 +102,7 @@ private: LLPointer<LLImageRaw> mStaticImageRaw; std::atomic<bool> mNeedsCreateTexture; bool mStaticImageInvalid; - LL_ALIGN_16(LLVector4a mAvgDistortionVec); + LLVector4a mAvgDistortionVec; F32 mCachedEffectiveWeight; public: @@ -112,7 +112,7 @@ public: typedef std::list< LLTexLayerParamAlpha* > param_alpha_ptr_list_t; static param_alpha_ptr_list_t sInstances; -} LL_ALIGN_POSTFIX(16); +}; class LLTexLayerParamAlphaInfo : public LLViewerVisualParamInfo { friend class LLTexLayerParamAlpha; diff --git a/indra/llappearance/llviewervisualparam.h b/indra/llappearance/llviewervisualparam.h index b79983df8e..37771cc8d3 100644 --- a/indra/llappearance/llviewervisualparam.h +++ b/indra/llappearance/llviewervisualparam.h @@ -65,8 +65,7 @@ protected: // VIRTUAL CLASS // a viewer side interface class for a generalized parametric modification of the avatar mesh //----------------------------------------------------------------------------- -LL_ALIGN_PREFIX(16) -class LLViewerVisualParam : public LLVisualParam +class alignas(16) LLViewerVisualParam : public LLVisualParam { public: LLViewerVisualParam(); @@ -107,6 +106,6 @@ public: protected: LLViewerVisualParam(const LLViewerVisualParam& pOther); -} LL_ALIGN_POSTFIX(16); +}; #endif // LL_LLViewerVisualParam_H |
