diff --git a/include/obj/NiBSplineData.h b/include/obj/NiBSplineData.h index 906f2e2a5a8362febaddfb52fb439346cd8ceba3..3372eeba414817aca52eea754dc5b4d345f1d7b5 100644 --- a/include/obj/NiBSplineData.h +++ b/include/obj/NiBSplineData.h @@ -60,6 +60,18 @@ public: */ NIFLIB_API vector<float> GetFloatControlPoints() const; + /*! + * Sets the float control points representing the spline data + * \param[in] The new float control points to replace the current ones + */ + NIFLIB_API void SetFloatControlPoints(vector<float> value); + + /*! + * Adds float control points at the end of the float control points collection + * \param[in] The float points to add at the end of the collection + */ + NIFLIB_API void AppendFloatControlPoints(vector<float> value); + /*! * Get Range of signed shorts representing the data scaled by SHRT_MAX. * \param[in] offset The start of the range. @@ -74,6 +86,18 @@ public: */ NIFLIB_API vector<short> GetShortControlPoints() const; + /*! + * Sets the short control points representing the spline data + * \param[in] The new short control points to replace the current ones + */ + NIFLIB_API void SetShortControlPoints(vector<short> value); + + /*! + * Adds short control points at the end of the short control points collection + * \param[in] The short points to add at the end of the collection + */ + NIFLIB_API void AppendShortControlPoints(vector<short> value); + /*! * Get Range of signed shorts representing the data scaled by SHRT_MAX. * \param[in] offset The start of the range. diff --git a/include/obj/NiBSplineTransformInterpolator.h b/include/obj/NiBSplineTransformInterpolator.h index 4c1a3f13d00f8b3d37edf62ddc0c5ee9b6f7c263..b255e9d53957c34ca8ea13a02d0402adfa0b3789 100644 --- a/include/obj/NiBSplineTransformInterpolator.h +++ b/include/obj/NiBSplineTransformInterpolator.h @@ -66,6 +66,18 @@ public: */ NIFLIB_API void SetTranslation( Vector3 value ); + /*! + * Gets the translation offset for the control points in the NiSplineData + * \return The translation offset + */ + NIFLIB_API int GetTranslationOffset(); + + /*! + * Sets the translation offset for the control points in the NiSplineData + * \param[in] The new translation offset + */ + NIFLIB_API void SetTranslationOffset( int value ); + /*! * Gets the base rotation when a translate curve is not defined. * \return The base rotation. @@ -78,6 +90,18 @@ public: */ NIFLIB_API void SetRotation( Quaternion value ); + /*! + * Gets the rotation offset for the control points in the NiSplineData + * \return The rotation offset + */ + NIFLIB_API int GetRotationOffset(); + + /*! + * Sets the rotation offset for the control points in the NiSplineData + * \param[in] The new rotation offset + */ + NIFLIB_API void SetRotationOffset( int value ); + /*! * Gets the base scale when a translate curve is not defined. * \return The base scale. @@ -90,6 +114,18 @@ public: */ NIFLIB_API void SetScale( float value ); + /*! + * Gets the scale offset for the control points in the NiSplineData + * \return The scale offset + */ + NIFLIB_API int GetScaleOffset(); + + /*! + * Sets the scale offset for the control points in the NiSplineData + * \param[in] The new scale offset + */ + NIFLIB_API void SetScaleOffset( int value ); + /*! * Retrieves the control quaternion rotation data. diff --git a/src/obj/NiBSplineData.cpp b/src/obj/NiBSplineData.cpp index 21aa5e55ac726d004360ac2a66f0fecf1bf88445..bd11443889826fb6d36707365e2c4117f1471bf4 100644 --- a/src/obj/NiBSplineData.cpp +++ b/src/obj/NiBSplineData.cpp @@ -190,7 +190,7 @@ void NiBSplineData::SetShortControlPoints( vector<short> value ) this->numShortControlPoints = value.size(); for(int i = 0; i < value.size(); i++) { - this->shortControlPoints.push_back(value); + this->shortControlPoints.push_back(value[i]); } }