Holder of the track description the beat-quantising paths consult.
More...
#include <quantizer.h>
|
| | Quantizer (const TrackData *pTrackData) |
| | Retain the track description.
|
| int | Quantize (int nTick) |
| | Round a song position to the quantisation of its bar.
|
| int | GetQuantum (int nTick) |
| | Report the quantisation of the bar a song position falls in.
|
|
| static unsigned | Round (unsigned nTick, unsigned nQuantum) |
| | Round a song position to the nearest multiple of a quantum.
|
Holder of the track description the beat-quantising paths consult.
The class emits no RTTI, because it is not polymorphic. Its name is attested by the signature of Catcher::Catcher() the image records, whose second parameter is Quantizer *.
The object is four bytes. ScoreTrackGraph builds one with the global operator new(4), and the constructor at 0x001ce670 stores its argument and returns.
◆ Quantizer()
| Quantizer::Quantizer |
( |
const TrackData * | pTrackData | ) |
|
Retain the track description.
- Parameters
-
| pTrackData | The track this quantiser works over. |
- Ghidra address:
- NTSC-U/C: 0x001ce670
- Ghidra address:
- PAL: 0x001d4528
◆ Quantize()
| int Quantizer::Quantize |
( |
int | nTick | ) |
|
Round a song position to the quantisation of its bar.
- Parameters
-
| nTick | The song position, in MIDI ticks. |
- Returns
- The rounded position.
- Ghidra address:
- NTSC-U/C: 0x001ce680
- Ghidra address:
- PAL: 0x001d4538
◆ GetQuantum()
| int Quantizer::GetQuantum |
( |
int | nTick | ) |
|
Report the quantisation of the bar a song position falls in.
- Parameters
-
| nTick | The song position, in MIDI ticks. |
- Returns
- TrackData::GetQuant() for the bar, in MIDI ticks.
- Ghidra address:
- NTSC-U/C: 0x001ce6b0
- Ghidra address:
- PAL: 0x001d4568
◆ Round()
| unsigned Quantizer::Round |
( |
unsigned | nTick, |
|
|
unsigned | nQuantum ) |
|
static |
Round a song position to the nearest multiple of a quantum.
The position is moved eight ticks earlier before rounding. The arithmetic is unsigned, and a zero quantum traps.
- Parameters
-
| nTick | The song position, in MIDI ticks. |
| nQuantum | The quantum, in MIDI ticks. |
- Returns
- The rounded position.
- Ghidra address:
- NTSC-U/C: 0x001ce710
- Ghidra address:
- PAL: 0x001d45c8
The documentation for this class was generated from the following file: