afInitMarkName(3dm) afInitMarkName(3dm) NAME afInitMarkName, afInitMarkComment - initialize the name/comment for a specified marker in an AFfilesetup structure SYNOPSIS #include <dmedia/audiofile.h> void afInitMarkName(AFfilesetup setup, int track, int markid, const char *namestr) void afInitMarkComment(AFfilesetup setup, int track, int markid, const char *commstr) PARAMETER setup is an AFfilesetup structure, previously created by a call to afNewFileSetup(3dm). track is a positive integer value which specifies an audio track in a file configuration. Since all currently supported file formats contain exactly one audio track, the value AF_DEFAULT_TRACK should always be used here for now. markid a positive integer value which identifies a marker structure configured into track previously by afInitMarkIDs(3dm). namestr is a character string which will be written into the marker structure when an audio file is created with setup. AIFF-C (AIFF) files allow up to 255 characters per marker name. commstr is a character string which will be written into the marker structure when an audio file is created with setup. Any file type which does not allow comments (AIFF-C and AIFF included) will simply ignore the comment. Currently, WAVE files support comments in the "cue" list, into which the mark chunks are mapped. DESCRIPTION afInitMarkName() specifies a name string for a marker structure. afInitMarkComment() specifies a comment string for same. Note that you need to initialize a list of marker ID's for setup by calling afInitMarkIDs(3dm) before you can set name strings and/or comments for individual markers. When you create an audio file by passing setup to afOpenFile(3dm), the file header will be written out with namestr attached to the marker structure given by markid. Marker names and comments default to zero-length strings. EXAMPLE You might initialize the marker ID list in an AFfilesetup to {1,2,3,4} to store four endpoints, two for each of two loops. You might then give marker 1 the name "begin sustain loop", marker 2 the name "end sustain loop", marker 3 the name "begin release loop", and marker 4 the name "end release loop". SEE ALSO afNewFileSetup(3dm), afOpenFile(3dm), afInitMarkIDs(3dm), afGetMarkIDs(3dm), afGetMarkName(3dm) Page 2