2024-02-20 14:14:24 +00:00
|
|
|
#pragma once
|
|
|
|
#include "EffectApplication.h"
|
2024-10-23 11:44:31 +00:00
|
|
|
#include "../shape/OsciPoint.h"
|
2024-02-20 14:14:24 +00:00
|
|
|
|
|
|
|
class DashedLineEffect : public EffectApplication {
|
|
|
|
public:
|
|
|
|
DashedLineEffect();
|
|
|
|
~DashedLineEffect();
|
|
|
|
|
2024-10-23 11:44:31 +00:00
|
|
|
OsciPoint apply(int index, OsciPoint input, const std::vector<std::atomic<double>>& values, double sampleRate) override;
|
2024-02-20 14:14:24 +00:00
|
|
|
|
|
|
|
private:
|
|
|
|
const static int MAX_BUFFER = 192000;
|
2024-10-23 11:44:31 +00:00
|
|
|
std::vector<OsciPoint> buffer = std::vector<OsciPoint>(MAX_BUFFER);
|
2024-02-20 14:14:24 +00:00
|
|
|
int dashIndex = 0;
|
|
|
|
int bufferIndex = 0;
|
2024-08-26 17:09:29 +00:00
|
|
|
};
|