mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-10-25 20:07:17 +00:00
PSP: Removed inlined copy of SDL_CalculateAudioSpec()'s functionality.
This commit is contained in:
@@ -66,20 +66,7 @@ PSPAUD_OpenDevice(_THIS, void *handle, const char *devname, int iscapture)
|
|||||||
this->spec.freq = 44100;
|
this->spec.freq = 44100;
|
||||||
|
|
||||||
/* Update the fragment size as size in bytes. */
|
/* Update the fragment size as size in bytes. */
|
||||||
/* SDL_CalculateAudioSpec(this->spec); MOD */
|
SDL_CalculateAudioSpec(&this->spec);
|
||||||
switch (this->spec.format) {
|
|
||||||
case AUDIO_U8:
|
|
||||||
this->spec.silence = 0x80;
|
|
||||||
break;
|
|
||||||
default:
|
|
||||||
this->spec.silence = 0x00;
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
this->spec.size = SDL_AUDIO_BITSIZE(this->spec.format) / 8;
|
|
||||||
this->spec.size *= this->spec.channels;
|
|
||||||
this->spec.size *= this->spec.samples;
|
|
||||||
|
|
||||||
/* ========================================== */
|
|
||||||
|
|
||||||
/* Allocate the mixing buffer. Its size and starting address must
|
/* Allocate the mixing buffer. Its size and starting address must
|
||||||
be a multiple of 64 bytes. Our sample count is already a multiple of
|
be a multiple of 64 bytes. Our sample count is already a multiple of
|
||||||
|
|||||||
Reference in New Issue
Block a user