FastLED 3.10.8
Loading...
Searching...
No Matches

◆ operator==()

bool fl::audio::Sample::operator== ( const Sample & other) const

Definition at line 107 of file audio.cpp.hpp.

107 {
108 if (mImpl == other.mImpl) {
109 return true;
110 }
111 if (mImpl == nullptr || other.mImpl == nullptr) {
112 return false;
113 }
114 if (mImpl->pcm().size() != other.mImpl->pcm().size()) {
115 return false;
116 }
117 for (fl::size i = 0; i < mImpl->pcm().size(); ++i) {
118 if (mImpl->pcm()[i] != other.mImpl->pcm()[i]) {
119 return false;
120 }
121 }
122 return true;
123}
SampleImplPtr mImpl
Definition audio.h:62
fl::size size() const FL_NO_EXCEPT
Definition audio.cpp.hpp:91

References Sample(), fl::FL_NO_EXCEPT, mImpl, and size().

+ Here is the call graph for this function: