diff options
author | Chris Robinson <[email protected]> | 2018-10-30 09:31:52 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2018-10-30 09:31:52 -0700 |
commit | e2a1dd4503be8cd1280be8d34826c4858c4d6ed2 (patch) | |
tree | 19b1aa99abc2b41ed23cfd642cf3b916eaf2dcb2 /router/router.h | |
parent | ce212c911c8634fb9ccd9944b00dcd6c2b28d516 (diff) |
Use std::wstring in place of some fixed WCHAR arrays
Diffstat (limited to 'router/router.h')
-rw-r--r-- | router/router.h | 203 |
1 files changed, 102 insertions, 101 deletions
diff --git a/router/router.h b/router/router.h index c7d2c89e..3ac0ab40 100644 --- a/router/router.h +++ b/router/router.h @@ -9,6 +9,7 @@ #include <vector> #include <atomic> +#include <string> #include "AL/alc.h" #include "AL/al.h" @@ -35,107 +36,107 @@ extern "C" { #define MAKE_ALC_VER(major, minor) (((major)<<8) | (minor)) typedef struct DriverIface { - WCHAR Name[32]; - HMODULE Module; - int ALCVer; - - LPALCCREATECONTEXT alcCreateContext; - LPALCMAKECONTEXTCURRENT alcMakeContextCurrent; - LPALCPROCESSCONTEXT alcProcessContext; - LPALCSUSPENDCONTEXT alcSuspendContext; - LPALCDESTROYCONTEXT alcDestroyContext; - LPALCGETCURRENTCONTEXT alcGetCurrentContext; - LPALCGETCONTEXTSDEVICE alcGetContextsDevice; - LPALCOPENDEVICE alcOpenDevice; - LPALCCLOSEDEVICE alcCloseDevice; - LPALCGETERROR alcGetError; - LPALCISEXTENSIONPRESENT alcIsExtensionPresent; - LPALCGETPROCADDRESS alcGetProcAddress; - LPALCGETENUMVALUE alcGetEnumValue; - LPALCGETSTRING alcGetString; - LPALCGETINTEGERV alcGetIntegerv; - LPALCCAPTUREOPENDEVICE alcCaptureOpenDevice; - LPALCCAPTURECLOSEDEVICE alcCaptureCloseDevice; - LPALCCAPTURESTART alcCaptureStart; - LPALCCAPTURESTOP alcCaptureStop; - LPALCCAPTURESAMPLES alcCaptureSamples; - - PFNALCSETTHREADCONTEXTPROC alcSetThreadContext; - PFNALCGETTHREADCONTEXTPROC alcGetThreadContext; - - LPALENABLE alEnable; - LPALDISABLE alDisable; - LPALISENABLED alIsEnabled; - LPALGETSTRING alGetString; - LPALGETBOOLEANV alGetBooleanv; - LPALGETINTEGERV alGetIntegerv; - LPALGETFLOATV alGetFloatv; - LPALGETDOUBLEV alGetDoublev; - LPALGETBOOLEAN alGetBoolean; - LPALGETINTEGER alGetInteger; - LPALGETFLOAT alGetFloat; - LPALGETDOUBLE alGetDouble; - LPALGETERROR alGetError; - LPALISEXTENSIONPRESENT alIsExtensionPresent; - LPALGETPROCADDRESS alGetProcAddress; - LPALGETENUMVALUE alGetEnumValue; - LPALLISTENERF alListenerf; - LPALLISTENER3F alListener3f; - LPALLISTENERFV alListenerfv; - LPALLISTENERI alListeneri; - LPALLISTENER3I alListener3i; - LPALLISTENERIV alListeneriv; - LPALGETLISTENERF alGetListenerf; - LPALGETLISTENER3F alGetListener3f; - LPALGETLISTENERFV alGetListenerfv; - LPALGETLISTENERI alGetListeneri; - LPALGETLISTENER3I alGetListener3i; - LPALGETLISTENERIV alGetListeneriv; - LPALGENSOURCES alGenSources; - LPALDELETESOURCES alDeleteSources; - LPALISSOURCE alIsSource; - LPALSOURCEF alSourcef; - LPALSOURCE3F alSource3f; - LPALSOURCEFV alSourcefv; - LPALSOURCEI alSourcei; - LPALSOURCE3I alSource3i; - LPALSOURCEIV alSourceiv; - LPALGETSOURCEF alGetSourcef; - LPALGETSOURCE3F alGetSource3f; - LPALGETSOURCEFV alGetSourcefv; - LPALGETSOURCEI alGetSourcei; - LPALGETSOURCE3I alGetSource3i; - LPALGETSOURCEIV alGetSourceiv; - LPALSOURCEPLAYV alSourcePlayv; - LPALSOURCESTOPV alSourceStopv; - LPALSOURCEREWINDV alSourceRewindv; - LPALSOURCEPAUSEV alSourcePausev; - LPALSOURCEPLAY alSourcePlay; - LPALSOURCESTOP alSourceStop; - LPALSOURCEREWIND alSourceRewind; - LPALSOURCEPAUSE alSourcePause; - LPALSOURCEQUEUEBUFFERS alSourceQueueBuffers; - LPALSOURCEUNQUEUEBUFFERS alSourceUnqueueBuffers; - LPALGENBUFFERS alGenBuffers; - LPALDELETEBUFFERS alDeleteBuffers; - LPALISBUFFER alIsBuffer; - LPALBUFFERF alBufferf; - LPALBUFFER3F alBuffer3f; - LPALBUFFERFV alBufferfv; - LPALBUFFERI alBufferi; - LPALBUFFER3I alBuffer3i; - LPALBUFFERIV alBufferiv; - LPALGETBUFFERF alGetBufferf; - LPALGETBUFFER3F alGetBuffer3f; - LPALGETBUFFERFV alGetBufferfv; - LPALGETBUFFERI alGetBufferi; - LPALGETBUFFER3I alGetBuffer3i; - LPALGETBUFFERIV alGetBufferiv; - LPALBUFFERDATA alBufferData; - LPALDOPPLERFACTOR alDopplerFactor; - LPALDOPPLERVELOCITY alDopplerVelocity; - LPALSPEEDOFSOUND alSpeedOfSound; - LPALDISTANCEMODEL alDistanceModel; + std::wstring Name; + HMODULE Module{nullptr}; + int ALCVer{0}; + + LPALCCREATECONTEXT alcCreateContext{nullptr}; + LPALCMAKECONTEXTCURRENT alcMakeContextCurrent{nullptr}; + LPALCPROCESSCONTEXT alcProcessContext{nullptr}; + LPALCSUSPENDCONTEXT alcSuspendContext{nullptr}; + LPALCDESTROYCONTEXT alcDestroyContext{nullptr}; + LPALCGETCURRENTCONTEXT alcGetCurrentContext{nullptr}; + LPALCGETCONTEXTSDEVICE alcGetContextsDevice{nullptr}; + LPALCOPENDEVICE alcOpenDevice{nullptr}; + LPALCCLOSEDEVICE alcCloseDevice{nullptr}; + LPALCGETERROR alcGetError{nullptr}; + LPALCISEXTENSIONPRESENT alcIsExtensionPresent{nullptr}; + LPALCGETPROCADDRESS alcGetProcAddress{nullptr}; + LPALCGETENUMVALUE alcGetEnumValue{nullptr}; + LPALCGETSTRING alcGetString{nullptr}; + LPALCGETINTEGERV alcGetIntegerv{nullptr}; + LPALCCAPTUREOPENDEVICE alcCaptureOpenDevice{nullptr}; + LPALCCAPTURECLOSEDEVICE alcCaptureCloseDevice{nullptr}; + LPALCCAPTURESTART alcCaptureStart{nullptr}; + LPALCCAPTURESTOP alcCaptureStop{nullptr}; + LPALCCAPTURESAMPLES alcCaptureSamples{nullptr}; + + PFNALCSETTHREADCONTEXTPROC alcSetThreadContext{nullptr}; + PFNALCGETTHREADCONTEXTPROC alcGetThreadContext{nullptr}; + + LPALENABLE alEnable{nullptr}; + LPALDISABLE alDisable{nullptr}; + LPALISENABLED alIsEnabled{nullptr}; + LPALGETSTRING alGetString{nullptr}; + LPALGETBOOLEANV alGetBooleanv{nullptr}; + LPALGETINTEGERV alGetIntegerv{nullptr}; + LPALGETFLOATV alGetFloatv{nullptr}; + LPALGETDOUBLEV alGetDoublev{nullptr}; + LPALGETBOOLEAN alGetBoolean{nullptr}; + LPALGETINTEGER alGetInteger{nullptr}; + LPALGETFLOAT alGetFloat{nullptr}; + LPALGETDOUBLE alGetDouble{nullptr}; + LPALGETERROR alGetError{nullptr}; + LPALISEXTENSIONPRESENT alIsExtensionPresent{nullptr}; + LPALGETPROCADDRESS alGetProcAddress{nullptr}; + LPALGETENUMVALUE alGetEnumValue{nullptr}; + LPALLISTENERF alListenerf{nullptr}; + LPALLISTENER3F alListener3f{nullptr}; + LPALLISTENERFV alListenerfv{nullptr}; + LPALLISTENERI alListeneri{nullptr}; + LPALLISTENER3I alListener3i{nullptr}; + LPALLISTENERIV alListeneriv{nullptr}; + LPALGETLISTENERF alGetListenerf{nullptr}; + LPALGETLISTENER3F alGetListener3f{nullptr}; + LPALGETLISTENERFV alGetListenerfv{nullptr}; + LPALGETLISTENERI alGetListeneri{nullptr}; + LPALGETLISTENER3I alGetListener3i{nullptr}; + LPALGETLISTENERIV alGetListeneriv{nullptr}; + LPALGENSOURCES alGenSources{nullptr}; + LPALDELETESOURCES alDeleteSources{nullptr}; + LPALISSOURCE alIsSource{nullptr}; + LPALSOURCEF alSourcef{nullptr}; + LPALSOURCE3F alSource3f{nullptr}; + LPALSOURCEFV alSourcefv{nullptr}; + LPALSOURCEI alSourcei{nullptr}; + LPALSOURCE3I alSource3i{nullptr}; + LPALSOURCEIV alSourceiv{nullptr}; + LPALGETSOURCEF alGetSourcef{nullptr}; + LPALGETSOURCE3F alGetSource3f{nullptr}; + LPALGETSOURCEFV alGetSourcefv{nullptr}; + LPALGETSOURCEI alGetSourcei{nullptr}; + LPALGETSOURCE3I alGetSource3i{nullptr}; + LPALGETSOURCEIV alGetSourceiv{nullptr}; + LPALSOURCEPLAYV alSourcePlayv{nullptr}; + LPALSOURCESTOPV alSourceStopv{nullptr}; + LPALSOURCEREWINDV alSourceRewindv{nullptr}; + LPALSOURCEPAUSEV alSourcePausev{nullptr}; + LPALSOURCEPLAY alSourcePlay{nullptr}; + LPALSOURCESTOP alSourceStop{nullptr}; + LPALSOURCEREWIND alSourceRewind{nullptr}; + LPALSOURCEPAUSE alSourcePause{nullptr}; + LPALSOURCEQUEUEBUFFERS alSourceQueueBuffers{nullptr}; + LPALSOURCEUNQUEUEBUFFERS alSourceUnqueueBuffers{nullptr}; + LPALGENBUFFERS alGenBuffers{nullptr}; + LPALDELETEBUFFERS alDeleteBuffers{nullptr}; + LPALISBUFFER alIsBuffer{nullptr}; + LPALBUFFERF alBufferf{nullptr}; + LPALBUFFER3F alBuffer3f{nullptr}; + LPALBUFFERFV alBufferfv{nullptr}; + LPALBUFFERI alBufferi{nullptr}; + LPALBUFFER3I alBuffer3i{nullptr}; + LPALBUFFERIV alBufferiv{nullptr}; + LPALGETBUFFERF alGetBufferf{nullptr}; + LPALGETBUFFER3F alGetBuffer3f{nullptr}; + LPALGETBUFFERFV alGetBufferfv{nullptr}; + LPALGETBUFFERI alGetBufferi{nullptr}; + LPALGETBUFFER3I alGetBuffer3i{nullptr}; + LPALGETBUFFERIV alGetBufferiv{nullptr}; + LPALBUFFERDATA alBufferData{nullptr}; + LPALDOPPLERFACTOR alDopplerFactor{nullptr}; + LPALDOPPLERVELOCITY alDopplerVelocity{nullptr}; + LPALSPEEDOFSOUND alSpeedOfSound{nullptr}; + LPALDISTANCEMODEL alDistanceModel{nullptr}; } DriverIface; extern std::vector<DriverIface> DriverList; |