wavelength 1.0.0
Loading...
Searching...
No Matches
pitchtrackdisplay.h
Go to the documentation of this file.
1#pragma once
2
4#include "game/playmap.h"
6#include "os/command.h"
7#include "os/ptr.h"
8
17public:
31 int nLeadInBars,
32 int nTicksPerBar,
33 PlayMap *pPlayMap,
34 SectionBoundaries *pSections,
35 PitchTrackPlayGems *pGems);
36
44
51 void Start();
52
59 void Stop();
60
71 void SetGems(PitchTrackPlayGems *pGems, int nStyle, int nUnused, int nOwner);
72
81 void BlankBars(int nStartBar, int nEndBar);
82
93 void ShowGem(signed char nSlot, int nTick, bool bRepeat, int nOwner);
94
103 void HideGem(int nTick, bool bRepeat);
104
112 void Redraw(int nStartBar);
113
122 void Redraw(int nStartBar, int nEndBar);
123
131 void ClearGems(int nStartBar);
132
141 void ClearGems(int nStartBar, int nEndBar);
142
151 void RedrawBar(int nBar, bool bClear);
152
160 void ClearRepeatedBars(int nBar);
161
170 void ClearBar(int nBar, bool bRepeat);
171
172private:
185 void DrawGem(signed char nSlot, int nTick, bool bRepeat, int nOwner, bool bPlace);
186
193 void Update();
194
204 void DrawRange(int nStartBar, int nEndBar, bool bClear);
205
214 void DrawBars(int nStartBar, int nEndBar);
215
227 void DrawGems(int nStartBar, int nEndBar, bool bClear, int nUnused, int nOwner);
228
229 int mTrack;
230 int mTicksPerBar;
231 PlayMap *mPlayMap;
232 SectionBoundaries *mSections;
233 PitchTrackPlayGems *mGems;
234 Ptr<Command> mUpdateCommand;
235 int mEndBar;
236 int mStyle;
237};
void ClearGems(int nStartBar)
Remove the gems shown from a bar to the last bar shown.
void Redraw(int nStartBar, int nEndBar)
Show again the gems of a range of bars, ending no later than the last bar shown.
void Stop()
Withdraw the scheduled update.
void BlankBars(int nStartBar, int nEndBar)
Show a range of bars empty, outside the song.
~PitchTrackDisplay()
Withdraw the scheduled command and release the display.
void HideGem(int nTick, bool bRepeat)
Show a gem removed.
void SetGems(PitchTrackPlayGems *pGems, int nStyle, int nUnused, int nOwner)
Show other gems from the current bar on.
PitchTrackDisplay(int nTrack, int nLeadInBars, int nTicksPerBar, PlayMap *pPlayMap, SectionBoundaries *pSections, PitchTrackPlayGems *pGems)
Construct a display.
void RedrawBar(int nBar, bool bClear)
Show a bar again, and each later bar shown that plays the same bar of the song.
void ClearRepeatedBars(int nBar)
Remove the gems of a bar and of every other bar after it shown in the same section.
void Redraw(int nStartBar)
Show again the gems from a bar to the last bar shown.
void ClearGems(int nStartBar, int nEndBar)
Remove the gems shown in a range of bars.
void ShowGem(signed char nSlot, int nTick, bool bRepeat, int nOwner)
Show a gem placed.
void Start()
Show the bars ahead of the song and schedule the next update.
void ClearBar(int nBar, bool bRepeat)
Remove the gems of a bar, and on request of every other bar after it in the same section.
The gems of a pitch track, addressed by the bars and ticks the song plays.
Definition pitchtrackplaygems.h:15
Map from the bars a song plays to the bars of the song as written, with the loops that repeat stretch...
Definition playmap.h:11
Owner of one reference to an Attachment.
Definition ptr.h:16
Ascending list of the measures at which the sections of a song end.
Definition sectionboundaries.h:12