Update OpenAL-soft to 1.21.1

This commit is contained in:
Miku AuahDark
2021-02-11 18:04:50 +08:00
parent 08f227997e
commit 904cc75ba8
358 changed files with 61122 additions and 60973 deletions
+25
View File
@@ -0,0 +1,25 @@
#include "config.h"
#include "effectslot.h"
#include <stddef.h>
#include "alcontext.h"
#include "almalloc.h"
EffectSlotArray *EffectSlot::CreatePtrArray(size_t count) noexcept
{
/* Allocate space for twice as many pointers, so the mixer has scratch
* space to store a sorted list during mixing.
*/
void *ptr{al_calloc(alignof(EffectSlotArray), EffectSlotArray::Sizeof(count*2))};
return new(ptr) EffectSlotArray{count};
}
EffectSlot::~EffectSlot()
{
if(mWetBuffer)
mWetBuffer->mInUse = false;
}