From 2ddfdbbf0ddf0a1410e4bcb5f5b8bc3836273dcd Mon Sep 17 00:00:00 2001 From: Tazpn <tazpn@users.sourceforge.net> Date: Tue, 14 Apr 2009 03:44:15 +0000 Subject: [PATCH] niflib: add subshapes to hkPackedNiTriStripsData --- include/obj/hkPackedNiTriStripsData.h | 12 ++++++++++++ src/obj/hkPackedNiTriStripsData.cpp | 10 ++++++++++ 2 files changed, 22 insertions(+) diff --git a/include/obj/hkPackedNiTriStripsData.h b/include/obj/hkPackedNiTriStripsData.h index f1aa983c..2fd86f3b 100644 --- a/include/obj/hkPackedNiTriStripsData.h +++ b/include/obj/hkPackedNiTriStripsData.h @@ -109,6 +109,18 @@ public: */ NIFLIB_API virtual void SetVertices( const vector<Vector3> & in ); + /*! + * Retrieves the subshape data object used by this geometry node, if any. + * \return The subshape data object. + */ + NIFLIB_API vector<OblivionSubShape> GetSubShapes() const; + + /*! + * Sets the subshape data object used by this geometry node. + * \param[in] value The subshape data. + */ + NIFLIB_API void SetSubShapes( vector<OblivionSubShape>& value ); + //--END CUSTOM CODE--// protected: /*! Number of triangles? */ diff --git a/src/obj/hkPackedNiTriStripsData.cpp b/src/obj/hkPackedNiTriStripsData.cpp index 4e8aad5e..454dd8fc 100644 --- a/src/obj/hkPackedNiTriStripsData.cpp +++ b/src/obj/hkPackedNiTriStripsData.cpp @@ -253,4 +253,14 @@ void hkPackedNiTriStripsData::SetVertices( const vector<Vector3> & in ) { vertices = in; } +vector<OblivionSubShape> hkPackedNiTriStripsData::GetSubShapes() const { + return subShapes; +} + +void hkPackedNiTriStripsData::SetSubShapes( vector<OblivionSubShape>& value ) { + numSubShapes = value.size(); + subShapes = value; +} + + //--END CUSTOM CODE--// -- GitLab