Fix #110336 Regression: Speaker ignoring of the starting position in NLA track

Porting fix from upstream:

Bugfix for reading an animated property with a negative time value.

This can now happen in SequenceHandle::seek.
This commit is contained in:
Jörg Müller 2023-07-24 16:20:42 +02:00
parent 47cc5787a6
commit 7c3a779bc2

@ -184,6 +184,12 @@ void AnimateableProperty::read(float position, float* out)
t = 0;
}
if(position < 0)
{
position = 0;
t = 0;
}
if(t == 0)
{
std::memcpy(out, getBuffer() + int(std::floor(position)) * m_count, m_count * sizeof(float));