/* Magic MIDI bytes used to switch I/O streams on the ICS2115 MPU401 emulation. Note these NEVER show up in output from the device and should NEVER be used in input unless Virtual MIDI mode has been disabled. If they do show up as input, the results are unpredictable.
*/
Because most/all of the sample data we pass in via pointers has never been copied (just mmap-ed into user space straight from the disk), it would be nice to allow handling of multi-channel sample data without forcing user-level extraction of the relevant bytes. So, we need a way of specifying which channel to use (the WaveFront only handles mono samples in a given slot), and the only way to do this without using some struct other than wavefront_sample as the interface is the awful hack of using the unused bits in a wavefront_sample: Val Meaning --- ------- 0 no channel selection (use channel 1, sample is MONO) 1 use first channel, and skip one 2 use second channel, and skip one 3 use third channel, and skip two 4 use fourth channel, skip three 5 use fifth channel, skip four 6 use six channel, skip five
This can handle up to 4 channels, and anyone downloading >4 channels of sample data just to select one of them needs to find some tools like sox ...
NOTE: values 0, 1 and 2 correspond to WF_CH_* above. This is important.
/* This structure is meant to be padded only to 16 bits on their original. Of course, whoever wrote their documentation didn't realize that sizeof(struct) can be >= sum(sizeof(struct-fields)) and so thought that giving a C level description of the structs used in WavePatch files was sufficient. I suppose it was, as long as you remember the standard 16->32 bit issues.
*/
/* Hannu Solvainen hoped that his "patch_info" struct in soundcard.h might work for other wave-table based patch loading situations. Alas, his fears were correct. The WaveFront doesn't even come with just "patches", but several different kind of structures that control the sound generation process.
*/
typedefstruct wf_patch_info {
/* the first two fields are used by the OSS "patch loading" interface only, and are unused by the current user-level library.
*/
s16 key; /* Use WAVEFRONT_PATCH here */
u16 devno; /* fill in when sending */
u8 subkey; /* WF_ST_{SAMPLE,ALIAS,etc.} */
#define WAVEFRONT_FIND_FREE_SAMPLE_SLOT 999
u16 number; /* patch/sample/prog number */
u32 size; /* size of any data included in one of the fields in `hdrptr', or as `dataptr'.
NOTE: for actual samples, this is the size of the *SELECTED CHANNEL* even if more data is actually available. So, a stereo sample (2 channels) of 6000 bytes total has `size' = 3000.
See the macros and comments for WF_{GET,SET}_CHANNEL above.
*/
wavefront_any __user *hdrptr; /* user-space ptr to hdr bytes */
u16 __user *dataptr; /* actual sample data */
/* The maximum number of bytes we will ever move to or from user space in response to a WFC_* command. This obviously doesn't cover actual sample data.
*/
/* This allows us to execute any WF command except the download/upload ones, which are handled differently due to copyin/copyout issues as well as data-nybbling to/from the card.
*/
typedefstruct wavefront_control { int cmd; /* WFC_* */ char status; /* return status to user-space */ unsignedchar rbuf[WF_MAX_READ]; /* bytes read from card */ unsignedchar wbuf[WF_MAX_WRITE]; /* bytes written to card */
} wavefront_control;
typedefstruct wf_fx_info { int request; /* see list below */ long data[4]; /* we don't need much */
} wavefront_fx_info;
/* support for each of these will be forthcoming once I or someone else has figured out which of the addresses on page 6 and page 7 of the YSS225 control each parameter. Incidentally, these come from the Windows driver interface, but again, Turtle Beach didn't document the API to use them.
*/
/* Allow direct user-space control over FX memory/coefficient data. In theory this could be used to download the FX microprogram, but it would be a little slower, and involve some weird code.
*/
#define WFFX_MEMSET 69
#endif/* __SOUND_WAVEFRONT_H__ */
Messung V0.5
¤ Dauer der Verarbeitung: 0.11 Sekunden
(vorverarbeitet)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.