The following notation shows the organization of the top-level chunk, or form, of a chordmap file:
RIFF( 'DMPR'
<perh-ck> // Chordmap header chunk
[ <guid-ck> ] // GUID chunk
[ <vers-ck> ] // version chunk
[ <UNFO-list> ] // UNFO list
<chdt-ck> // chord data chunk
<chpl-list> // chord palette
<cmap-list> // chord graph
<spsq-list> // signpost list
)
Each of the items with the exception of the GUID chunk, version chunk, and UNFO list (see Common Chunks) is required.
The required chunks and their subchunks are as follows:
<perh-ck> -> perh( <DMUS_IO_CHORDMAP> )
This is the basic header information for a chordmap.
<chdt-ck> -> chdt(
<WORD> // size of DMUS_IO_CHORDMAP_SUBCHORD
<DMUS_IO_CHORDMAP_SUBCHORD>...
)
The <chdt-ck> chunk contains a WORD indicating the number of bytes per subchord followed by an array of unique subchords. The subchord identifiers referenced in other parts of this file all correspond directly to an index into this array.
<chpl-list> -> LIST( 'chpl'
<chrd-list>...
)
This list contains the chord palette. Currently there must be exactly 24 items in this list.
<chrd-list> -> LIST( 'chrd'
<UNAM-ck> // chord name
<sbcn-ck> // subchord indexes
)
This list contains the basic chord information. This information is simply the chord's name and a list of identifiers for the subchords that make it up.
<UNAM-ck> -> UNAM ( <WCHAR>... )
The UNAM chunk stores the name of the chord.
<sbcn-ck> -> sbcn( <WORD>... )
The "sbcn" chunk contains one or more subchord identifiers. These correspond directly to an index into the array found in <chdt-ck>. Currently a maximum of four chords is supported.
<cmap-list> -> LIST( 'cmap'
<choe-list>...
)
The "cmap" list contains the entire chord connection graph for the chordmap. The bulk of the data for the chordmap resides in this chunk.
<choe-list> -> LIST( 'choe'
<cheh-ck> // chord entry data
<chrd-list> // chord data; see above
<ncsq-ck> // nextchord list
)
The "choe" list contains data for a single entry in the chord graph along with pointers to all the chords that may occur next in the chord graph.
<cheh-ck> -> cheh( <DMUS_IO_CHORDENTRY> )
This is the chord entry header. The identifier in the structure is the identifier for the chord connection graph, not a subchord identifier.
<ncsq-ck> -> ncsq (
<WORD> // size of DMUS_IO_NEXTCHORD
<DMUS_IO_NEXTCHORD>...
)
The "ncsq" chunk contains data that connects one chord in the connection graph to another. Each chord in the connection graph is represented by a 16-bit identifier.
<spsq-list> -> LIST( 'spsq'
<spst-list>...
)
The "spsq" list contains data for each of the signposts.
<spst-list> -> LIST( 'spst'
<spsh-ck>
<chrd-list> // chord data; see above
[ <cade-list> ]
)
The "spst" list contains data for a single signpost, consisting of a header, chord information, and optional cadence chords.
<cade-list> -> LIST( 'cade'
<chrd-list>...
)
The "cade" list contains the chord information for cadence chords. Currently there is support for up to two cadence chords in this list. Any additional chords or other information will be ignored.
<spsh-ck> -> spsh(
<DMUS_IO_CHORDMAP_SIGNPOST>
)
Finally, the "spsh" chunk contains the signpost data.