|
wavelength 1.0.0
|
Identity and mix settings of an instrument bank, as the bank file records them. More...
#include <bankheader.h>
Public Member Functions | |
| BankHeader () | |
| Construct a header with the defaults Init() sets. | |
| void | Init () |
| Reset every field to its default. | |
| int | Unpack (const unsigned char *data) |
| Read the header from a serialised record. | |
| int | Pack (unsigned char *data) const |
| Write the header as a serialised record of the current version. | |
| int | PackedSize () const |
| Report the size of a serialised record of the current version. | |
Public Attributes | |
| unsigned short | mId |
| unsigned char | mVolume |
| unsigned short | mNumPrograms |
Identity and mix settings of an instrument bank, as the bank file records them.
The class has no RTTI, and its name is inferred from its role. The serialised record is a version word followed by the fields in member order, with no padding.
| BankHeader::BankHeader | ( | ) |
Construct a header with the defaults Init() sets.
| void BankHeader::Init | ( | ) |
Reset every field to its default.
| int BankHeader::Unpack | ( | const unsigned char * | data | ) |
Read the header from a serialised record.
A record of an unknown version does not change the header.
| data | The record, at any alignment. |
| int BankHeader::Pack | ( | unsigned char * | data | ) | const |
Write the header as a serialised record of the current version.
| data | Receives the record, at any alignment. |
| int BankHeader::PackedSize | ( | ) | const |
Report the size of a serialised record of the current version.
| unsigned short BankHeader::mId |
Bank identifier a bank select requests.
| unsigned char BankHeader::mVolume |
Bank volume, an index into the volume curve.
| unsigned short BankHeader::mNumPrograms |
Programs the bank defines.