forked from bartvdbraak/blender
Bugfix T41133: Audio: Speakers with animated pitch cause clicks in rendered animations, crashes or huge filesizes in rendered audio
Crash happened when the pitch value got <= 0, preventing this now.
This commit is contained in:
parent
25fab54e09
commit
31e1a31fee
@ -48,5 +48,7 @@ float AUD_PitchReader::getPitch() const
|
||||
|
||||
void AUD_PitchReader::setPitch(float pitch)
|
||||
{
|
||||
if(pitch <= 0)
|
||||
pitch = 1;
|
||||
m_pitch = pitch;
|
||||
}
|
||||
|
@ -422,6 +422,8 @@ bool AUD_SoftwareDevice::AUD_SoftwareHandle::setPitch(float pitch)
|
||||
{
|
||||
if(!m_status)
|
||||
return false;
|
||||
if(pitch <= 0)
|
||||
pitch = 1;
|
||||
m_user_pitch = pitch;
|
||||
return true;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user