100 |
} |
} |
101 |
|
|
102 |
BOOL |
BOOL |
103 |
sun_format_supported(WAVEFORMATEX * pwfx) |
sun_format_supported(RD_WAVEFORMATEX * pwfx) |
104 |
{ |
{ |
105 |
if (pwfx->wFormatTag != WAVE_FORMAT_PCM) |
if (pwfx->wFormatTag != WAVE_FORMAT_PCM) |
106 |
return False; |
return False; |
113 |
} |
} |
114 |
|
|
115 |
BOOL |
BOOL |
116 |
sun_set_format(WAVEFORMATEX * pwfx) |
sun_set_format(RD_WAVEFORMATEX * pwfx) |
117 |
{ |
{ |
118 |
audio_info_t info; |
audio_info_t info; |
119 |
|
|
264 |
} |
} |
265 |
} |
} |
266 |
|
|
|
static struct audio_driver sun_driver = { |
|
|
.name = "sun", |
|
|
.description = "SUN/BSD output driver, default device: " DEFAULTDEVICE " or $AUDIODEV", |
|
|
|
|
|
.add_fds = sun_add_fds, |
|
|
.check_fds = sun_check_fds, |
|
|
|
|
|
.wave_out_open = sun_open, |
|
|
.wave_out_close = sun_close, |
|
|
.wave_out_format_supported = sun_format_supported, |
|
|
.wave_out_set_format = sun_set_format, |
|
|
.wave_out_volume = sun_volume, |
|
|
|
|
|
.need_byteswap_on_be = 1, |
|
|
.need_resampling = 0, |
|
|
}; |
|
|
|
|
267 |
struct audio_driver * |
struct audio_driver * |
268 |
sun_register(char *options) |
sun_register(char *options) |
269 |
{ |
{ |
270 |
|
static struct audio_driver sun_driver; |
271 |
|
|
272 |
|
memset(&sun_driver, 0, sizeof(sun_driver)); |
273 |
|
|
274 |
|
sun_driver.name = "sun"; |
275 |
|
sun_driver.description = |
276 |
|
"SUN/BSD output driver, default device: " DEFAULTDEVICE " or $AUDIODEV"; |
277 |
|
|
278 |
|
sun_driver.add_fds = sun_add_fds; |
279 |
|
sun_driver.check_fds = sun_check_fds; |
280 |
|
|
281 |
|
sun_driver.wave_out_open = sun_open; |
282 |
|
sun_driver.wave_out_close = sun_close; |
283 |
|
sun_driver.wave_out_format_supported = sun_format_supported; |
284 |
|
sun_driver.wave_out_set_format = sun_set_format; |
285 |
|
sun_driver.wave_out_volume = sun_volume; |
286 |
|
|
287 |
|
sun_driver.need_byteswap_on_be = 1; |
288 |
|
sun_driver.need_resampling = 0; |
289 |
|
|
290 |
if (options) |
if (options) |
291 |
{ |
{ |
292 |
dsp_dev = xstrdup(options); |
dsp_dev = xstrdup(options); |
297 |
|
|
298 |
if (dsp_dev == NULL) |
if (dsp_dev == NULL) |
299 |
{ |
{ |
300 |
dsp_dev = xstrdup(DEFAULTDEVICE); |
dsp_dev = DEFAULTDEVICE; |
301 |
} |
} |
302 |
} |
} |
303 |
|
|