Remove _THIS in src/audio/

This commit is contained in:
Sylvain
2023-05-09 13:23:33 +02:00
committed by Ryan C. Gordon
parent 81ff49f4b5
commit 04e17d4e46
48 changed files with 1352 additions and 1425 deletions

View File

@@ -40,12 +40,12 @@
#define DISKENVR_IODELAY "SDL_DISKAUDIODELAY"
/* This function waits until it is possible to write a full sound buffer */
static void DISKAUDIO_WaitDevice(_THIS)
static void DISKAUDIO_WaitDevice(SDL_AudioDevice *_this)
{
SDL_Delay(_this->hidden->io_delay);
}
static void DISKAUDIO_PlayDevice(_THIS)
static void DISKAUDIO_PlayDevice(SDL_AudioDevice *_this)
{
const Sint64 written = SDL_RWwrite(_this->hidden->io,
_this->hidden->mixbuf,
@@ -60,12 +60,12 @@ static void DISKAUDIO_PlayDevice(_THIS)
#endif
}
static Uint8 *DISKAUDIO_GetDeviceBuf(_THIS)
static Uint8 *DISKAUDIO_GetDeviceBuf(SDL_AudioDevice *_this)
{
return _this->hidden->mixbuf;
}
static int DISKAUDIO_CaptureFromDevice(_THIS, void *buffer, int buflen)
static int DISKAUDIO_CaptureFromDevice(SDL_AudioDevice *_this, void *buffer, int buflen)
{
struct SDL_PrivateAudioData *h = _this->hidden;
const int origbuflen = buflen;
@@ -88,12 +88,12 @@ static int DISKAUDIO_CaptureFromDevice(_THIS, void *buffer, int buflen)
return origbuflen;
}
static void DISKAUDIO_FlushCapture(_THIS)
static void DISKAUDIO_FlushCapture(SDL_AudioDevice *_this)
{
/* no op...we don't advance the file pointer or anything. */
}
static void DISKAUDIO_CloseDevice(_THIS)
static void DISKAUDIO_CloseDevice(SDL_AudioDevice *_this)
{
if (_this->hidden->io != NULL) {
SDL_RWclose(_this->hidden->io);
@@ -113,7 +113,7 @@ static const char *get_filename(const SDL_bool iscapture, const char *devname)
return devname;
}
static int DISKAUDIO_OpenDevice(_THIS, const char *devname)
static int DISKAUDIO_OpenDevice(SDL_AudioDevice *_this, const char *devname)
{
void *handle = _this->handle;
/* handle != NULL means "user specified the placeholder name on the fake detected device list" */