SoundFont 3 does not change the zone tables. pbag lists the zones of presets and ibag those of instruments; each is a multiple of four bytes with one record for each zone and a terminal zone (SF2 spec 7.3 and 7.7).
The record
| Offset | Size | pbag field | ibag field | Meaning |
|---|---|---|---|---|
| 0 | 2 | wGenNdx | wInstGenNdx | The index of the zone’s first generator in pgen or igen |
| 2 | 2 | wModNdx | wInstModNdx | The index of the zone’s first modulator in pmod or imod |
Rules
- An object’s zones run from its bag index to the next object’s; a zone’s generators and modulators run from its indexes to the next zone’s. All indexes increase monotonically; the generator table is four times the terminal zone’s generator index plus four bytes, and the modulator table ten times its modulator index plus ten; otherwise the file is structurally defective.
- If an object has more than one zone, the first may be a global zone: its last generator is not an instrument (or sampleID) generator, and its values apply to all other zones. A generator list has at least one generator, except for a global zone that holds only modulators.
- A zone other than the first that does not end with an instrument (sampleID) generator is ignored; so is a global zone with no generators and no modulators.
- A missing sub-chunk or a size that is not a multiple of four rejects the file as structurally unsound.
(SF2 spec 7.3, 7.7.) One instrument of VintageDreamsWaves-v2.sf3 has such an empty global zone; the explorer reports it.
In the explorer
The table that Show opens for a preset or instrument lists its zones with their kind (zone, global or ignored), key and velocity ranges, target, and generator and modulator counts. Bag indexes that go down or do not match the generator and modulator tables, ignored zones and generators after the terminal one are reported.
Source: SoundFont Technical Specification 2.04, sections 2.1, 4.4, 7.3 and 7.7; the corpus file VintageDreamsWaves-v2.sf3.