-
Notifications
You must be signed in to change notification settings - Fork 0
/
Quiet.h
70 lines (60 loc) · 1.96 KB
/
Quiet.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
#pragma once
#include "Qommon.h"
#include "DSP/QuietProcessing.h"
#include "IPlug_include_in_plug_hdr.h"
const int qNumPresets = 1;
enum QParams
{
qDepth = 0,
qRate,
qFrequency,
qSnap,
qPhaseShift,
qSync,
qMIDI,
qSmoothing,
qWaveform,
qTheme,
qLookahead,
qVelocity,
qNumParams
};
enum QontrolTags
{
QtrlTagBaq = 0,
QtrlTagSqope,
QtrlTagQnodeSys,
QtrlTagUndo,
QtrlTagQenu,
QtrlTagRedo,
QtrlTagInfo
};
//*****************************************************************************************************************************************
class Quiet final : public Plugin
{
public:
//***************************************************************************************************************************************
Quiet(const InstanceInfo&);
void OnIdle() override;
void OnReset() override;
void OnParamChange(int _paramIdx) override;
void OnParamChangeUI(int _paramIdx, EParamSource _eps) override;
void ProcessBlock(sample** _inputs, sample** _outputs, int _frames) override;
void ProcessMidiMsg(const IMidiMsg& _msg) override;
bool SerializeState(IByteChunk& _chunk) const override;
int UnserializeState(const IByteChunk& _chunk, int _startPosition) override;
private:
//***************************************************************************************************************************************
Qurve qurve;
QuietProcessing qp{qurve};
//***************************************************************************************************************************************
Qheme qheme;
bool transporting = false;
bool showSidechain = false;
//***************************************************************************************************************************************
void updateLookAhead();
void turnLookAheadOff(bool _alreadyOff);
bool addAsterisk(std::string& _presetName);
void updateQenuTheme(IGraphics* _qui);
void updateUndoRedoQuttons(const IGraphics* _qui);
};