Change all of channel numbers and number of frames
to size_t
This commit is contained in:
parent
7243e7aaa0
commit
78a4a63459
6 changed files with 44 additions and 44 deletions
|
|
@ -42,7 +42,7 @@ namespace sfz
|
||||||
* @tparam MaxChannels the maximum number of channels in the buffer
|
* @tparam MaxChannels the maximum number of channels in the buffer
|
||||||
* @tparam Alignment the alignment for the buffers
|
* @tparam Alignment the alignment for the buffers
|
||||||
*/
|
*/
|
||||||
template <class Type, int MaxChannels = sfz::config::numChannels, unsigned int Alignment = SIMDConfig::defaultAlignment>
|
template <class Type, size_t MaxChannels = sfz::config::numChannels, unsigned int Alignment = SIMDConfig::defaultAlignment>
|
||||||
class AudioBuffer {
|
class AudioBuffer {
|
||||||
public:
|
public:
|
||||||
using value_type = std::remove_cv_t<Type>;
|
using value_type = std::remove_cv_t<Type>;
|
||||||
|
|
@ -50,7 +50,6 @@ public:
|
||||||
using const_pointer = const value_type*;
|
using const_pointer = const value_type*;
|
||||||
using iterator = pointer;
|
using iterator = pointer;
|
||||||
using const_iterator = const_pointer;
|
using const_iterator = const_pointer;
|
||||||
using size_type = size_t;
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Construct a new Audio Buffer object
|
* @brief Construct a new Audio Buffer object
|
||||||
|
|
@ -67,7 +66,7 @@ public:
|
||||||
* @param numChannels
|
* @param numChannels
|
||||||
* @param numFrames
|
* @param numFrames
|
||||||
*/
|
*/
|
||||||
AudioBuffer(int numChannels, int numFrames)
|
AudioBuffer(size_t numChannels, size_t numFrames)
|
||||||
: numChannels(numChannels)
|
: numChannels(numChannels)
|
||||||
, numFrames(numFrames)
|
, numFrames(numFrames)
|
||||||
{
|
{
|
||||||
|
|
@ -82,7 +81,7 @@ public:
|
||||||
* @return true if the resize worked
|
* @return true if the resize worked
|
||||||
* @return false otherwise
|
* @return false otherwise
|
||||||
*/
|
*/
|
||||||
bool resize(size_type newSize)
|
bool resize(size_t newSize)
|
||||||
{
|
{
|
||||||
bool returnedOK = true;
|
bool returnedOK = true;
|
||||||
|
|
||||||
|
|
@ -101,7 +100,7 @@ public:
|
||||||
* @param channelIndex
|
* @param channelIndex
|
||||||
* @return iterator
|
* @return iterator
|
||||||
*/
|
*/
|
||||||
iterator channelWriter(int channelIndex)
|
iterator channelWriter(size_t channelIndex)
|
||||||
{
|
{
|
||||||
ASSERT(channelIndex < numChannels)
|
ASSERT(channelIndex < numChannels)
|
||||||
if (channelIndex < numChannels)
|
if (channelIndex < numChannels)
|
||||||
|
|
@ -116,7 +115,7 @@ public:
|
||||||
* @param channelIndex
|
* @param channelIndex
|
||||||
* @return iterator
|
* @return iterator
|
||||||
*/
|
*/
|
||||||
iterator channelWriterEnd(int channelIndex)
|
iterator channelWriterEnd(size_t channelIndex)
|
||||||
{
|
{
|
||||||
ASSERT(channelIndex < numChannels)
|
ASSERT(channelIndex < numChannels)
|
||||||
if (channelIndex < numChannels)
|
if (channelIndex < numChannels)
|
||||||
|
|
@ -131,7 +130,7 @@ public:
|
||||||
* @param channelIndex
|
* @param channelIndex
|
||||||
* @return const_iterator
|
* @return const_iterator
|
||||||
*/
|
*/
|
||||||
const_iterator channelReader(int channelIndex) const
|
const_iterator channelReader(size_t channelIndex) const
|
||||||
{
|
{
|
||||||
ASSERT(channelIndex < numChannels)
|
ASSERT(channelIndex < numChannels)
|
||||||
if (channelIndex < numChannels)
|
if (channelIndex < numChannels)
|
||||||
|
|
@ -146,7 +145,7 @@ public:
|
||||||
* @param channelIndex
|
* @param channelIndex
|
||||||
* @return const_iterator
|
* @return const_iterator
|
||||||
*/
|
*/
|
||||||
const_iterator channelReaderEnd(int channelIndex) const
|
const_iterator channelReaderEnd(size_t channelIndex) const
|
||||||
{
|
{
|
||||||
ASSERT(channelIndex < numChannels)
|
ASSERT(channelIndex < numChannels)
|
||||||
if (channelIndex < numChannels)
|
if (channelIndex < numChannels)
|
||||||
|
|
@ -161,7 +160,7 @@ public:
|
||||||
* @param channelIndex
|
* @param channelIndex
|
||||||
* @return absl::Span<value_type>
|
* @return absl::Span<value_type>
|
||||||
*/
|
*/
|
||||||
absl::Span<value_type> getSpan(int channelIndex) const
|
absl::Span<value_type> getSpan(size_t channelIndex) const
|
||||||
{
|
{
|
||||||
ASSERT(channelIndex < numChannels)
|
ASSERT(channelIndex < numChannels)
|
||||||
if (channelIndex < numChannels)
|
if (channelIndex < numChannels)
|
||||||
|
|
@ -176,7 +175,7 @@ public:
|
||||||
* @param channelIndex
|
* @param channelIndex
|
||||||
* @return absl::Span<const value_type>
|
* @return absl::Span<const value_type>
|
||||||
*/
|
*/
|
||||||
absl::Span<const value_type> getConstSpan(int channelIndex) const
|
absl::Span<const value_type> getConstSpan(size_t channelIndex) const
|
||||||
{
|
{
|
||||||
return getSpan(channelIndex);
|
return getSpan(channelIndex);
|
||||||
}
|
}
|
||||||
|
|
@ -194,9 +193,9 @@ public:
|
||||||
/**
|
/**
|
||||||
* @brief Get the number of elements in each buffer
|
* @brief Get the number of elements in each buffer
|
||||||
*
|
*
|
||||||
* @return size_type
|
* @return size_t
|
||||||
*/
|
*/
|
||||||
size_type getNumFrames() const
|
size_t getNumFrames() const
|
||||||
{
|
{
|
||||||
return numFrames;
|
return numFrames;
|
||||||
}
|
}
|
||||||
|
|
@ -206,7 +205,7 @@ public:
|
||||||
*
|
*
|
||||||
* @return int
|
* @return int
|
||||||
*/
|
*/
|
||||||
int getNumChannels() const
|
size_t getNumChannels() const
|
||||||
{
|
{
|
||||||
return numChannels;
|
return numChannels;
|
||||||
}
|
}
|
||||||
|
|
@ -231,7 +230,7 @@ public:
|
||||||
* @param frameIndex
|
* @param frameIndex
|
||||||
* @return Type&
|
* @return Type&
|
||||||
*/
|
*/
|
||||||
Type& getSample(int channelIndex, size_type frameIndex)
|
Type& getSample(size_t channelIndex, size_t frameIndex)
|
||||||
{
|
{
|
||||||
// Uhoh
|
// Uhoh
|
||||||
ASSERT(buffers[channelIndex] != nullptr);
|
ASSERT(buffers[channelIndex] != nullptr);
|
||||||
|
|
@ -247,7 +246,7 @@ public:
|
||||||
* @param frameIndex
|
* @param frameIndex
|
||||||
* @return Type&
|
* @return Type&
|
||||||
*/
|
*/
|
||||||
Type& operator()(int channelIndex, size_type frameIndex)
|
Type& operator()(size_t channelIndex, size_t frameIndex)
|
||||||
{
|
{
|
||||||
return getSample(channelIndex, frameIndex);
|
return getSample(channelIndex, frameIndex);
|
||||||
}
|
}
|
||||||
|
|
@ -258,7 +257,7 @@ public:
|
||||||
*/
|
*/
|
||||||
void reset()
|
void reset()
|
||||||
{
|
{
|
||||||
for (int i = 0; i < numChannels; ++i)
|
for (size_t i = 0; i < numChannels; ++i)
|
||||||
buffers[i].reset();
|
buffers[i].reset();
|
||||||
numFrames = 0;
|
numFrames = 0;
|
||||||
numChannels = 0;
|
numChannels = 0;
|
||||||
|
|
@ -269,10 +268,10 @@ public:
|
||||||
*
|
*
|
||||||
* @param numChannels
|
* @param numChannels
|
||||||
*/
|
*/
|
||||||
void addChannels(int numChannels)
|
void addChannels(size_t numChannels)
|
||||||
{
|
{
|
||||||
ASSERT(this->numChannels + numChannels <= MaxChannels);
|
ASSERT(this->numChannels + numChannels <= MaxChannels);
|
||||||
for (int i = 0; i < numChannels; ++i)
|
for (size_t i = 0; i < numChannels; ++i)
|
||||||
addChannel();
|
addChannel();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -281,7 +280,7 @@ private:
|
||||||
using buffer_ptr = std::unique_ptr<buffer_type>;
|
using buffer_ptr = std::unique_ptr<buffer_type>;
|
||||||
static_assert(MaxChannels > 0, "Need a positive number of channels");
|
static_assert(MaxChannels > 0, "Need a positive number of channels");
|
||||||
std::array<buffer_ptr, MaxChannels> buffers;
|
std::array<buffer_ptr, MaxChannels> buffers;
|
||||||
int numChannels { 0 };
|
size_t numChannels { 0 };
|
||||||
size_type numFrames { 0 };
|
size_t numFrames { 0 };
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -86,7 +86,7 @@ namespace sfz
|
||||||
* @tparam Type the underlying buffer type
|
* @tparam Type the underlying buffer type
|
||||||
* @tparam MaxChannels the maximum number of channels. Defaults to sfz::config::numChannels
|
* @tparam MaxChannels the maximum number of channels. Defaults to sfz::config::numChannels
|
||||||
*/
|
*/
|
||||||
template <class Type, int MaxChannels = sfz::config::numChannels>
|
template <class Type, size_t MaxChannels = sfz::config::numChannels>
|
||||||
class AudioSpan {
|
class AudioSpan {
|
||||||
public:
|
public:
|
||||||
using size_type = size_t;
|
using size_type = size_t;
|
||||||
|
|
@ -102,7 +102,7 @@ public:
|
||||||
* @param offset starting offset for the AudioSpan
|
* @param offset starting offset for the AudioSpan
|
||||||
* @param numFrames size of the AudioSpan
|
* @param numFrames size of the AudioSpan
|
||||||
*/
|
*/
|
||||||
AudioSpan(const std::array<Type*, MaxChannels>& spans, int numChannels, size_type offset, size_type numFrames)
|
AudioSpan(const std::array<Type*, MaxChannels>& spans, size_type numChannels, size_type offset, size_type numFrames)
|
||||||
: numFrames(numFrames)
|
: numFrames(numFrames)
|
||||||
, numChannels(numChannels)
|
, numChannels(numChannels)
|
||||||
{
|
{
|
||||||
|
|
@ -169,7 +169,7 @@ public:
|
||||||
: numFrames(audioBuffer.getNumFrames())
|
: numFrames(audioBuffer.getNumFrames())
|
||||||
, numChannels(audioBuffer.getNumChannels())
|
, numChannels(audioBuffer.getNumChannels())
|
||||||
{
|
{
|
||||||
for (int i = 0; i < numChannels; i++) {
|
for (size_t i = 0; i < numChannels; i++) {
|
||||||
this->spans[i] = audioBuffer.channelReader(i);
|
this->spans[i] = audioBuffer.channelReader(i);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -190,7 +190,7 @@ public:
|
||||||
: numFrames(audioBuffer.getNumFrames())
|
: numFrames(audioBuffer.getNumFrames())
|
||||||
, numChannels(audioBuffer.getNumChannels())
|
, numChannels(audioBuffer.getNumChannels())
|
||||||
{
|
{
|
||||||
for (int i = 0; i < numChannels; i++) {
|
for (size_t i = 0; i < numChannels; i++) {
|
||||||
this->spans[i] = audioBuffer.channelWriter(i);
|
this->spans[i] = audioBuffer.channelWriter(i);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -205,7 +205,7 @@ public:
|
||||||
: numFrames(other.getNumFrames())
|
: numFrames(other.getNumFrames())
|
||||||
, numChannels(other.getNumChannels())
|
, numChannels(other.getNumChannels())
|
||||||
{
|
{
|
||||||
for (int i = 0; i < numChannels; i++) {
|
for (size_t i = 0; i < numChannels; i++) {
|
||||||
this->spans[i] = other.getChannel(i);
|
this->spans[i] = other.getChannel(i);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -216,7 +216,7 @@ public:
|
||||||
* @param channelIndex the channel
|
* @param channelIndex the channel
|
||||||
* @return Type* the raw pointer to the channel
|
* @return Type* the raw pointer to the channel
|
||||||
*/
|
*/
|
||||||
Type* getChannel(int channelIndex)
|
Type* getChannel(size_t channelIndex)
|
||||||
{
|
{
|
||||||
ASSERT(channelIndex < numChannels);
|
ASSERT(channelIndex < numChannels);
|
||||||
if (channelIndex < numChannels)
|
if (channelIndex < numChannels)
|
||||||
|
|
@ -231,7 +231,7 @@ public:
|
||||||
* @param channelIndex the channel
|
* @param channelIndex the channel
|
||||||
* @return absl::Span<Type>
|
* @return absl::Span<Type>
|
||||||
*/
|
*/
|
||||||
absl::Span<Type> getSpan(int channelIndex)
|
absl::Span<Type> getSpan(size_t channelIndex)
|
||||||
{
|
{
|
||||||
ASSERT(channelIndex < numChannels);
|
ASSERT(channelIndex < numChannels);
|
||||||
if (channelIndex < numChannels)
|
if (channelIndex < numChannels)
|
||||||
|
|
@ -246,7 +246,7 @@ public:
|
||||||
* @param channelIndex the channel
|
* @param channelIndex the channel
|
||||||
* @return absl::Span<const Type>
|
* @return absl::Span<const Type>
|
||||||
*/
|
*/
|
||||||
absl::Span<const Type> getConstSpan(int channelIndex)
|
absl::Span<const Type> getConstSpan(size_t channelIndex)
|
||||||
{
|
{
|
||||||
ASSERT(channelIndex < numChannels);
|
ASSERT(channelIndex < numChannels);
|
||||||
if (channelIndex < numChannels)
|
if (channelIndex < numChannels)
|
||||||
|
|
@ -265,7 +265,7 @@ public:
|
||||||
if (numChannels == 0)
|
if (numChannels == 0)
|
||||||
return 0.0;
|
return 0.0;
|
||||||
Type result = 0.0;
|
Type result = 0.0;
|
||||||
for (int i = 0; i < numChannels; ++i)
|
for (size_t i = 0; i < numChannels; ++i)
|
||||||
result += sfz::meanSquared<Type>(getConstSpan(i));
|
result += sfz::meanSquared<Type>(getConstSpan(i));
|
||||||
return result / numChannels;
|
return result / numChannels;
|
||||||
}
|
}
|
||||||
|
|
@ -278,7 +278,7 @@ public:
|
||||||
void fill(Type value) noexcept
|
void fill(Type value) noexcept
|
||||||
{
|
{
|
||||||
static_assert(!std::is_const<Type>::value, "Can't allow mutating operations on const AudioSpans");
|
static_assert(!std::is_const<Type>::value, "Can't allow mutating operations on const AudioSpans");
|
||||||
for (int i = 0; i < numChannels; ++i)
|
for (size_t i = 0; i < numChannels; ++i)
|
||||||
sfz::fill<Type>(getSpan(i), value);
|
sfz::fill<Type>(getSpan(i), value);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -290,7 +290,7 @@ public:
|
||||||
void applyGain(absl::Span<const Type> gain) noexcept
|
void applyGain(absl::Span<const Type> gain) noexcept
|
||||||
{
|
{
|
||||||
static_assert(!std::is_const<Type>::value, "Can't allow mutating operations on const AudioSpans");
|
static_assert(!std::is_const<Type>::value, "Can't allow mutating operations on const AudioSpans");
|
||||||
for (int i = 0; i < numChannels; ++i)
|
for (size_t i = 0; i < numChannels; ++i)
|
||||||
sfz::applyGain<Type>(gain, getSpan(i));
|
sfz::applyGain<Type>(gain, getSpan(i));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -302,7 +302,7 @@ public:
|
||||||
void applyGain(Type gain) noexcept
|
void applyGain(Type gain) noexcept
|
||||||
{
|
{
|
||||||
static_assert(!std::is_const<Type>::value, "Can't allow mutating operations on const AudioSpans");
|
static_assert(!std::is_const<Type>::value, "Can't allow mutating operations on const AudioSpans");
|
||||||
for (int i = 0; i < numChannels; ++i)
|
for (size_t i = 0; i < numChannels; ++i)
|
||||||
sfz::applyGain<Type>(gain, getSpan(i));
|
sfz::applyGain<Type>(gain, getSpan(i));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -318,7 +318,7 @@ public:
|
||||||
static_assert(!std::is_const<Type>::value, "Can't allow mutating operations on const AudioSpans");
|
static_assert(!std::is_const<Type>::value, "Can't allow mutating operations on const AudioSpans");
|
||||||
ASSERT(other.getNumChannels() == numChannels);
|
ASSERT(other.getNumChannels() == numChannels);
|
||||||
if (other.getNumChannels() == numChannels) {
|
if (other.getNumChannels() == numChannels) {
|
||||||
for (int i = 0; i < numChannels; ++i)
|
for (size_t i = 0; i < numChannels; ++i)
|
||||||
sfz::add<Type>(other.getConstSpan(i), getSpan(i));
|
sfz::add<Type>(other.getConstSpan(i), getSpan(i));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -335,7 +335,7 @@ public:
|
||||||
static_assert(!std::is_const<Type>::value, "Can't allow mutating operations on const AudioSpans");
|
static_assert(!std::is_const<Type>::value, "Can't allow mutating operations on const AudioSpans");
|
||||||
ASSERT(other.getNumChannels() == numChannels);
|
ASSERT(other.getNumChannels() == numChannels);
|
||||||
if (other.getNumChannels() == numChannels) {
|
if (other.getNumChannels() == numChannels) {
|
||||||
for (int i = 0; i < numChannels; ++i)
|
for (size_t i = 0; i < numChannels; ++i)
|
||||||
sfz::copy<Type>(other.getConstSpan(i), getSpan(i));
|
sfz::copy<Type>(other.getConstSpan(i), getSpan(i));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -355,7 +355,7 @@ public:
|
||||||
*
|
*
|
||||||
* @returns size_type the number of channels in the AudioSpan
|
* @returns size_type the number of channels in the AudioSpan
|
||||||
*/
|
*/
|
||||||
int getNumChannels()
|
size_t getNumChannels()
|
||||||
{
|
{
|
||||||
return numChannels;
|
return numChannels;
|
||||||
}
|
}
|
||||||
|
|
@ -413,6 +413,6 @@ private:
|
||||||
static_assert(MaxChannels > 0, "Need a positive number of channels");
|
static_assert(MaxChannels > 0, "Need a positive number of channels");
|
||||||
std::array<Type*, MaxChannels> spans;
|
std::array<Type*, MaxChannels> spans;
|
||||||
size_type numFrames { 0 };
|
size_type numFrames { 0 };
|
||||||
int numChannels { 0 };
|
size_type numChannels { 0 };
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -250,7 +250,7 @@ public:
|
||||||
// return *this;
|
// return *this;
|
||||||
// }
|
// }
|
||||||
|
|
||||||
Type& operator[](int idx) { return *(normalData + idx); }
|
Type& operator[](size_t idx) { return *(normalData + idx); }
|
||||||
constexpr pointer data() const noexcept { return normalData; }
|
constexpr pointer data() const noexcept { return normalData; }
|
||||||
constexpr size_type size() const noexcept { return alignedSize; }
|
constexpr size_type size() const noexcept { return alignedSize; }
|
||||||
constexpr bool empty() const noexcept { return alignedSize == 0; }
|
constexpr bool empty() const noexcept { return alignedSize == 0; }
|
||||||
|
|
|
||||||
|
|
@ -26,6 +26,7 @@
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
// There's a spurious min/max function in MSVC that makes everything go badly...
|
// There's a spurious min/max function in MSVC that makes everything go badly...
|
||||||
#define NOMINMAX
|
#define NOMINMAX
|
||||||
|
#define _SILENCE_CXX17_OLD_ALLOCATOR_MEMBERS_DEPRECATION_WARNING
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
namespace sfz {
|
namespace sfz {
|
||||||
|
|
@ -41,7 +42,7 @@ namespace config {
|
||||||
constexpr int defaultSamplesPerBlock { 1024 };
|
constexpr int defaultSamplesPerBlock { 1024 };
|
||||||
constexpr int maxBlockSize { 8192 };
|
constexpr int maxBlockSize { 8192 };
|
||||||
constexpr int preloadSize { 8192 };
|
constexpr int preloadSize { 8192 };
|
||||||
constexpr int numChannels { 2 };
|
constexpr size_t numChannels { 2 };
|
||||||
constexpr int numBackgroundThreads { 4 };
|
constexpr int numBackgroundThreads { 4 };
|
||||||
constexpr int numVoices { 64 };
|
constexpr int numVoices { 64 };
|
||||||
constexpr int maxVoices { 256 };
|
constexpr int maxVoices { 256 };
|
||||||
|
|
@ -59,7 +60,7 @@ namespace config {
|
||||||
constexpr char defineCharacter { '$' };
|
constexpr char defineCharacter { '$' };
|
||||||
constexpr Oversampling defaultOversamplingFactor { Oversampling::x1 };
|
constexpr Oversampling defaultOversamplingFactor { Oversampling::x1 };
|
||||||
constexpr float A440 { 440.0 };
|
constexpr float A440 { 440.0 };
|
||||||
constexpr unsigned powerHistoryLength { 16 };
|
constexpr size_t powerHistoryLength { 16 };
|
||||||
constexpr float voiceStealingThreshold { 0.00001f };
|
constexpr float voiceStealingThreshold { 0.00001f };
|
||||||
constexpr int numCCs { 143 };
|
constexpr int numCCs { 143 };
|
||||||
constexpr int chunkSize { 1024 };
|
constexpr int chunkSize { 1024 };
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@ public:
|
||||||
*
|
*
|
||||||
* @param size
|
* @param size
|
||||||
*/
|
*/
|
||||||
void resize(int size)
|
void resize(size_t size)
|
||||||
{
|
{
|
||||||
buffer.resize(size);
|
buffer.resize(size);
|
||||||
fill<ValueType>(absl::MakeSpan(buffer), 0.0);
|
fill<ValueType>(absl::MakeSpan(buffer), 0.0);
|
||||||
|
|
|
||||||
|
|
@ -59,7 +59,7 @@ public:
|
||||||
|
|
||||||
Type getGain() const { return gain; }
|
Type getGain() const { return gain; }
|
||||||
|
|
||||||
int processLowpass(absl::Span<const Type> input, absl::Span<Type> lowpass)
|
size_t processLowpass(absl::Span<const Type> input, absl::Span<Type> lowpass)
|
||||||
{
|
{
|
||||||
auto in = input.begin();
|
auto in = input.begin();
|
||||||
auto out = lowpass.begin();
|
auto out = lowpass.begin();
|
||||||
|
|
@ -73,7 +73,7 @@ public:
|
||||||
return size;
|
return size;
|
||||||
}
|
}
|
||||||
|
|
||||||
int processHighpass(absl::Span<const Type> input, absl::Span<Type> highpass)
|
size_t processHighpass(absl::Span<const Type> input, absl::Span<Type> highpass)
|
||||||
{
|
{
|
||||||
auto in = input.begin();
|
auto in = input.begin();
|
||||||
auto out = highpass.begin();
|
auto out = highpass.begin();
|
||||||
|
|
@ -87,7 +87,7 @@ public:
|
||||||
return size;
|
return size;
|
||||||
}
|
}
|
||||||
|
|
||||||
int processLowpassVariableGain(absl::Span<const Type> input, absl::Span<Type> lowpass, absl::Span<const Type> gain)
|
size_t processLowpassVariableGain(absl::Span<const Type> input, absl::Span<Type> lowpass, absl::Span<const Type> gain)
|
||||||
{
|
{
|
||||||
auto in = input.begin();
|
auto in = input.begin();
|
||||||
auto out = lowpass.begin();
|
auto out = lowpass.begin();
|
||||||
|
|
@ -104,7 +104,7 @@ public:
|
||||||
return size;
|
return size;
|
||||||
}
|
}
|
||||||
|
|
||||||
int processHighpassVariableGain(absl::Span<const Type> input, absl::Span<Type> highpass, absl::Span<const Type> gain)
|
size_t processHighpassVariableGain(absl::Span<const Type> input, absl::Span<Type> highpass, absl::Span<const Type> gain)
|
||||||
{
|
{
|
||||||
auto in = input.begin();
|
auto in = input.begin();
|
||||||
auto out = highpass.begin();
|
auto out = highpass.begin();
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue