mirror of
https://github.com/mauiaaron/apple2.git
synced 2025-01-01 07:30:45 +00:00
Refactor : LPVOID > void*
This commit is contained in:
parent
e63afea069
commit
92f21a65ca
@ -34,10 +34,10 @@ typedef struct IDirectSoundBuffer {
|
||||
int (*Play)(void* _this, unsigned long dwReserved1, unsigned long dwReserved2, unsigned long dwFlags);
|
||||
|
||||
// This method obtains a valid write pointer to the sound buffer's audio data
|
||||
int (*Lock)(void* _this, unsigned long dwWriteCursor, unsigned long dwWriteBytes, LPVOID* lplpvAudioPtr1, LPDWORD lpdwAudioBytes1, LPVOID* lplpvAudioPtr2, LPDWORD lpdwAudioBytes2, unsigned long dwFlags);
|
||||
int (*Lock)(void* _this, unsigned long dwWriteCursor, unsigned long dwWriteBytes, void **lplpvAudioPtr1, LPDWORD lpdwAudioBytes1, void **lplpvAudioPtr2, LPDWORD lpdwAudioBytes2, unsigned long dwFlags);
|
||||
|
||||
// This method releases a locked sound buffer.
|
||||
int (*Unlock)(void* _this, LPVOID lpvAudioPtr1, unsigned long dwAudioBytes1, LPVOID lpvAudioPtr2, unsigned long dwAudioBytes2);
|
||||
int (*Unlock)(void* _this, void *lpvAudioPtr1, unsigned long dwAudioBytes1, void *lpvAudioPtr2, unsigned long dwAudioBytes2);
|
||||
|
||||
int (*GetStatus)(void* _this, LPDWORD lpdwStatus);
|
||||
|
||||
|
@ -263,9 +263,9 @@ uint32_t g_uTimer1IrqCount = 0; // DEBUG
|
||||
|
||||
// Forward refs:
|
||||
#ifdef APPLE2IX
|
||||
static void* SSI263Thread(LPVOID);
|
||||
static void* SSI263Thread(void *);
|
||||
#else
|
||||
static unsigned long SSI263Thread(LPVOID);
|
||||
static unsigned long SSI263Thread(void *);
|
||||
#endif
|
||||
static void Votrax_Write(uint8_t nDevice, uint8_t nValue);
|
||||
|
||||
@ -1047,9 +1047,9 @@ static void MB_Update()
|
||||
//-----------------------------------------------------------------------------
|
||||
|
||||
#ifdef APPLE2IX
|
||||
static void* SSI263Thread(LPVOID lpParameter)
|
||||
static void* SSI263Thread(void *lpParameter)
|
||||
#else
|
||||
static unsigned long SSI263Thread(LPVOID lpParameter)
|
||||
static unsigned long SSI263Thread(void *lpParameter)
|
||||
#endif
|
||||
{
|
||||
while(1)
|
||||
@ -1431,7 +1431,7 @@ static bool MB_DSInit()
|
||||
#ifdef APPLE2IX
|
||||
// Assume no way to get notification of sound finished, instead we will poll from mockingboard thread ...
|
||||
#else
|
||||
hr = SSI263Voice[i].lpDSBvoice->QueryInterface(IID_IDirectSoundNotify, (LPVOID *)&SSI263Voice[i].lpDSNotify);
|
||||
hr = SSI263Voice[i].lpDSBvoice->QueryInterface(IID_IDirectSoundNotify, (void **)&SSI263Voice[i].lpDSNotify);
|
||||
//LogFileOutput("MB_DSInit: (%02d) QueryInterface(), hr=0x%08X\n", i, hr); // WARNING: Lock acquired && doing heavy-weight logging
|
||||
if(FAILED(hr))
|
||||
{
|
||||
@ -1893,7 +1893,7 @@ void mb_io_initialize(unsigned int slot4, unsigned int slot5)
|
||||
|
||||
//typedef uint8_t (*iofunction)(uint16_t nPC, uint16_t nAddr, uint8_t nWriteFlag, uint8_t nWriteValue, unsigned long nCyclesLeft);
|
||||
typedef void (*iofunction)();
|
||||
static void RegisterIoHandler(UINT uSlot, iofunction IOReadC0, iofunction IOWriteC0, iofunction IOReadCx, iofunction IOWriteCx, LPVOID unused_lpSlotParameter, uint8_t* unused_pExpansionRom)
|
||||
static void RegisterIoHandler(UINT uSlot, iofunction IOReadC0, iofunction IOWriteC0, iofunction IOReadCx, iofunction IOWriteCx, void *unused_lpSlotParameter, uint8_t* unused_pExpansionRom)
|
||||
{
|
||||
|
||||
// card softswitches
|
||||
|
@ -730,8 +730,8 @@ static long OpenALCreateSoundBuffer(ALBufferParamsStruct *params, ALSoundBufferS
|
||||
(*soundbuf_struct)->Stop = (int (*)(void *))ALStop;
|
||||
(*soundbuf_struct)->Restore = (int (*)(void *))ALRestore;
|
||||
(*soundbuf_struct)->Play = (int (*)(void *, unsigned long, unsigned long, unsigned long))ALPlay;
|
||||
(*soundbuf_struct)->Lock = (int (*)(void *, unsigned long, unsigned long, LPVOID *, LPDWORD, LPVOID *, LPDWORD, unsigned long))ALBegin;
|
||||
(*soundbuf_struct)->Unlock = (int (*)(void *, LPVOID, unsigned long, LPVOID, unsigned long))ALCommit;
|
||||
(*soundbuf_struct)->Lock = (int (*)(void *, unsigned long, unsigned long, void **, LPDWORD, void **, LPDWORD, unsigned long))ALBegin;
|
||||
(*soundbuf_struct)->Unlock = (int (*)(void *, void *, unsigned long, void *, unsigned long))ALCommit;
|
||||
(*soundbuf_struct)->GetStatus = (int (*)(void *, LPDWORD))ALGetStatus;
|
||||
|
||||
// mockingboard-specific hacks
|
||||
|
@ -12,7 +12,7 @@
|
||||
#include "common.h"
|
||||
#include "audio/win-shim.h"
|
||||
|
||||
pthread_t CreateThread(void* unused_lpThreadAttributes, int unused_dwStackSize, LPTHREAD_START_ROUTINE lpStartRoutine, LPVOID lpParameter, unsigned long unused_dwCreationFlags, LPDWORD lpThreadId)
|
||||
pthread_t CreateThread(void* unused_lpThreadAttributes, int unused_dwStackSize, LPTHREAD_START_ROUTINE lpStartRoutine, void *lpParameter, unsigned long unused_dwCreationFlags, LPDWORD lpThreadId)
|
||||
{
|
||||
pthread_t a_thread = 0;
|
||||
int err = 0;
|
||||
|
@ -27,8 +27,6 @@
|
||||
|
||||
typedef unsigned int UINT;
|
||||
|
||||
typedef void *LPVOID;
|
||||
typedef void *LPDVOID;
|
||||
typedef unsigned long *LPDWORD;
|
||||
|
||||
#if !defined(TRUE)
|
||||
@ -48,9 +46,9 @@ typedef void *IUnknown;
|
||||
|
||||
#define LogFileOutput(...) LOG(__VA_ARGS__)
|
||||
|
||||
typedef LPVOID (*LPTHREAD_START_ROUTINE)(LPVOID unused);
|
||||
typedef void *(*LPTHREAD_START_ROUTINE)(void *unused);
|
||||
|
||||
pthread_t CreateThread(void* unused_lpThreadAttributes, int unused_dwStackSize, LPTHREAD_START_ROUTINE lpStartAddress, LPVOID lpParameter, unsigned long unused_dwCreationFlags, LPDWORD lpThreadId);
|
||||
pthread_t CreateThread(void* unused_lpThreadAttributes, int unused_dwStackSize, LPTHREAD_START_ROUTINE lpStartAddress, void *lpParameter, unsigned long unused_dwCreationFlags, LPDWORD lpThreadId);
|
||||
|
||||
#define THREAD_PRIORITY_NORMAL 0
|
||||
#define THREAD_PRIORITY_TIME_CRITICAL 15
|
||||
|
Loading…
Reference in New Issue
Block a user