MCPcopy Create free account
hub / github.com/BespokeSynth/BespokeSynth / DrawModule

Method DrawModule

Source/NoteSinger.cpp:108–121  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

106}
107
108void NoteSinger::DrawModule()
109{
110 if (Minimized() || IsVisible() == false)
111 return;
112
113 mOctaveSlider->Draw();
114
115 for (int i = 0; i < mNumBuckets; ++i)
116 {
117 float x = ofMap(i, 0, mNumBuckets, 0, 100);
118 ofSetColor(255, 0, 255);
119 ofLine(x, 50, x, 50 - ofMap(MIN(mPeaks[i].GetPeak(), 1), 0, 1, 0, 50));
120 }
121}
122
123void NoteSinger::OnScaleChanged()
124{

Callers

nothing calls this directly

Calls 5

ofMapFunction · 0.85
ofSetColorFunction · 0.85
ofLineFunction · 0.85
GetPeakMethod · 0.80
DrawMethod · 0.45

Tested by

no test coverage detected