aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Alc/ALc.c2
-rw-r--r--OpenAL32/Include/alMain.h8
-rw-r--r--OpenAL32/alSource.c4
3 files changed, 6 insertions, 8 deletions
diff --git a/Alc/ALc.c b/Alc/ALc.c
index b4a06bfc..4142a99d 100644
--- a/Alc/ALc.c
+++ b/Alc/ALc.c
@@ -1400,7 +1400,7 @@ ALint64 ALCdevice_GetLatencyDefault(ALCdevice *UNUSED(device))
}
-ALint64 alcGetLatency(ALCdevice *device)
+ALint64 ALCdevice_GetLatency(ALCdevice *device)
{
return VCALL0(device->Backend,getLatency)();
}
diff --git a/OpenAL32/Include/alMain.h b/OpenAL32/Include/alMain.h
index 93679824..de6f2613 100644
--- a/OpenAL32/Include/alMain.h
+++ b/OpenAL32/Include/alMain.h
@@ -307,8 +307,7 @@ enum DevFmtChannels {
ALuint BytesFromDevFmt(enum DevFmtType type);
ALuint ChannelsFromDevFmt(enum DevFmtChannels chans);
-static inline ALuint FrameSizeFromDevFmt(enum DevFmtChannels chans,
- enum DevFmtType type)
+static inline ALuint FrameSizeFromDevFmt(enum DevFmtChannels chans, enum DevFmtType type)
{
return ChannelsFromDevFmt(chans) * BytesFromDevFmt(type);
}
@@ -436,9 +435,6 @@ struct ALCdevice_struct
#define MIXER_THREAD_NAME "alsoft-mixer"
-ALint64 alcGetLatency(ALCdevice *device);
-
-
static inline struct ALbuffer *LookupBuffer(ALCdevice *device, ALuint id)
{ return (struct ALbuffer*)LookupUIntMapKey(&device->BufferMap, id); }
static inline struct ALeffect *LookupEffect(ALCdevice *device, ALuint id)
@@ -514,6 +510,8 @@ ALint64 ALCdevice_GetLatencyDefault(ALCdevice *device);
void ALCdevice_Lock(ALCdevice *device);
void ALCdevice_Unlock(ALCdevice *device);
+ALint64 ALCdevice_GetLatency(ALCdevice *device);
+
void LockContext(ALCcontext *context);
void UnlockContext(ALCcontext *context);
diff --git a/OpenAL32/alSource.c b/OpenAL32/alSource.c
index e017ff62..cae60cc2 100644
--- a/OpenAL32/alSource.c
+++ b/OpenAL32/alSource.c
@@ -947,7 +947,7 @@ static ALboolean GetSourcedv(const ALsource *Source, ALCcontext *Context, SrcFlo
case AL_SEC_OFFSET_LATENCY_SOFT:
LockContext(Context);
values[0] = GetSourceSecOffset(Source);
- values[1] = (ALdouble)alcGetLatency(Context->Device) /
+ values[1] = (ALdouble)ALCdevice_GetLatency(Context->Device) /
1000000000.0;
UnlockContext(Context);
return AL_TRUE;
@@ -1133,7 +1133,7 @@ static ALboolean GetSourcei64v(const ALsource *Source, ALCcontext *Context, SrcI
case AL_SAMPLE_OFFSET_LATENCY_SOFT:
LockContext(Context);
values[0] = GetSourceOffset(Source);
- values[1] = alcGetLatency(Context->Device);
+ values[1] = ALCdevice_GetLatency(Context->Device);
UnlockContext(Context);
return AL_TRUE;