Push current work
This commit is contained in:
committed by
Jérôme Leclercq
parent
85cd064171
commit
e5e3026005
@@ -256,7 +256,7 @@ namespace Nz
|
||||
Vector3<T>& OrientedBox<T>::operator()(unsigned int i)
|
||||
{
|
||||
#if NAZARA_MATH_SAFE
|
||||
if (i > BoxCornerCount)
|
||||
if (i >= BoxCornerCount)
|
||||
{
|
||||
std::ostringstream ss;
|
||||
ss << "Index out of range: (" << i << " >= " << BoxCornerCount << ")";
|
||||
@@ -281,7 +281,7 @@ namespace Nz
|
||||
Vector3<T> OrientedBox<T>::operator()(unsigned int i) const
|
||||
{
|
||||
#if NAZARA_MATH_SAFE
|
||||
if (i > BoxCornerCount)
|
||||
if (i >= BoxCornerCount)
|
||||
{
|
||||
std::ostringstream ss;
|
||||
ss << "Index out of range: (" << i << " >= " << BoxCornerCount << ")";
|
||||
|
||||
@@ -21,12 +21,16 @@
|
||||
|
||||
namespace Nz
|
||||
{
|
||||
class Skeleton;
|
||||
|
||||
struct NAZARA_UTILITY_API AnimationParams : ResourceParameters
|
||||
{
|
||||
// La frame de fin à charger
|
||||
std::size_t endFrame = 0xFFFFFFFF;
|
||||
// La frame de début à charger
|
||||
std::size_t startFrame = 0;
|
||||
// Reference skeleton
|
||||
const Skeleton* skeleton = nullptr;
|
||||
|
||||
bool IsValid() const;
|
||||
};
|
||||
@@ -34,7 +38,6 @@ namespace Nz
|
||||
class Animation;
|
||||
struct Sequence;
|
||||
struct SequenceJoint;
|
||||
class Skeleton;
|
||||
|
||||
using AnimationLibrary = ObjectLibrary<Animation>;
|
||||
using AnimationLoader = ResourceLoader<Animation, AnimationParams>;
|
||||
|
||||
@@ -23,9 +23,9 @@ namespace Nz
|
||||
|
||||
struct SequenceJoint
|
||||
{
|
||||
Quaternionf rotation;
|
||||
Vector3f position;
|
||||
Vector3f scale;
|
||||
Quaternionf rotation = Quaternionf::Identity();
|
||||
Vector3f position = Vector3f::Zero();
|
||||
Vector3f scale = Vector3f::Unit();
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
@@ -57,6 +57,8 @@ namespace Nz
|
||||
// Signals:
|
||||
NazaraSignal(OnSkeletonJointsInvalidated, const Skeleton* /*skeleton*/);
|
||||
|
||||
static constexpr std::size_t InvalidJointIndex = std::numeric_limits<std::size_t>::max();
|
||||
|
||||
private:
|
||||
void InvalidateJoints();
|
||||
void InvalidateJointMap();
|
||||
|
||||
Reference in New Issue
Block a user