comparison include/SDL_audio.h @ 1985:8055185ae4ed

Added source color and alpha modulation support. Added perl script to generate optimized render copy functions.
author Sam Lantinga <slouken@libsdl.org>
date Mon, 28 Aug 2006 03:17:39 +0000
parents ee73925ddf14
children 5f6550e5184f 37c9c4590689
comparison
equal deleted inserted replaced
1984:b910bcabec26 1985:8055185ae4ed
130 #endif 130 #endif
131 131
132 132
133 /* A structure to hold a set of audio conversion filters and buffers */ 133 /* A structure to hold a set of audio conversion filters and buffers */
134 struct SDL_AudioCVT; 134 struct SDL_AudioCVT;
135 typedef void (SDLCALL * SDL_AudioFilter)(struct SDL_AudioCVT *cvt, 135 typedef void (SDLCALL * SDL_AudioFilter) (struct SDL_AudioCVT * cvt,
136 SDL_AudioFormat format); 136 SDL_AudioFormat format);
137 137
138 typedef struct SDL_AudioCVT 138 typedef struct SDL_AudioCVT
139 { 139 {
140 int needed; /* Set to 1 if conversion possible */ 140 int needed; /* Set to 1 if conversion possible */
141 SDL_AudioFormat src_format; /* Source audio format */ 141 SDL_AudioFormat src_format; /* Source audio format */
142 SDL_AudioFormat dst_format; /* Target audio format */ 142 SDL_AudioFormat dst_format; /* Target audio format */
143 double rate_incr; /* Rate conversion increment */ 143 double rate_incr; /* Rate conversion increment */
144 Uint8 *buf; /* Buffer to hold entire audio data */ 144 Uint8 *buf; /* Buffer to hold entire audio data */
145 int len; /* Length of original audio buffer */ 145 int len; /* Length of original audio buffer */
146 int len_cvt; /* Length of converted audio buffer */ 146 int len_cvt; /* Length of converted audio buffer */
147 int len_mult; /* buffer must be len*len_mult big */ 147 int len_mult; /* buffer must be len*len_mult big */
148 double len_ratio; /* Given len, final size is len*len_ratio */ 148 double len_ratio; /* Given len, final size is len*len_ratio */
149 SDL_AudioFilter filters[10]; /* Filter list */ 149 SDL_AudioFilter filters[10]; /* Filter list */
150 int filter_index; /* Current audio conversion function */ 150 int filter_index; /* Current audio conversion function */
151 } SDL_AudioCVT; 151 } SDL_AudioCVT;
152 152
153 153
154 /* Function prototypes */ 154 /* Function prototypes */
155 155