mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-10 23:44:24 +00:00
DSP: Added an assertion to protect against invalid use of ProcessContextNonReplacing
This commit is contained in:
parent
1bc7fdd1ec
commit
9f344aaa5a
2 changed files with 20 additions and 1 deletions
|
|
@ -151,6 +151,20 @@ public:
|
|||
AudioBlock (const AudioBlock& other) noexcept = default;
|
||||
AudioBlock& operator= (const AudioBlock& other) noexcept = default;
|
||||
|
||||
//==============================================================================
|
||||
bool operator== (const AudioBlock& other) const noexcept
|
||||
{
|
||||
return std::equal (channels, channels + numChannels,
|
||||
other.channels, other.channels + other.numChannels)
|
||||
&& startSample == other.startSample
|
||||
&& numSamples == other.numSamples;
|
||||
}
|
||||
|
||||
bool operator!= (const AudioBlock& other) const noexcept
|
||||
{
|
||||
return ! (*this == other);
|
||||
}
|
||||
|
||||
//==============================================================================
|
||||
forcedinline size_t getNumSamples() const noexcept { return numSamples; }
|
||||
forcedinline size_t getNumChannels() const noexcept { return static_cast<size_t> (numChannels); }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue