// // Created by versustune on 12.06.20. // #ifndef VENO_VENOBUFFER_H #define VENO_VENOBUFFER_H #include #include "JuceHeader.h" class VenoBuffer { private: std::vector buffer; std::vector right; std::vector left; public: VenoBuffer (); ~VenoBuffer (); void reset (int size); void addMonoSample (float value, int index); void addLeftSample (float value, int index); void addRightSample (float value, int index); void calcPeak (); float leftPeak; float rightPeak; float monoPeak; const std::vector& getBuffer () const; const std::vector& getRight () const; const std::vector& getLeft () const; protected: JUCE_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR (VenoBuffer); }; #endif //VENO_VENOBUFFER_H