26 #ifndef _SIFTEO_ABI_AUDIO_H
27 #define _SIFTEO_ABI_AUDIO_H
29 #include <sifteo/abi/types.h>
36 typedef uint8_t _SYSAudioChannelID;
38 #define _SYS_AUDIO_INVALID_CHANNEL_ID ((_SYSAudioChannelID)-1)
39 #define _SYS_AUDIO_MAX_CHANNELS 8
41 #define _SYS_AUDIO_MAX_VOLUME_LOG2 8
42 #define _SYS_AUDIO_MAX_VOLUME (1 << _SYS_AUDIO_MAX_VOLUME_LOG2)
43 #define _SYS_AUDIO_DEFAULT_VOLUME (_SYS_AUDIO_MAX_VOLUME / 2)
54 enum _SYSAudioLoopType {
58 _SYS_LOOP_EMULATED_PING_PONG = 2,
61 struct _SYSAudioModule {
72 struct _SYSXMPattern {
78 struct _SYSXMInstrument {
79 struct _SYSAudioModule sample;
81 int8_t relativeNoteNumber;
84 uint32_t volumeEnvelopePoints;
85 uint8_t nVolumeEnvelopePoints;
86 uint8_t volumeSustainPoint;
87 uint8_t volumeLoopStartPoint;
88 uint8_t volumeLoopEndPoint;
94 uint16_t volumeFadeout;
98 uint32_t patternOrderTable;
99 uint16_t patternOrderTableSize;
100 uint8_t restartPosition;
106 uint8_t nInstruments;
107 uint32_t instruments;
109 uint8_t frequencyTable;