wavelength 1.0.0
Loading...
Searching...
No Matches
SampleDescWin.h
Go to the documentation of this file.
1#pragma once
2
4#include "utl/Str.h"
5
13public:
20 explicit SampleDescWin(int sampleID);
21
28
37 void SetKeymap(unsigned char iLow, unsigned char iBase, unsigned char iHigh);
38
47 void GetKeymap(unsigned char *oLow, unsigned char *oBase, unsigned char *oHigh);
48
54 int GetID() const {
55 return mID;
56 }
57
64 return mName;
65 }
66
72 void SetName(const String &name) {
73 if (name.size() > 0) {
74 mName = name;
75 }
76 }
77
84 int GetSampleID() const {
85 return mSampleID;
86 }
87
94 return mSampleDescription;
95 }
96
97private:
98 int mID;
99 String mName;
100 int mSampleID;
101 SampleDescription mSampleDescription;
102};
~SampleDescWin()
Release the description.
int GetSampleID() const
Report the identifier of the sample the description plays.
Definition SampleDescWin.h:84
SampleDescWin(int sampleID)
Create a description of a sample, named after its identifier.
void SetName(const String &name)
Rename the description, unless the new name is empty.
Definition SampleDescWin.h:72
void SetKeymap(unsigned char iLow, unsigned char iBase, unsigned char iHigh)
Set the key range and base key.
String & GetName()
Report the name.
Definition SampleDescWin.h:63
SampleDescription & GetSampleDescription()
Report the playback settings.
Definition SampleDescWin.h:93
int GetID() const
Report the identifier.
Definition SampleDescWin.h:54
void GetKeymap(unsigned char *oLow, unsigned char *oBase, unsigned char *oHigh)
Report the key range and base key.
How one sample plays across a key range of an instrument, shared with the synthesiser on the IOP.
Definition SampleDescription.h:11
Growable text buffer that is also a PrnStream.
Definition string.h:19
unsigned int size() const
Definition Str.h:226