/// /// \brief /// Get a Havok Physics object space/scalar vector from a Vision vector; taking Vision scaling into account. /// VHAVOK_IMPEXP static HK_FORCE_INLINE void VisVecToPhysVecLocal(const hkvVec3& visV, hkVector4& physV) { physV.load<3, HK_IO_NATIVE_ALIGNED>(&visV.data[0]); physV.zeroComponent<3>(); physV.mul(m_cachedVis2PhysScale); HK_ASSERT(0xdee883, physV.isOk<4>()); }
/// /// \brief /// Get a Havok Physics world space vector from a Vision render space vector; taking Vision scaling into account. /// VHAVOK_IMPEXP static HK_FORCE_INLINE void VisVecToPhysVecWorld(const hkvVec4& visV, hkVector4& physV) { physV.load<4, HK_IO_NATIVE_ALIGNED>(&visV.data[0]); physV.mul(m_cachedVis2PhysScale); physV.add(*m_cachedWorldPivot); HK_ASSERT(0xdee884, physV.isOk<4>()); }
/// /// \brief /// Get a Havok Physics object space/scalar vector from a Vision vector; taking Vision scaling into account. /// VHAVOK_IMPEXP static HK_FORCE_INLINE void VisVecToPhysVecLocal(const hkvVec3d& visV, hkVector4& physV) { /*! Work around, see [SIM-41] */ AlignedArray array(visV); physV.load<3, HK_IO_NATIVE_ALIGNED>(array.m_array); physV.zeroComponent<3>(); physV.mul(m_cachedVis2PhysScale); HK_ASSERT(0xdee883, physV.isOk<4>()); }