![]() |
![]()
| ![]() |
![]()
Routineint AFsetNHpar (const char String[])
PurposeSet defaults for input headerless audio files from a string
specification
DescriptionThis routine sets the default audio file data parameters. These parameters are used for reading audio files with unrecognized (non-standard) headers or files with no headers (raw audio files). This routine must be called before opening the file with AFopnRead. The parameters for AFsetNHpar are determined from an input string which consists of a list of parameters separated by commas and/or white space. The form of the list is
Format: File data format
Start: byte offset to the start of data (integer value) Sfreq:
sampling frequency in Hz (floating-point number) Swapb: Data byte swap
parameter
Nchan: number of channels
The default values for the audio file parameters correspond to the following string.
Leading and trailing white-space (as defined by isspace) is removed from each item. Any of the parameters may be omitted, in which case whatever value has been previously set remains in effect for that parameter. The string ",512, 10000." would set the Start and Sfreq parameters and leave the other parameters undisturbed. If the input string contains has a leading '$', the string is assumed to specify the name of an environment variable after the '$'. This routine uses the value of this environment variable to determine the parameters. If this routine is called as AFsetNHpar("$AF_NOHEADER"), this routine would look for the parameter string in environment variable AF_NOHEADER. Parameters<- int AFsetNHpar
Author / revisionP. Kabal / Revision 1.53 2003/05/09 See AlsoAFopnRead
|