mirror of
git://source.winehq.org/git/wine.git
synced 2024-09-02 19:03:38 +00:00
dsound: Win64 printf format warning fixes.
This commit is contained in:
parent
0f08667c8a
commit
26bd2ec9c3
|
@ -6,7 +6,6 @@ MODULE = dsound.dll
|
|||
IMPORTLIB = libdsound.$(IMPLIBEXT)
|
||||
IMPORTS = winmm ole32 user32 advapi32 kernel32 ntdll
|
||||
EXTRALIBS = -ldxguid -luuid
|
||||
EXTRADEFS = -DWINE_NO_LONG_AS_INT
|
||||
|
||||
C_SRCS = \
|
||||
buffer.c \
|
||||
|
|
|
@ -72,7 +72,7 @@ static ULONG WINAPI IDirectSoundNotifyImpl_AddRef(LPDIRECTSOUNDNOTIFY iface)
|
|||
{
|
||||
IDirectSoundNotifyImpl *This = (IDirectSoundNotifyImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -80,7 +80,7 @@ static ULONG WINAPI IDirectSoundNotifyImpl_Release(LPDIRECTSOUNDNOTIFY iface)
|
|||
{
|
||||
IDirectSoundNotifyImpl *This = (IDirectSoundNotifyImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
IDirectSoundBuffer_Release((LPDIRECTSOUNDBUFFER)This->dsb);
|
||||
|
@ -95,7 +95,7 @@ static HRESULT WINAPI IDirectSoundNotifyImpl_SetNotificationPositions(
|
|||
LPDIRECTSOUNDNOTIFY iface,DWORD howmuch,LPCDSBPOSITIONNOTIFY notify
|
||||
) {
|
||||
IDirectSoundNotifyImpl *This = (IDirectSoundNotifyImpl *)iface;
|
||||
TRACE("(%p,0x%08lx,%p)\n",This,howmuch,notify);
|
||||
TRACE("(%p,0x%08x,%p)\n",This,howmuch,notify);
|
||||
|
||||
if (howmuch > 0 && notify == NULL) {
|
||||
WARN("invalid parameter: notify == NULL\n");
|
||||
|
@ -105,7 +105,7 @@ static HRESULT WINAPI IDirectSoundNotifyImpl_SetNotificationPositions(
|
|||
if (TRACE_ON(dsound)) {
|
||||
unsigned int i;
|
||||
for (i=0;i<howmuch;i++)
|
||||
TRACE("notify at %ld to %p\n",
|
||||
TRACE("notify at %d to %p\n",
|
||||
notify[i].dwOffset,notify[i].hEventNotify);
|
||||
}
|
||||
|
||||
|
@ -204,15 +204,15 @@ static HRESULT WINAPI IDirectSoundBufferImpl_SetVolume(
|
|||
LONG oldVol;
|
||||
HRESULT hres = DS_OK;
|
||||
|
||||
TRACE("(%p,%ld)\n",This,vol);
|
||||
TRACE("(%p,%d)\n",This,vol);
|
||||
|
||||
if (!(This->dsbd.dwFlags & DSBCAPS_CTRLVOLUME)) {
|
||||
WARN("control unavailable: This->dsbd.dwFlags = 0x%08lx\n", This->dsbd.dwFlags);
|
||||
WARN("control unavailable: This->dsbd.dwFlags = 0x%08x\n", This->dsbd.dwFlags);
|
||||
return DSERR_CONTROLUNAVAIL;
|
||||
}
|
||||
|
||||
if ((vol > DSBVOLUME_MAX) || (vol < DSBVOLUME_MIN)) {
|
||||
WARN("invalid parameter: vol = %ld\n", vol);
|
||||
WARN("invalid parameter: vol = %d\n", vol);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -271,7 +271,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_SetFrequency(
|
|||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
DWORD oldFreq;
|
||||
|
||||
TRACE("(%p,%ld)\n",This,freq);
|
||||
TRACE("(%p,%d)\n",This,freq);
|
||||
|
||||
if (!(This->dsbd.dwFlags & DSBCAPS_CTRLFREQUENCY)) {
|
||||
WARN("control unavailable\n");
|
||||
|
@ -282,7 +282,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_SetFrequency(
|
|||
freq = This->pwfx->nSamplesPerSec;
|
||||
|
||||
if ((freq < DSBFREQUENCY_MIN) || (freq > DSBFREQUENCY_MAX)) {
|
||||
WARN("invalid parameter: freq = %ld\n", freq);
|
||||
WARN("invalid parameter: freq = %d\n", freq);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -310,7 +310,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_Play(
|
|||
) {
|
||||
HRESULT hres = DS_OK;
|
||||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
TRACE("(%p,%08lx,%08lx,%08lx)\n",This,reserved1,reserved2,flags);
|
||||
TRACE("(%p,%08x,%08x,%08x)\n",This,reserved1,reserved2,flags);
|
||||
|
||||
/* **** */
|
||||
EnterCriticalSection(&(This->lock));
|
||||
|
@ -368,7 +368,7 @@ static ULONG WINAPI IDirectSoundBufferImpl_AddRef(LPDIRECTSOUNDBUFFER8 iface)
|
|||
{
|
||||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -376,7 +376,7 @@ static ULONG WINAPI IDirectSoundBufferImpl_Release(LPDIRECTSOUNDBUFFER8 iface)
|
|||
{
|
||||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
DirectSoundDevice_RemoveBuffer(This->device, This);
|
||||
|
@ -415,7 +415,7 @@ DWORD DSOUND_CalcPlayPosition(IDirectSoundBufferImpl *This, DWORD pplay, DWORD p
|
|||
DWORD bplay = This->buf_mixpos;
|
||||
DWORD pmix = This->primary_mixpos;
|
||||
DirectSoundDevice * device = This->device;
|
||||
TRACE("(%p, pplay=%lu, pwrite=%lu)\n", This, pplay, pwrite);
|
||||
TRACE("(%p, pplay=%u, pwrite=%u)\n", This, pplay, pwrite);
|
||||
|
||||
/* the actual primary play position (pplay) is always behind last mixed (pmix),
|
||||
* unless the computer is too slow or something */
|
||||
|
@ -426,17 +426,17 @@ DWORD DSOUND_CalcPlayPosition(IDirectSoundBufferImpl *This, DWORD pplay, DWORD p
|
|||
if (pwrite < pplay) pwrite += device->buflen; /* wraparound */
|
||||
pwrite -= pplay;
|
||||
if (pmix > (ds_snd_queue_max * device->fraglen + pwrite + device->writelead)) {
|
||||
WARN("detected an underrun: primary queue was %ld\n",pmix);
|
||||
WARN("detected an underrun: primary queue was %d\n",pmix);
|
||||
pmix = 0;
|
||||
}
|
||||
/* divide the offset by its sample size */
|
||||
pmix /= device->pwfx->nBlockAlign;
|
||||
TRACE("primary back-samples=%ld\n",pmix);
|
||||
TRACE("primary back-samples=%d\n",pmix);
|
||||
/* adjust for our frequency */
|
||||
pmix = (pmix * This->freqAdjust) >> DSOUND_FREQSHIFT;
|
||||
/* multiply by our own sample size */
|
||||
pmix *= This->pwfx->nBlockAlign;
|
||||
TRACE("this back-offset=%ld\n", pmix);
|
||||
TRACE("this back-offset=%d\n", pmix);
|
||||
/* subtract from our last mixed position */
|
||||
while (bplay < pmix) bplay += This->buflen; /* wraparound */
|
||||
bplay -= pmix;
|
||||
|
@ -502,7 +502,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_GetCurrentPosition(
|
|||
}
|
||||
if (playpos)
|
||||
This->last_playpos = *playpos;
|
||||
TRACE("playpos = %ld, writepos = %ld (%p, time=%ld)\n", playpos?*playpos:0, writepos?*writepos:0, This, GetTickCount());
|
||||
TRACE("playpos = %d, writepos = %d (%p, time=%d)\n", playpos?*playpos:0, writepos?*writepos:0, This, GetTickCount());
|
||||
return DS_OK;
|
||||
}
|
||||
|
||||
|
@ -510,7 +510,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_GetStatus(
|
|||
LPDIRECTSOUNDBUFFER8 iface,LPDWORD status
|
||||
) {
|
||||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
TRACE("(%p,%p), thread is %04lx\n",This,status,GetCurrentThreadId());
|
||||
TRACE("(%p,%p), thread is %04x\n",This,status,GetCurrentThreadId());
|
||||
|
||||
if (status == NULL) {
|
||||
WARN("invalid parameter: status = NULL\n");
|
||||
|
@ -524,7 +524,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_GetStatus(
|
|||
*status |= DSBSTATUS_LOOPING;
|
||||
}
|
||||
|
||||
TRACE("status=%lx\n", *status);
|
||||
TRACE("status=%x\n", *status);
|
||||
return DS_OK;
|
||||
}
|
||||
|
||||
|
@ -537,7 +537,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_GetFormat(
|
|||
{
|
||||
DWORD size;
|
||||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
TRACE("(%p,%p,%ld,%p)\n",This,lpwf,wfsize,wfwritten);
|
||||
TRACE("(%p,%p,%d,%p)\n",This,lpwf,wfsize,wfwritten);
|
||||
|
||||
size = sizeof(WAVEFORMATEX) + This->pwfx->cbSize;
|
||||
|
||||
|
@ -570,7 +570,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_Lock(
|
|||
HRESULT hres = DS_OK;
|
||||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
|
||||
TRACE("(%p,%ld,%ld,%p,%p,%p,%p,0x%08lx) at %ld\n",
|
||||
TRACE("(%p,%d,%d,%p,%p,%p,%p,0x%08x) at %d\n",
|
||||
This,
|
||||
writecursor,
|
||||
writebytes,
|
||||
|
@ -597,13 +597,13 @@ static HRESULT WINAPI IDirectSoundBufferImpl_Lock(
|
|||
writebytes = This->buflen;
|
||||
|
||||
if (writecursor >= This->buflen) {
|
||||
WARN("Invalid parameter, writecursor: %lu >= buflen: %lu\n",
|
||||
WARN("Invalid parameter, writecursor: %u >= buflen: %u\n",
|
||||
writecursor, This->buflen);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
if (writebytes > This->buflen) {
|
||||
WARN("Invalid parameter, writebytes: %lu > buflen: %lu\n",
|
||||
WARN("Invalid parameter, writebytes: %u > buflen: %u\n",
|
||||
writebytes, This->buflen);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
@ -641,7 +641,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_Lock(
|
|||
*(LPBYTE*)lplpaudioptr2 = NULL;
|
||||
if (audiobytes2)
|
||||
*audiobytes2 = 0;
|
||||
TRACE("->%ld.0\n",writebytes);
|
||||
TRACE("->%d.0\n",writebytes);
|
||||
} else {
|
||||
*(LPBYTE*)lplpaudioptr1 = This->buffer->memory+writecursor;
|
||||
*audiobytes1 = This->buflen-writecursor;
|
||||
|
@ -649,7 +649,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_Lock(
|
|||
*(LPBYTE*)lplpaudioptr2 = This->buffer->memory;
|
||||
if (audiobytes2)
|
||||
*audiobytes2 = writebytes-(This->buflen-writecursor);
|
||||
TRACE("->%ld.%ld\n",*audiobytes1,audiobytes2?*audiobytes2:0);
|
||||
TRACE("->%d.%d\n",*audiobytes1,audiobytes2?*audiobytes2:0);
|
||||
}
|
||||
if (This->state == STATE_PLAYING) {
|
||||
/* if the segment between playpos and buf_mixpos is touched,
|
||||
|
@ -682,7 +682,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_SetCurrentPosition(
|
|||
) {
|
||||
HRESULT hres = DS_OK;
|
||||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
TRACE("(%p,%ld)\n",This,newpos);
|
||||
TRACE("(%p,%d)\n",This,newpos);
|
||||
|
||||
/* **** */
|
||||
EnterCriticalSection(&(This->lock));
|
||||
|
@ -707,10 +707,10 @@ static HRESULT WINAPI IDirectSoundBufferImpl_SetPan(
|
|||
HRESULT hres = DS_OK;
|
||||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
|
||||
TRACE("(%p,%ld)\n",This,pan);
|
||||
TRACE("(%p,%d)\n",This,pan);
|
||||
|
||||
if ((pan > DSBPAN_RIGHT) || (pan < DSBPAN_LEFT)) {
|
||||
WARN("invalid parameter: pan = %ld\n", pan);
|
||||
WARN("invalid parameter: pan = %d\n", pan);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -770,7 +770,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_Unlock(
|
|||
DWORD probably_valid_to;
|
||||
HRESULT hres = DS_OK;
|
||||
|
||||
TRACE("(%p,%p,%ld,%p,%ld)\n", This,p1,x1,p2,x2);
|
||||
TRACE("(%p,%p,%d,%p,%d)\n", This,p1,x1,p2,x2);
|
||||
|
||||
/* **** */
|
||||
EnterCriticalSection(&(This->lock));
|
||||
|
@ -796,7 +796,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_Unlock(
|
|||
LeaveCriticalSection(&(This->lock));
|
||||
/* **** */
|
||||
|
||||
TRACE("probably_valid_to=%ld\n", This->probably_valid_to);
|
||||
TRACE("probably_valid_to=%d\n", This->probably_valid_to);
|
||||
return hres;
|
||||
}
|
||||
|
||||
|
@ -820,7 +820,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_GetFrequency(
|
|||
}
|
||||
|
||||
*freq = This->freq;
|
||||
TRACE("-> %ld\n", *freq);
|
||||
TRACE("-> %d\n", *freq);
|
||||
|
||||
return DS_OK;
|
||||
}
|
||||
|
@ -831,7 +831,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_SetFX(
|
|||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
DWORD u;
|
||||
|
||||
FIXME("(%p,%lu,%p,%p): stub\n",This,dwEffectsCount,pDSFXDesc,pdwResultCodes);
|
||||
FIXME("(%p,%u,%p,%p): stub\n",This,dwEffectsCount,pDSFXDesc,pdwResultCodes);
|
||||
|
||||
if (pdwResultCodes)
|
||||
for (u=0; u<dwEffectsCount; u++) pdwResultCodes[u] = DSFXR_UNKNOWN;
|
||||
|
@ -846,7 +846,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_AcquireResources(
|
|||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
DWORD u;
|
||||
|
||||
FIXME("(%p,%08lu,%lu,%p): stub\n",This,dwFlags,dwEffectsCount,pdwResultCodes);
|
||||
FIXME("(%p,%08u,%u,%p): stub\n",This,dwFlags,dwEffectsCount,pdwResultCodes);
|
||||
|
||||
if (pdwResultCodes)
|
||||
for (u=0; u<dwEffectsCount; u++) pdwResultCodes[u] = DSFXR_UNKNOWN;
|
||||
|
@ -860,7 +860,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_GetObjectInPath(
|
|||
) {
|
||||
IDirectSoundBufferImpl *This = (IDirectSoundBufferImpl *)iface;
|
||||
|
||||
FIXME("(%p,%s,%lu,%s,%p): stub\n",This,debugstr_guid(rguidObject),dwIndex,debugstr_guid(rguidInterface),ppObject);
|
||||
FIXME("(%p,%s,%u,%s,%p): stub\n",This,debugstr_guid(rguidObject),dwIndex,debugstr_guid(rguidInterface),ppObject);
|
||||
|
||||
WARN("control unavailable\n");
|
||||
return DSERR_CONTROLUNAVAIL;
|
||||
|
@ -888,7 +888,7 @@ static HRESULT WINAPI IDirectSoundBufferImpl_GetCaps(
|
|||
}
|
||||
|
||||
if (caps->dwSize < sizeof(*caps)) {
|
||||
WARN("invalid parameter: caps->dwSize = %ld\n",caps->dwSize);
|
||||
WARN("invalid parameter: caps->dwSize = %d\n",caps->dwSize);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -1023,7 +1023,7 @@ HRESULT IDirectSoundBufferImpl_Create(
|
|||
TRACE("(%p,%p,%p)\n",device,pdsb,dsbd);
|
||||
|
||||
if (dsbd->dwBufferBytes < DSBSIZE_MIN || dsbd->dwBufferBytes > DSBSIZE_MAX) {
|
||||
WARN("invalid parameter: dsbd->dwBufferBytes = %ld\n", dsbd->dwBufferBytes);
|
||||
WARN("invalid parameter: dsbd->dwBufferBytes = %d\n", dsbd->dwBufferBytes);
|
||||
*pdsb = NULL;
|
||||
return DSERR_INVALIDPARAM; /* FIXME: which error? */
|
||||
}
|
||||
|
@ -1084,7 +1084,7 @@ HRESULT IDirectSoundBufferImpl_Create(
|
|||
else capf |= DSCAPS_SECONDARY8BIT;
|
||||
|
||||
use_hw = (device->drvcaps.dwFlags & capf) == capf;
|
||||
TRACE("use_hw = 0x%08x, capf = 0x%08lx, device->drvcaps.dwFlags = 0x%08lx\n", use_hw, capf, device->drvcaps.dwFlags);
|
||||
TRACE("use_hw = 0x%08x, capf = 0x%08x, device->drvcaps.dwFlags = 0x%08x\n", use_hw, capf, device->drvcaps.dwFlags);
|
||||
|
||||
/* FIXME: check hardware sample rate mixing capabilities */
|
||||
/* FIXME: check app hints for software/hardware buffer (STATIC, LOCHARDWARE, etc) */
|
||||
|
@ -1353,7 +1353,7 @@ static ULONG WINAPI SecondaryBufferImpl_AddRef(LPDIRECTSOUNDBUFFER8 iface)
|
|||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -1363,7 +1363,7 @@ static ULONG WINAPI SecondaryBufferImpl_Release(LPDIRECTSOUNDBUFFER8 iface)
|
|||
ULONG ref;
|
||||
TRACE("(%p)\n", This);
|
||||
ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("ref was %ld\n", ref + 1);
|
||||
TRACE("ref was %d\n", ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
This->dsb->secondary = NULL;
|
||||
|
@ -1396,7 +1396,7 @@ static HRESULT WINAPI SecondaryBufferImpl_GetFormat(
|
|||
LPDIRECTSOUNDBUFFER8 iface,LPWAVEFORMATEX lpwf,DWORD wfsize,LPDWORD wfwritten)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%p,%ld,%p)\n",This,lpwf,wfsize,wfwritten);
|
||||
TRACE("(%p,%p,%d,%p)\n",This,lpwf,wfsize,wfwritten);
|
||||
|
||||
return IDirectSoundBufferImpl_GetFormat((LPDIRECTSOUNDBUFFER8)This->dsb,lpwf,wfsize,wfwritten);
|
||||
}
|
||||
|
@ -1457,7 +1457,7 @@ static HRESULT WINAPI SecondaryBufferImpl_Lock(
|
|||
DWORD dwFlags)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%ld,%ld,%p,%p,%p,%p,0x%08lx)\n",
|
||||
TRACE("(%p,%d,%d,%p,%p,%p,%p,0x%08x)\n",
|
||||
This,writecursor,writebytes,lplpaudioptr1,audiobytes1,lplpaudioptr2,audiobytes2,dwFlags);
|
||||
|
||||
return IDirectSoundBufferImpl_Lock((LPDIRECTSOUNDBUFFER8)This->dsb,
|
||||
|
@ -1468,7 +1468,7 @@ static HRESULT WINAPI SecondaryBufferImpl_Play(
|
|||
LPDIRECTSOUNDBUFFER8 iface,DWORD reserved1,DWORD reserved2,DWORD flags)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%08lx,%08lx,%08lx)\n",This,reserved1,reserved2,flags);
|
||||
TRACE("(%p,%08x,%08x,%08x)\n",This,reserved1,reserved2,flags);
|
||||
|
||||
return IDirectSoundBufferImpl_Play((LPDIRECTSOUNDBUFFER8)This->dsb,reserved1,reserved2,flags);
|
||||
}
|
||||
|
@ -1477,7 +1477,7 @@ static HRESULT WINAPI SecondaryBufferImpl_SetCurrentPosition(
|
|||
LPDIRECTSOUNDBUFFER8 iface,DWORD newpos)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%ld)\n",This,newpos);
|
||||
TRACE("(%p,%d)\n",This,newpos);
|
||||
|
||||
return IDirectSoundBufferImpl_SetCurrentPosition((LPDIRECTSOUNDBUFFER8)This->dsb,newpos);
|
||||
}
|
||||
|
@ -1495,7 +1495,7 @@ static HRESULT WINAPI SecondaryBufferImpl_SetVolume(
|
|||
LPDIRECTSOUNDBUFFER8 iface,LONG vol)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%ld)\n",This,vol);
|
||||
TRACE("(%p,%d)\n",This,vol);
|
||||
|
||||
return IDirectSoundBufferImpl_SetVolume((LPDIRECTSOUNDBUFFER8)This->dsb,vol);
|
||||
}
|
||||
|
@ -1504,7 +1504,7 @@ static HRESULT WINAPI SecondaryBufferImpl_SetPan(
|
|||
LPDIRECTSOUNDBUFFER8 iface,LONG pan)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%ld)\n",This,pan);
|
||||
TRACE("(%p,%d)\n",This,pan);
|
||||
|
||||
return IDirectSoundBufferImpl_SetPan((LPDIRECTSOUNDBUFFER8)This->dsb,pan);
|
||||
}
|
||||
|
@ -1513,7 +1513,7 @@ static HRESULT WINAPI SecondaryBufferImpl_SetFrequency(
|
|||
LPDIRECTSOUNDBUFFER8 iface,DWORD freq)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%ld)\n",This,freq);
|
||||
TRACE("(%p,%d)\n",This,freq);
|
||||
|
||||
return IDirectSoundBufferImpl_SetFrequency((LPDIRECTSOUNDBUFFER8)This->dsb,freq);
|
||||
}
|
||||
|
@ -1534,7 +1534,7 @@ static HRESULT WINAPI SecondaryBufferImpl_Unlock(
|
|||
DWORD dwAudioBytes2)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%p,%ld,%p,%ld)\n",
|
||||
TRACE("(%p,%p,%d,%p,%d)\n",
|
||||
This, lpvAudioPtr1, dwAudioBytes1, lpvAudioPtr2, dwAudioBytes2);
|
||||
|
||||
return IDirectSoundBufferImpl_Unlock((LPDIRECTSOUNDBUFFER8)This->dsb,
|
||||
|
@ -1554,7 +1554,7 @@ static HRESULT WINAPI SecondaryBufferImpl_SetFX(
|
|||
LPDIRECTSOUNDBUFFER8 iface,DWORD dwEffectsCount,LPDSEFFECTDESC pDSFXDesc,LPDWORD pdwResultCodes)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%lu,%p,%p)\n",This,dwEffectsCount,pDSFXDesc,pdwResultCodes);
|
||||
TRACE("(%p,%u,%p,%p)\n",This,dwEffectsCount,pDSFXDesc,pdwResultCodes);
|
||||
|
||||
return IDirectSoundBufferImpl_SetFX((LPDIRECTSOUNDBUFFER8)This->dsb,dwEffectsCount,pDSFXDesc,pdwResultCodes);
|
||||
}
|
||||
|
@ -1563,7 +1563,7 @@ static HRESULT WINAPI SecondaryBufferImpl_AcquireResources(
|
|||
LPDIRECTSOUNDBUFFER8 iface,DWORD dwFlags,DWORD dwEffectsCount,LPDWORD pdwResultCodes)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%08lu,%lu,%p)\n",This,dwFlags,dwEffectsCount,pdwResultCodes);
|
||||
TRACE("(%p,%08u,%u,%p)\n",This,dwFlags,dwEffectsCount,pdwResultCodes);
|
||||
|
||||
return IDirectSoundBufferImpl_AcquireResources((LPDIRECTSOUNDBUFFER8)This->dsb,dwFlags,dwEffectsCount,pdwResultCodes);
|
||||
}
|
||||
|
@ -1572,7 +1572,7 @@ static HRESULT WINAPI SecondaryBufferImpl_GetObjectInPath(
|
|||
LPDIRECTSOUNDBUFFER8 iface,REFGUID rguidObject,DWORD dwIndex,REFGUID rguidInterface,LPVOID* ppObject)
|
||||
{
|
||||
SecondaryBufferImpl *This = (SecondaryBufferImpl *)iface;
|
||||
TRACE("(%p,%s,%lu,%s,%p)\n",This,debugstr_guid(rguidObject),dwIndex,debugstr_guid(rguidInterface),ppObject);
|
||||
TRACE("(%p,%s,%u,%s,%p)\n",This,debugstr_guid(rguidObject),dwIndex,debugstr_guid(rguidInterface),ppObject);
|
||||
|
||||
return IDirectSoundBufferImpl_GetObjectInPath((LPDIRECTSOUNDBUFFER8)This->dsb,rguidObject,dwIndex,rguidInterface,ppObject);
|
||||
}
|
||||
|
|
|
@ -394,7 +394,7 @@ DSOUND_capture_callback(
|
|||
DWORD dw2 )
|
||||
{
|
||||
DirectSoundCaptureDevice * This = (DirectSoundCaptureDevice*)dwUser;
|
||||
TRACE("(%p,%08x(%s),%08lx,%08lx,%08lx) entering at %ld\n",hwi,msg,
|
||||
TRACE("(%p,%08x(%s),%08x,%08x,%08x) entering at %d\n",hwi,msg,
|
||||
msg == MM_WIM_OPEN ? "MM_WIM_OPEN" : msg == MM_WIM_CLOSE ? "MM_WIM_CLOSE" :
|
||||
msg == MM_WIM_DATA ? "MM_WIM_DATA" : "UNKNOWN",dwUser,dw1,dw2,GetTickCount());
|
||||
|
||||
|
@ -470,7 +470,7 @@ IDirectSoundCaptureImpl_AddRef( LPDIRECTSOUNDCAPTURE iface )
|
|||
{
|
||||
IDirectSoundCaptureImpl *This = (IDirectSoundCaptureImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -479,7 +479,7 @@ IDirectSoundCaptureImpl_Release( LPDIRECTSOUNDCAPTURE iface )
|
|||
{
|
||||
IDirectSoundCaptureImpl *This = (IDirectSoundCaptureImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
if (This->device)
|
||||
|
@ -550,7 +550,7 @@ HRESULT WINAPI IDirectSoundCaptureImpl_GetCaps(
|
|||
}
|
||||
|
||||
if (lpDSCCaps->dwSize < sizeof(*lpDSCCaps)) {
|
||||
WARN("invalid parameter: lpDSCCaps->dwSize = %ld\n", lpDSCCaps->dwSize);
|
||||
WARN("invalid parameter: lpDSCCaps->dwSize = %d\n", lpDSCCaps->dwSize);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -558,7 +558,7 @@ HRESULT WINAPI IDirectSoundCaptureImpl_GetCaps(
|
|||
lpDSCCaps->dwFormats = This->device->drvcaps.dwFormats;
|
||||
lpDSCCaps->dwChannels = This->device->drvcaps.dwChannels;
|
||||
|
||||
TRACE("(flags=0x%08lx,format=0x%08lx,channels=%ld)\n",lpDSCCaps->dwFlags,
|
||||
TRACE("(flags=0x%08x,format=0x%08x,channels=%d)\n",lpDSCCaps->dwFlags,
|
||||
lpDSCCaps->dwFormats, lpDSCCaps->dwChannels);
|
||||
|
||||
return DS_OK;
|
||||
|
@ -638,7 +638,7 @@ static ULONG WINAPI IDirectSoundCaptureNotifyImpl_AddRef(LPDIRECTSOUNDNOTIFY ifa
|
|||
{
|
||||
IDirectSoundCaptureNotifyImpl *This = (IDirectSoundCaptureNotifyImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -646,7 +646,7 @@ static ULONG WINAPI IDirectSoundCaptureNotifyImpl_Release(LPDIRECTSOUNDNOTIFY if
|
|||
{
|
||||
IDirectSoundCaptureNotifyImpl *This = (IDirectSoundCaptureNotifyImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
if (This->dscb->hwnotify)
|
||||
|
@ -665,7 +665,7 @@ static HRESULT WINAPI IDirectSoundCaptureNotifyImpl_SetNotificationPositions(
|
|||
LPCDSBPOSITIONNOTIFY notify)
|
||||
{
|
||||
IDirectSoundCaptureNotifyImpl *This = (IDirectSoundCaptureNotifyImpl *)iface;
|
||||
TRACE("(%p,0x%08lx,%p)\n",This,howmuch,notify);
|
||||
TRACE("(%p,0x%08x,%p)\n",This,howmuch,notify);
|
||||
|
||||
if (howmuch > 0 && notify == NULL) {
|
||||
WARN("invalid parameter: notify == NULL\n");
|
||||
|
@ -675,7 +675,7 @@ static HRESULT WINAPI IDirectSoundCaptureNotifyImpl_SetNotificationPositions(
|
|||
if (TRACE_ON(dsound)) {
|
||||
unsigned int i;
|
||||
for (i=0;i<howmuch;i++)
|
||||
TRACE("notify at %ld to %p\n",
|
||||
TRACE("notify at %d to %p\n",
|
||||
notify[i].dwOffset,notify[i].hEventNotify);
|
||||
}
|
||||
|
||||
|
@ -801,7 +801,7 @@ IDirectSoundCaptureBufferImpl_AddRef( LPDIRECTSOUNDCAPTUREBUFFER8 iface )
|
|||
{
|
||||
IDirectSoundCaptureBufferImpl *This = (IDirectSoundCaptureBufferImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -810,7 +810,7 @@ IDirectSoundCaptureBufferImpl_Release( LPDIRECTSOUNDCAPTUREBUFFER8 iface )
|
|||
{
|
||||
IDirectSoundCaptureBufferImpl *This = (IDirectSoundCaptureBufferImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
TRACE("deleting object\n");
|
||||
|
@ -857,7 +857,7 @@ IDirectSoundCaptureBufferImpl_GetCaps(
|
|||
}
|
||||
|
||||
if (lpDSCBCaps->dwSize < sizeof(DSCBCAPS)) {
|
||||
WARN("invalid parameter: lpDSCBCaps->dwSize = %ld\n", lpDSCBCaps->dwSize);
|
||||
WARN("invalid parameter: lpDSCBCaps->dwSize = %d\n", lpDSCBCaps->dwSize);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -901,7 +901,7 @@ IDirectSoundCaptureBufferImpl_GetCurrentPosition(
|
|||
MMTIME mtime;
|
||||
mtime.wType = TIME_BYTES;
|
||||
waveInGetPosition(This->device->hwi, &mtime, sizeof(mtime));
|
||||
TRACE("mtime.u.cb=%ld,This->device->buflen=%ld\n", mtime.u.cb,
|
||||
TRACE("mtime.u.cb=%d,This->device->buflen=%d\n", mtime.u.cb,
|
||||
This->device->buflen);
|
||||
mtime.u.cb = mtime.u.cb % This->device->buflen;
|
||||
*lpdwCapturePosition = mtime.u.cb;
|
||||
|
@ -917,14 +917,14 @@ IDirectSoundCaptureBufferImpl_GetCurrentPosition(
|
|||
}
|
||||
TRACE("new This->device->state=%s\n",captureStateString[This->device->state]);
|
||||
LeaveCriticalSection(&(This->device->lock));
|
||||
if (lpdwCapturePosition) TRACE("*lpdwCapturePosition=%ld\n",*lpdwCapturePosition);
|
||||
if (lpdwReadPosition) TRACE("*lpdwReadPosition=%ld\n",*lpdwReadPosition);
|
||||
if (lpdwCapturePosition) TRACE("*lpdwCapturePosition=%d\n",*lpdwCapturePosition);
|
||||
if (lpdwReadPosition) TRACE("*lpdwReadPosition=%d\n",*lpdwReadPosition);
|
||||
} else {
|
||||
WARN("no driver\n");
|
||||
hres = DSERR_NODRIVER;
|
||||
}
|
||||
|
||||
TRACE("returning %08lx\n", hres);
|
||||
TRACE("returning %08x\n", hres);
|
||||
return hres;
|
||||
}
|
||||
|
||||
|
@ -937,7 +937,7 @@ IDirectSoundCaptureBufferImpl_GetFormat(
|
|||
{
|
||||
IDirectSoundCaptureBufferImpl *This = (IDirectSoundCaptureBufferImpl *)iface;
|
||||
HRESULT hres = DS_OK;
|
||||
TRACE( "(%p,%p,0x%08lx,%p)\n", This, lpwfxFormat, dwSizeAllocated,
|
||||
TRACE( "(%p,%p,0x%08x,%p)\n", This, lpwfxFormat, dwSizeAllocated,
|
||||
lpdwSizeWritten );
|
||||
|
||||
if (This->device == NULL) {
|
||||
|
@ -961,7 +961,7 @@ IDirectSoundCaptureBufferImpl_GetFormat(
|
|||
}
|
||||
}
|
||||
|
||||
TRACE("returning %08lx\n", hres);
|
||||
TRACE("returning %08x\n", hres);
|
||||
return hres;
|
||||
}
|
||||
|
||||
|
@ -971,7 +971,7 @@ IDirectSoundCaptureBufferImpl_GetStatus(
|
|||
LPDWORD lpdwStatus )
|
||||
{
|
||||
IDirectSoundCaptureBufferImpl *This = (IDirectSoundCaptureBufferImpl *)iface;
|
||||
TRACE( "(%p, %p), thread is %04lx\n", This, lpdwStatus, GetCurrentThreadId() );
|
||||
TRACE( "(%p, %p), thread is %04x\n", This, lpdwStatus, GetCurrentThreadId() );
|
||||
|
||||
if (This->device == NULL) {
|
||||
WARN("invalid parameter: This->device == NULL\n");
|
||||
|
@ -986,7 +986,7 @@ IDirectSoundCaptureBufferImpl_GetStatus(
|
|||
*lpdwStatus = 0;
|
||||
EnterCriticalSection(&(This->device->lock));
|
||||
|
||||
TRACE("old This->device->state=%s, old lpdwStatus=%08lx\n",
|
||||
TRACE("old This->device->state=%s, old lpdwStatus=%08x\n",
|
||||
captureStateString[This->device->state],*lpdwStatus);
|
||||
if ((This->device->state == STATE_STARTING) ||
|
||||
(This->device->state == STATE_CAPTURING)) {
|
||||
|
@ -994,11 +994,11 @@ IDirectSoundCaptureBufferImpl_GetStatus(
|
|||
if (This->flags & DSCBSTART_LOOPING)
|
||||
*lpdwStatus |= DSCBSTATUS_LOOPING;
|
||||
}
|
||||
TRACE("new This->device->state=%s, new lpdwStatus=%08lx\n",
|
||||
TRACE("new This->device->state=%s, new lpdwStatus=%08x\n",
|
||||
captureStateString[This->device->state],*lpdwStatus);
|
||||
LeaveCriticalSection(&(This->device->lock));
|
||||
|
||||
TRACE("status=%lx\n", *lpdwStatus);
|
||||
TRACE("status=%x\n", *lpdwStatus);
|
||||
TRACE("returning DS_OK\n");
|
||||
return DS_OK;
|
||||
}
|
||||
|
@ -1029,7 +1029,7 @@ IDirectSoundCaptureBufferImpl_Lock(
|
|||
{
|
||||
HRESULT hres = DS_OK;
|
||||
IDirectSoundCaptureBufferImpl *This = (IDirectSoundCaptureBufferImpl *)iface;
|
||||
TRACE( "(%p,%08lu,%08lu,%p,%p,%p,%p,0x%08lx) at %ld\n", This, dwReadCusor,
|
||||
TRACE( "(%p,%08u,%08u,%p,%p,%p,%p,0x%08x) at %d\n", This, dwReadCusor,
|
||||
dwReadBytes, lplpvAudioPtr1, lpdwAudioBytes1, lplpvAudioPtr2,
|
||||
lpdwAudioBytes2, dwFlags, GetTickCount() );
|
||||
|
||||
|
@ -1079,7 +1079,7 @@ IDirectSoundCaptureBufferImpl_Lock(
|
|||
|
||||
LeaveCriticalSection(&(This->device->lock));
|
||||
|
||||
TRACE("returning %08lx\n", hres);
|
||||
TRACE("returning %08x\n", hres);
|
||||
return hres;
|
||||
}
|
||||
|
||||
|
@ -1090,7 +1090,7 @@ IDirectSoundCaptureBufferImpl_Start(
|
|||
{
|
||||
HRESULT hres = DS_OK;
|
||||
IDirectSoundCaptureBufferImpl *This = (IDirectSoundCaptureBufferImpl *)iface;
|
||||
TRACE( "(%p,0x%08lx)\n", This, dwFlags );
|
||||
TRACE( "(%p,0x%08x)\n", This, dwFlags );
|
||||
|
||||
if (This->device == NULL) {
|
||||
WARN("invalid parameter: This->device == NULL\n");
|
||||
|
@ -1233,7 +1233,7 @@ IDirectSoundCaptureBufferImpl_Start(
|
|||
hres = DSERR_NODRIVER;
|
||||
}
|
||||
|
||||
TRACE("returning %08lx\n", hres);
|
||||
TRACE("returning %08x\n", hres);
|
||||
return hres;
|
||||
}
|
||||
|
||||
|
@ -1273,7 +1273,7 @@ IDirectSoundCaptureBufferImpl_Stop( LPDIRECTSOUNDCAPTUREBUFFER8 iface )
|
|||
hres = DSERR_NODRIVER;
|
||||
}
|
||||
|
||||
TRACE("returning %08lx\n", hres);
|
||||
TRACE("returning %08x\n", hres);
|
||||
return hres;
|
||||
}
|
||||
|
||||
|
@ -1287,7 +1287,7 @@ IDirectSoundCaptureBufferImpl_Unlock(
|
|||
{
|
||||
HRESULT hres = DS_OK;
|
||||
IDirectSoundCaptureBufferImpl *This = (IDirectSoundCaptureBufferImpl *)iface;
|
||||
TRACE( "(%p,%p,%08lu,%p,%08lu)\n", This, lpvAudioPtr1, dwAudioBytes1,
|
||||
TRACE( "(%p,%p,%08u,%p,%08u)\n", This, lpvAudioPtr1, dwAudioBytes1,
|
||||
lpvAudioPtr2, dwAudioBytes2 );
|
||||
|
||||
if (lpvAudioPtr1 == NULL) {
|
||||
|
@ -1308,7 +1308,7 @@ IDirectSoundCaptureBufferImpl_Unlock(
|
|||
hres = DSERR_INVALIDCALL;
|
||||
}
|
||||
|
||||
TRACE("returning %08lx\n", hres);
|
||||
TRACE("returning %08x\n", hres);
|
||||
return hres;
|
||||
}
|
||||
|
||||
|
@ -1322,7 +1322,7 @@ IDirectSoundCaptureBufferImpl_GetObjectInPath(
|
|||
{
|
||||
IDirectSoundCaptureBufferImpl *This = (IDirectSoundCaptureBufferImpl *)iface;
|
||||
|
||||
FIXME( "(%p,%s,%lu,%s,%p): stub\n", This, debugstr_guid(rguidObject),
|
||||
FIXME( "(%p,%s,%u,%s,%p): stub\n", This, debugstr_guid(rguidObject),
|
||||
dwIndex, debugstr_guid(rguidInterface), ppObject );
|
||||
|
||||
return DS_OK;
|
||||
|
@ -1336,7 +1336,7 @@ IDirectSoundCaptureBufferImpl_GetFXStatus(
|
|||
{
|
||||
IDirectSoundCaptureBufferImpl *This = (IDirectSoundCaptureBufferImpl *)iface;
|
||||
|
||||
FIXME( "(%p,%lu,%p): stub\n", This, dwFXCount, pdwFXStatus );
|
||||
FIXME( "(%p,%u,%p): stub\n", This, dwFXCount, pdwFXStatus );
|
||||
|
||||
return DS_OK;
|
||||
}
|
||||
|
@ -1401,8 +1401,8 @@ HRESULT IDirectSoundCaptureBufferImpl_Create(
|
|||
wfex = lpcDSCBufferDesc->lpwfxFormat;
|
||||
|
||||
if (wfex) {
|
||||
TRACE("(formattag=0x%04x,chans=%d,samplerate=%ld,"
|
||||
"bytespersec=%ld,blockalign=%d,bitspersamp=%d,cbSize=%d)\n",
|
||||
TRACE("(formattag=0x%04x,chans=%d,samplerate=%d,"
|
||||
"bytespersec=%d,blockalign=%d,bitspersamp=%d,cbSize=%d)\n",
|
||||
wfex->wFormatTag, wfex->nChannels, wfex->nSamplesPerSec,
|
||||
wfex->nAvgBytesPerSec, wfex->nBlockAlign,
|
||||
wfex->wBitsPerSample, wfex->cbSize);
|
||||
|
@ -1462,7 +1462,7 @@ HRESULT IDirectSoundCaptureBufferImpl_Create(
|
|||
if (This->device->drvdesc.dwFlags & DSDDESC_USESYSTEMMEMORY) {
|
||||
/* allocate buffer from system memory */
|
||||
buflen = lpcDSCBufferDesc->dwBufferBytes;
|
||||
TRACE("desired buflen=%ld, old buffer=%p\n", buflen, device->buffer);
|
||||
TRACE("desired buflen=%d, old buffer=%p\n", buflen, device->buffer);
|
||||
if (device->buffer)
|
||||
newbuf = HeapReAlloc(GetProcessHeap(),0,device->buffer,buflen);
|
||||
else
|
||||
|
@ -1509,7 +1509,7 @@ HRESULT IDirectSoundCaptureBufferImpl_Create(
|
|||
}
|
||||
|
||||
buflen = lpcDSCBufferDesc->dwBufferBytes;
|
||||
TRACE("desired buflen=%ld, old buffer=%p\n", buflen, device->buffer);
|
||||
TRACE("desired buflen=%d, old buffer=%p\n", buflen, device->buffer);
|
||||
if (device->buffer)
|
||||
newbuf = HeapReAlloc(GetProcessHeap(),0,device->buffer,buflen);
|
||||
else
|
||||
|
@ -1587,7 +1587,7 @@ HRESULT DirectSoundCaptureDevice_Initialize(
|
|||
|
||||
err = mmErr(waveInMessage((HWAVEIN)wid,DRV_QUERYDSOUNDIFACE,(DWORD_PTR)&(device->driver),0));
|
||||
if ( (err != DS_OK) && (err != DSERR_UNSUPPORTED) ) {
|
||||
WARN("waveInMessage failed; err=%lx\n",err);
|
||||
WARN("waveInMessage failed; err=%x\n",err);
|
||||
return err;
|
||||
}
|
||||
err = DS_OK;
|
||||
|
@ -1676,7 +1676,7 @@ ULONG DirectSoundCaptureDevice_AddRef(
|
|||
DirectSoundCaptureDevice * device)
|
||||
{
|
||||
ULONG ref = InterlockedIncrement(&(device->ref));
|
||||
TRACE("(%p) ref was %ld\n", device, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", device, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -1684,7 +1684,7 @@ ULONG DirectSoundCaptureDevice_Release(
|
|||
DirectSoundCaptureDevice * device)
|
||||
{
|
||||
ULONG ref = InterlockedDecrement(&(device->ref));
|
||||
TRACE("(%p) ref was %ld\n", device, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", device, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
TRACE("deleting object\n");
|
||||
|
|
|
@ -119,7 +119,7 @@ const char * dumpCooperativeLevel(DWORD level)
|
|||
LE(DSSCL_WRITEPRIMARY);
|
||||
}
|
||||
#undef LE
|
||||
sprintf(unknown, "Unknown(%08lx)", level);
|
||||
sprintf(unknown, "Unknown(%08x)", level);
|
||||
return unknown;
|
||||
}
|
||||
|
||||
|
@ -285,7 +285,7 @@ static ULONG IDirectSoundImpl_AddRef(
|
|||
{
|
||||
IDirectSoundImpl *This = (IDirectSoundImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -294,7 +294,7 @@ static ULONG IDirectSoundImpl_Release(
|
|||
{
|
||||
IDirectSoundImpl *This = (IDirectSoundImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
if (This->device)
|
||||
|
@ -345,7 +345,7 @@ static ULONG WINAPI IDirectSound_IUnknown_AddRef(
|
|||
{
|
||||
IDirectSound_IUnknown *This = (IDirectSound_IUnknown *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -354,7 +354,7 @@ static ULONG WINAPI IDirectSound_IUnknown_Release(
|
|||
{
|
||||
IDirectSound_IUnknown *This = (IDirectSound_IUnknown *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
if (!ref) {
|
||||
IDirectSoundImpl_Release(This->pds);
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
@ -423,7 +423,7 @@ static ULONG WINAPI IDirectSound_IDirectSound_AddRef(
|
|||
{
|
||||
IDirectSound_IDirectSound *This = (IDirectSound_IDirectSound *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -432,7 +432,7 @@ static ULONG WINAPI IDirectSound_IDirectSound_Release(
|
|||
{
|
||||
IDirectSound_IDirectSound *This = (IDirectSound_IDirectSound *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
if (!ref) {
|
||||
IDirectSoundImpl_Release(This->pds);
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
@ -503,7 +503,7 @@ static HRESULT WINAPI IDirectSound_IDirectSound_SetSpeakerConfig(
|
|||
DWORD config)
|
||||
{
|
||||
IDirectSound_IDirectSound *This = (IDirectSound_IDirectSound *)iface;
|
||||
TRACE("(%p,0x%08lx)\n",This,config);
|
||||
TRACE("(%p,0x%08x)\n",This,config);
|
||||
return DirectSoundDevice_SetSpeakerConfig(((IDirectSoundImpl *)This->pds)->device,config);
|
||||
}
|
||||
|
||||
|
@ -584,7 +584,7 @@ static ULONG WINAPI IDirectSound8_IUnknown_AddRef(
|
|||
{
|
||||
IDirectSound_IUnknown *This = (IDirectSound_IUnknown *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -593,7 +593,7 @@ static ULONG WINAPI IDirectSound8_IUnknown_Release(
|
|||
{
|
||||
IDirectSound_IUnknown *This = (IDirectSound_IUnknown *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
if (!ref) {
|
||||
IDirectSoundImpl_Release(This->pds);
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
@ -662,7 +662,7 @@ static ULONG WINAPI IDirectSound8_IDirectSound_AddRef(
|
|||
{
|
||||
IDirectSound8_IDirectSound *This = (IDirectSound8_IDirectSound *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -671,7 +671,7 @@ static ULONG WINAPI IDirectSound8_IDirectSound_Release(
|
|||
{
|
||||
IDirectSound8_IDirectSound *This = (IDirectSound8_IDirectSound *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
if (!ref) {
|
||||
IDirectSoundImpl_Release(This->pds);
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
@ -742,7 +742,7 @@ static HRESULT WINAPI IDirectSound8_IDirectSound_SetSpeakerConfig(
|
|||
DWORD config)
|
||||
{
|
||||
IDirectSound8_IDirectSound *This = (IDirectSound8_IDirectSound *)iface;
|
||||
TRACE("(%p,0x%08lx)\n",This,config);
|
||||
TRACE("(%p,0x%08x)\n",This,config);
|
||||
return DirectSoundDevice_SetSpeakerConfig(((IDirectSoundImpl *)This->pds)->device,config);
|
||||
}
|
||||
|
||||
|
@ -823,7 +823,7 @@ static ULONG WINAPI IDirectSound8_IDirectSound8_AddRef(
|
|||
{
|
||||
IDirectSound8_IDirectSound8 *This = (IDirectSound8_IDirectSound8 *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -832,7 +832,7 @@ static ULONG WINAPI IDirectSound8_IDirectSound8_Release(
|
|||
{
|
||||
IDirectSound8_IDirectSound8 *This = (IDirectSound8_IDirectSound8 *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
if (!ref) {
|
||||
IDirectSoundImpl_Release(This->pds);
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
@ -903,7 +903,7 @@ static HRESULT WINAPI IDirectSound8_IDirectSound8_SetSpeakerConfig(
|
|||
DWORD config)
|
||||
{
|
||||
IDirectSound8_IDirectSound8 *This = (IDirectSound8_IDirectSound8 *)iface;
|
||||
TRACE("(%p,0x%08lx)\n",This,config);
|
||||
TRACE("(%p,0x%08x)\n",This,config);
|
||||
return DirectSoundDevice_SetSpeakerConfig(((IDirectSoundImpl *)This->pds)->device,config);
|
||||
}
|
||||
|
||||
|
@ -1236,7 +1236,7 @@ static HRESULT DirectSoundDevice_Create(DirectSoundDevice ** ppDevice)
|
|||
static ULONG DirectSoundDevice_AddRef(DirectSoundDevice * device)
|
||||
{
|
||||
ULONG ref = InterlockedIncrement(&(device->ref));
|
||||
TRACE("(%p) ref was %ld\n", device, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", device, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -1244,7 +1244,7 @@ ULONG DirectSoundDevice_Release(DirectSoundDevice * device)
|
|||
{
|
||||
HRESULT hr;
|
||||
ULONG ref = InterlockedDecrement(&(device->ref));
|
||||
TRACE("(%p) ref was %lu\n", device, ref + 1);
|
||||
TRACE("(%p) ref was %u\n", device, ref + 1);
|
||||
if (!ref) {
|
||||
int i;
|
||||
timeKillEvent(device->timerID);
|
||||
|
@ -1314,13 +1314,13 @@ HRESULT DirectSoundDevice_GetCaps(
|
|||
|
||||
/* check if there is enough room */
|
||||
if (lpDSCaps->dwSize < sizeof(*lpDSCaps)) {
|
||||
WARN("invalid parameter: lpDSCaps->dwSize = %ld\n", lpDSCaps->dwSize);
|
||||
WARN("invalid parameter: lpDSCaps->dwSize = %d\n", lpDSCaps->dwSize);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
lpDSCaps->dwFlags = device->drvcaps.dwFlags;
|
||||
if (TRACE_ON(dsound)) {
|
||||
TRACE("(flags=0x%08lx:\n",lpDSCaps->dwFlags);
|
||||
TRACE("(flags=0x%08x:\n",lpDSCaps->dwFlags);
|
||||
_dump_DSCAPS(lpDSCaps->dwFlags);
|
||||
DPRINTF(")\n");
|
||||
}
|
||||
|
@ -1561,11 +1561,11 @@ HRESULT DirectSoundDevice_CreateSoundBuffer(
|
|||
}
|
||||
|
||||
if (TRACE_ON(dsound)) {
|
||||
TRACE("(structsize=%ld)\n",dsbd->dwSize);
|
||||
TRACE("(flags=0x%08lx:\n",dsbd->dwFlags);
|
||||
TRACE("(structsize=%d)\n",dsbd->dwSize);
|
||||
TRACE("(flags=0x%08x:\n",dsbd->dwFlags);
|
||||
_dump_DSBCAPS(dsbd->dwFlags);
|
||||
DPRINTF(")\n");
|
||||
TRACE("(bufferbytes=%ld)\n",dsbd->dwBufferBytes);
|
||||
TRACE("(bufferbytes=%d)\n",dsbd->dwBufferBytes);
|
||||
TRACE("(lpwfxFormat=%p)\n",dsbd->lpwfxFormat);
|
||||
}
|
||||
|
||||
|
@ -1598,8 +1598,8 @@ HRESULT DirectSoundDevice_CreateSoundBuffer(
|
|||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
TRACE("(formattag=0x%04x,chans=%d,samplerate=%ld,"
|
||||
"bytespersec=%ld,blockalign=%d,bitspersamp=%d,cbSize=%d)\n",
|
||||
TRACE("(formattag=0x%04x,chans=%d,samplerate=%d,"
|
||||
"bytespersec=%d,blockalign=%d,bitspersamp=%d,cbSize=%d)\n",
|
||||
dsbd->lpwfxFormat->wFormatTag, dsbd->lpwfxFormat->nChannels,
|
||||
dsbd->lpwfxFormat->nSamplesPerSec,
|
||||
dsbd->lpwfxFormat->nAvgBytesPerSec,
|
||||
|
@ -1741,7 +1741,7 @@ HRESULT DirectSoundDevice_SetSpeakerConfig(
|
|||
DirectSoundDevice * device,
|
||||
DWORD config)
|
||||
{
|
||||
TRACE("(%p,0x%08lx)\n",device,config);
|
||||
TRACE("(%p,0x%08x)\n",device,config);
|
||||
|
||||
if (device == NULL) {
|
||||
WARN("not initialized\n");
|
||||
|
|
|
@ -449,7 +449,7 @@ static ULONG WINAPI DSCF_AddRef(LPCLASSFACTORY iface)
|
|||
{
|
||||
IClassFactoryImpl *This = (IClassFactoryImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -457,7 +457,7 @@ static ULONG WINAPI DSCF_Release(LPCLASSFACTORY iface)
|
|||
{
|
||||
IClassFactoryImpl *This = (IClassFactoryImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
/* static class, won't be freed */
|
||||
return ref;
|
||||
}
|
||||
|
@ -583,7 +583,7 @@ HRESULT WINAPI DllCanUnloadNow(void)
|
|||
BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpvReserved)
|
||||
{
|
||||
int i;
|
||||
TRACE("(%p %ld %p)\n", hInstDLL, fdwReason, lpvReserved);
|
||||
TRACE("(%p %d %p)\n", hInstDLL, fdwReason, lpvReserved);
|
||||
|
||||
switch (fdwReason) {
|
||||
case DLL_PROCESS_ATTACH:
|
||||
|
|
|
@ -57,7 +57,7 @@ static ULONG WINAPI IDirectSoundFullDuplex_IUnknown_AddRef(
|
|||
{
|
||||
IDirectSoundFullDuplex_IUnknown *This = (IDirectSoundFullDuplex_IUnknown *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -66,7 +66,7 @@ static ULONG WINAPI IDirectSoundFullDuplex_IUnknown_Release(
|
|||
{
|
||||
IDirectSoundFullDuplex_IUnknown *This = (IDirectSoundFullDuplex_IUnknown *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
if (!ref) {
|
||||
IDirectSound_Release(This->pdsfd->pUnknown);
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
@ -133,7 +133,7 @@ static ULONG WINAPI IDirectSoundFullDuplex_IDirectSound_AddRef(
|
|||
{
|
||||
IDirectSoundFullDuplex_IDirectSound *This = (IDirectSoundFullDuplex_IDirectSound *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -142,7 +142,7 @@ static ULONG WINAPI IDirectSoundFullDuplex_IDirectSound_Release(
|
|||
{
|
||||
IDirectSoundFullDuplex_IDirectSound *This = (IDirectSoundFullDuplex_IDirectSound *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
if (!ref) {
|
||||
IDirectSound_Release(This->pdsfd->pDS);
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
@ -213,7 +213,7 @@ static HRESULT WINAPI IDirectSoundFullDuplex_IDirectSound_SetSpeakerConfig(
|
|||
DWORD config)
|
||||
{
|
||||
IDirectSoundFullDuplex_IDirectSound *This = (IDirectSoundFullDuplex_IDirectSound *)iface;
|
||||
TRACE("(%p,0x%08lx)\n",This,config);
|
||||
TRACE("(%p,0x%08x)\n",This,config);
|
||||
return DirectSoundDevice_SetSpeakerConfig(This->pdsfd->renderer_device,config);
|
||||
}
|
||||
|
||||
|
@ -298,7 +298,7 @@ static ULONG WINAPI IDirectSoundFullDuplex_IDirectSound8_AddRef(
|
|||
{
|
||||
IDirectSoundFullDuplex_IDirectSound8 *This = (IDirectSoundFullDuplex_IDirectSound8 *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -307,7 +307,7 @@ static ULONG WINAPI IDirectSoundFullDuplex_IDirectSound8_Release(
|
|||
{
|
||||
IDirectSoundFullDuplex_IDirectSound8 *This = (IDirectSoundFullDuplex_IDirectSound8 *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
if (!ref) {
|
||||
IDirectSound_Release(This->pdsfd->pDS8);
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
@ -378,7 +378,7 @@ static HRESULT WINAPI IDirectSoundFullDuplex_IDirectSound8_SetSpeakerConfig(
|
|||
DWORD config)
|
||||
{
|
||||
IDirectSoundFullDuplex_IDirectSound8 *This = (IDirectSoundFullDuplex_IDirectSound8 *)iface;
|
||||
TRACE("(%p,0x%08lx)\n",This,config);
|
||||
TRACE("(%p,0x%08x)\n",This,config);
|
||||
return DirectSoundDevice_SetSpeakerConfig(This->pdsfd->renderer_device,config);
|
||||
}
|
||||
|
||||
|
@ -463,7 +463,7 @@ static ULONG WINAPI IDirectSoundFullDuplex_IDirectSoundCapture_AddRef(
|
|||
{
|
||||
IDirectSoundFullDuplex_IDirectSoundCapture *This = (IDirectSoundFullDuplex_IDirectSoundCapture *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -472,7 +472,7 @@ static ULONG WINAPI IDirectSoundFullDuplex_IDirectSoundCapture_Release(
|
|||
{
|
||||
IDirectSoundFullDuplex_IDirectSoundCapture *This = (IDirectSoundFullDuplex_IDirectSoundCapture *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
if (!ref) {
|
||||
IDirectSoundCapture_Release(This->pdsfd->pDSC);
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
@ -567,7 +567,7 @@ IDirectSoundFullDuplexImpl_AddRef( LPDIRECTSOUNDFULLDUPLEX iface )
|
|||
{
|
||||
IDirectSoundFullDuplexImpl *This = (IDirectSoundFullDuplexImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -649,7 +649,7 @@ IDirectSoundFullDuplexImpl_Release( LPDIRECTSOUNDFULLDUPLEX iface )
|
|||
{
|
||||
IDirectSoundFullDuplexImpl *This = (IDirectSoundFullDuplexImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
|
||||
if (!ref) {
|
||||
if (This->capture_device)
|
||||
|
@ -678,7 +678,7 @@ IDirectSoundFullDuplexImpl_Initialize(
|
|||
IDirectSoundFullDuplexImpl *This = (IDirectSoundFullDuplexImpl *)iface;
|
||||
IDirectSoundBufferImpl * dsb;
|
||||
|
||||
TRACE("(%p,%s,%s,%p,%p,%lx,%lx,%p,%p)\n", This,
|
||||
TRACE("(%p,%s,%s,%p,%p,%x,%x,%p,%p)\n", This,
|
||||
debugstr_guid(pCaptureGuid), debugstr_guid(pRendererGuid),
|
||||
lpDscBufferDesc, lpDsBufferDesc, (DWORD)hWnd, dwLevel,
|
||||
lplpDirectSoundCaptureBuffer8, lplpDirectSoundBuffer8);
|
||||
|
@ -837,7 +837,7 @@ DirectSoundFullDuplexCreate(
|
|||
{
|
||||
HRESULT hres;
|
||||
IDirectSoundFullDuplexImpl *This = NULL;
|
||||
TRACE("(%s,%s,%p,%p,%p,%lx,%p,%p,%p,%p)\n",
|
||||
TRACE("(%s,%s,%p,%p,%p,%x,%p,%p,%p,%p)\n",
|
||||
debugstr_guid(pcGuidCaptureDevice), debugstr_guid(pcGuidRenderDevice),
|
||||
pcDSCBufferDesc, pcDSBufferDesc, hWnd, dwLevel, ppDSFD, ppDSCBuffer8,
|
||||
ppDSBuffer8, pUnkOuter);
|
||||
|
|
|
@ -43,7 +43,7 @@ void DSOUND_RecalcVolPan(PDSVOLUMEPAN volpan)
|
|||
double temp;
|
||||
TRACE("(%p)\n",volpan);
|
||||
|
||||
TRACE("Vol=%ld Pan=%ld\n", volpan->lVolume, volpan->lPan);
|
||||
TRACE("Vol=%d Pan=%d\n", volpan->lVolume, volpan->lPan);
|
||||
/* the AmpFactors are expressed in 16.16 fixed point */
|
||||
volpan->dwVolAmpFactor = (ULONG) (pow(2.0, volpan->lVolume / 600.0) * 0xffff);
|
||||
/* FIXME: dwPan{Left|Right}AmpFactor */
|
||||
|
@ -54,7 +54,7 @@ void DSOUND_RecalcVolPan(PDSVOLUMEPAN volpan)
|
|||
temp = (double) (volpan->lVolume + (volpan->lPan < 0 ? volpan->lPan : 0));
|
||||
volpan->dwTotalRightAmpFactor = (ULONG) (pow(2.0, temp / 600.0) * 0xffff);
|
||||
|
||||
TRACE("left = %lx, right = %lx\n", volpan->dwTotalLeftAmpFactor, volpan->dwTotalRightAmpFactor);
|
||||
TRACE("left = %x, right = %x\n", volpan->dwTotalLeftAmpFactor, volpan->dwTotalRightAmpFactor);
|
||||
}
|
||||
|
||||
void DSOUND_AmpFactorToVolPan(PDSVOLUMEPAN volpan)
|
||||
|
@ -62,7 +62,7 @@ void DSOUND_AmpFactorToVolPan(PDSVOLUMEPAN volpan)
|
|||
double left,right;
|
||||
TRACE("(%p)\n",volpan);
|
||||
|
||||
TRACE("left=%lx, right=%lx\n",volpan->dwTotalLeftAmpFactor,volpan->dwTotalRightAmpFactor);
|
||||
TRACE("left=%x, right=%x\n",volpan->dwTotalLeftAmpFactor,volpan->dwTotalRightAmpFactor);
|
||||
if (volpan->dwTotalLeftAmpFactor==0)
|
||||
left=-10000;
|
||||
else
|
||||
|
@ -87,7 +87,7 @@ void DSOUND_AmpFactorToVolPan(PDSVOLUMEPAN volpan)
|
|||
if (volpan->lPan < -10000)
|
||||
volpan->lPan=-10000;
|
||||
|
||||
TRACE("Vol=%ld Pan=%ld\n", volpan->lVolume, volpan->lPan);
|
||||
TRACE("Vol=%d Pan=%d\n", volpan->lVolume, volpan->lPan);
|
||||
}
|
||||
|
||||
void DSOUND_RecalcFormat(IDirectSoundBufferImpl *dsb)
|
||||
|
@ -108,12 +108,12 @@ void DSOUND_CheckEvent(IDirectSoundBufferImpl *dsb, int len)
|
|||
if (dsb->nrofnotifies == 0)
|
||||
return;
|
||||
|
||||
TRACE("(%p) buflen = %ld, playpos = %ld, len = %d\n",
|
||||
TRACE("(%p) buflen = %d, playpos = %d, len = %d\n",
|
||||
dsb, dsb->buflen, dsb->playpos, len);
|
||||
for (i = 0; i < dsb->nrofnotifies ; i++) {
|
||||
event = dsb->notifies + i;
|
||||
offset = event->dwOffset;
|
||||
TRACE("checking %d, position %ld, event = %p\n",
|
||||
TRACE("checking %d, position %d, event = %p\n",
|
||||
i, offset, event->hEventNotify);
|
||||
/* DSBPN_OFFSETSTOP has to be the last element. So this is */
|
||||
/* OK. [Inside DirectX, p274] */
|
||||
|
@ -220,7 +220,7 @@ static INT DSOUND_MixerNorm(IDirectSoundBufferImpl *dsb, BYTE *buf, INT len)
|
|||
ibp = dsb->buffer->memory + dsb->buf_mixpos;
|
||||
obp = buf;
|
||||
|
||||
TRACE("(%p, %p, %p), buf_mixpos=%ld\n", dsb, ibp, obp, dsb->buf_mixpos);
|
||||
TRACE("(%p, %p, %p), buf_mixpos=%d\n", dsb, ibp, obp, dsb->buf_mixpos);
|
||||
/* Check for the best case */
|
||||
if ((dsb->freq == dsb->device->pwfx->nSamplesPerSec) &&
|
||||
(dsb->pwfx->wBitsPerSample == dsb->device->pwfx->wBitsPerSample) &&
|
||||
|
@ -238,7 +238,7 @@ static INT DSOUND_MixerNorm(IDirectSoundBufferImpl *dsb, BYTE *buf, INT len)
|
|||
|
||||
/* Check for same sample rate */
|
||||
if (dsb->freq == dsb->device->pwfx->nSamplesPerSec) {
|
||||
TRACE("(%p) Same sample rate %ld = primary %ld\n", dsb,
|
||||
TRACE("(%p) Same sample rate %d = primary %d\n", dsb,
|
||||
dsb->freq, dsb->device->pwfx->nSamplesPerSec);
|
||||
ilen = 0;
|
||||
for (i = 0; i < len; i += oAdvance) {
|
||||
|
@ -287,7 +287,7 @@ static void DSOUND_MixerVol(IDirectSoundBufferImpl *dsb, BYTE *buf, INT len)
|
|||
INT16 *bps = (INT16 *) buf;
|
||||
|
||||
TRACE("(%p,%p,%d)\n",dsb,buf,len);
|
||||
TRACE("left = %lx, right = %lx\n", dsb->cvolpan.dwTotalLeftAmpFactor,
|
||||
TRACE("left = %x, right = %x\n", dsb->cvolpan.dwTotalLeftAmpFactor,
|
||||
dsb->cvolpan.dwTotalRightAmpFactor);
|
||||
|
||||
if ((!(dsb->dsbd.dwFlags & DSBCAPS_CTRLPAN) || (dsb->cvolpan.lPan == 0)) &&
|
||||
|
@ -358,7 +358,7 @@ static void DSOUND_MixerVol(IDirectSoundBufferImpl *dsb, BYTE *buf, INT len)
|
|||
|
||||
static LPBYTE DSOUND_tmpbuffer(DirectSoundDevice *device, DWORD len)
|
||||
{
|
||||
TRACE("(%p,%ld)\n", device, len);
|
||||
TRACE("(%p,%d)\n", device, len);
|
||||
|
||||
if (len > device->tmp_buffer_len) {
|
||||
if (device->tmp_buffer)
|
||||
|
@ -377,7 +377,7 @@ static DWORD DSOUND_MixInBuffer(IDirectSoundBufferImpl *dsb, DWORD writepos, DWO
|
|||
INT i, len, ilen, field, todo;
|
||||
BYTE *buf, *ibuf;
|
||||
|
||||
TRACE("(%p,%ld,%ld)\n",dsb,writepos,fraglen);
|
||||
TRACE("(%p,%d,%d)\n",dsb,writepos,fraglen);
|
||||
|
||||
len = fraglen;
|
||||
if (!(dsb->playflags & DSBPLAY_LOOPING)) {
|
||||
|
@ -402,7 +402,7 @@ static DWORD DSOUND_MixInBuffer(IDirectSoundBufferImpl *dsb, DWORD writepos, DWO
|
|||
if ((buf = ibuf = DSOUND_tmpbuffer(dsb->device, len)) == NULL)
|
||||
return 0;
|
||||
|
||||
TRACE("MixInBuffer (%p) len = %d, dest = %ld\n", dsb, len, writepos);
|
||||
TRACE("MixInBuffer (%p) len = %d, dest = %d\n", dsb, len, writepos);
|
||||
|
||||
ilen = DSOUND_MixerNorm(dsb, ibuf, len);
|
||||
if ((dsb->dsbd.dwFlags & DSBCAPS_CTRLPAN) ||
|
||||
|
@ -492,7 +492,7 @@ static DWORD DSOUND_MixInBuffer(IDirectSoundBufferImpl *dsb, DWORD writepos, DWO
|
|||
if (dsb->leadin && (dsb->startpos <= dsb->buf_mixpos))
|
||||
dsb->leadin = FALSE; /* HACK: see above */
|
||||
} else if (dsb->buf_mixpos > dsb->buflen) {
|
||||
ERR("Mixpos (%lu) past buflen (%lu), capping...\n", dsb->buf_mixpos, dsb->buflen);
|
||||
ERR("Mixpos (%u) past buflen (%u), capping...\n", dsb->buf_mixpos, dsb->buflen);
|
||||
dsb->buf_mixpos = dsb->buflen;
|
||||
}
|
||||
}
|
||||
|
@ -506,18 +506,18 @@ static void DSOUND_PhaseCancel(IDirectSoundBufferImpl *dsb, DWORD writepos, DWOR
|
|||
UINT i, todo;
|
||||
BYTE *buf, *ibuf;
|
||||
|
||||
TRACE("(%p,%ld,%ld)\n",dsb,writepos,len);
|
||||
TRACE("(%p,%d,%d)\n",dsb,writepos,len);
|
||||
|
||||
if (len % dsb->device->pwfx->nBlockAlign) {
|
||||
INT nBlockAlign = dsb->device->pwfx->nBlockAlign;
|
||||
ERR("length not a multiple of block size, len = %ld, block size = %d\n", len, nBlockAlign);
|
||||
ERR("length not a multiple of block size, len = %d, block size = %d\n", len, nBlockAlign);
|
||||
len = (len / nBlockAlign) * nBlockAlign; /* data alignment */
|
||||
}
|
||||
|
||||
if ((buf = ibuf = DSOUND_tmpbuffer(dsb->device, len)) == NULL)
|
||||
return;
|
||||
|
||||
TRACE("PhaseCancel (%p) len = %ld, dest = %ld\n", dsb, len, writepos);
|
||||
TRACE("PhaseCancel (%p) len = %d, dest = %d\n", dsb, len, writepos);
|
||||
|
||||
ilen = DSOUND_MixerNorm(dsb, ibuf, len);
|
||||
if ((dsb->dsbd.dwFlags & DSBCAPS_CTRLPAN) ||
|
||||
|
@ -602,7 +602,7 @@ static void DSOUND_MixCancel(IDirectSoundBufferImpl *dsb, DWORD writepos, BOOL c
|
|||
((dsb->primary_mixpos < writepos) ? dsb->device->buflen : 0) +
|
||||
dsb->primary_mixpos - writepos;
|
||||
|
||||
TRACE("(%p, %ld), buf_mixpos=%ld\n", dsb, writepos, dsb->buf_mixpos);
|
||||
TRACE("(%p, %d), buf_mixpos=%d\n", dsb, writepos, dsb->buf_mixpos);
|
||||
|
||||
/* backtrack the mix position */
|
||||
size = primary_done / oAdvance;
|
||||
|
@ -634,7 +634,7 @@ static void DSOUND_MixCancel(IDirectSoundBufferImpl *dsb, DWORD writepos, BOOL c
|
|||
dsb->buf_mixpos = npos;
|
||||
dsb->primary_mixpos = writepos;
|
||||
|
||||
TRACE("new buf_mixpos=%ld, primary_mixpos=%ld (len=%ld)\n",
|
||||
TRACE("new buf_mixpos=%d, primary_mixpos=%d (len=%d)\n",
|
||||
dsb->buf_mixpos, dsb->primary_mixpos, len);
|
||||
|
||||
if (cancel) DSOUND_PhaseCancel(dsb, writepos, len);
|
||||
|
@ -652,7 +652,7 @@ void DSOUND_MixCancelAt(IDirectSoundBufferImpl *dsb, DWORD buf_writepos)
|
|||
dsb->buf_mixpos - buf_writepos;
|
||||
#endif
|
||||
|
||||
WARN("(%p, %ld), buf_mixpos=%ld\n", dsb, buf_writepos, dsb->buf_mixpos);
|
||||
WARN("(%p, %d), buf_mixpos=%d\n", dsb, buf_writepos, dsb->buf_mixpos);
|
||||
/* since this is not implemented yet, just cancel *ALL* prebuffering for now
|
||||
* (which is faster anyway when there's only a single secondary buffer) */
|
||||
dsb->device->need_remix = TRUE;
|
||||
|
@ -688,12 +688,12 @@ static DWORD DSOUND_MixOne(IDirectSoundBufferImpl *dsb, DWORD playpos, DWORD wri
|
|||
DWORD buf_left = dsb->buflen - buf_writepos;
|
||||
int still_behind;
|
||||
|
||||
TRACE("(%p,%ld,%ld,%ld)\n",dsb,playpos,writepos,mixlen);
|
||||
TRACE("buf_writepos=%ld, primary_writepos=%ld\n", buf_writepos, writepos);
|
||||
TRACE("buf_done=%ld, primary_done=%ld\n", buf_done, primary_done);
|
||||
TRACE("buf_mixpos=%ld, primary_mixpos=%ld, mixlen=%ld\n", dsb->buf_mixpos, dsb->primary_mixpos,
|
||||
TRACE("(%p,%d,%d,%d)\n",dsb,playpos,writepos,mixlen);
|
||||
TRACE("buf_writepos=%d, primary_writepos=%d\n", buf_writepos, writepos);
|
||||
TRACE("buf_done=%d, primary_done=%d\n", buf_done, primary_done);
|
||||
TRACE("buf_mixpos=%d, primary_mixpos=%d, mixlen=%d\n", dsb->buf_mixpos, dsb->primary_mixpos,
|
||||
mixlen);
|
||||
TRACE("looping=%ld, startpos=%ld, leadin=%ld\n", dsb->playflags, dsb->startpos, dsb->leadin);
|
||||
TRACE("looping=%d, startpos=%d, leadin=%d\n", dsb->playflags, dsb->startpos, dsb->leadin);
|
||||
|
||||
/* check for notification positions */
|
||||
if (dsb->dsbd.dwFlags & DSBCAPS_CTRLPOSITIONNOTIFY &&
|
||||
|
@ -711,7 +711,7 @@ static DWORD DSOUND_MixOne(IDirectSoundBufferImpl *dsb, DWORD playpos, DWORD wri
|
|||
(dsb->buf_mixpos < dsb->buflen)) {
|
||||
/* yes, have to recover */
|
||||
ERR("underrun on sound buffer %p\n", dsb);
|
||||
TRACE("recovering from underrun: primary_mixpos=%ld\n", writepos);
|
||||
TRACE("recovering from underrun: primary_mixpos=%d\n", writepos);
|
||||
}
|
||||
dsb->primary_mixpos = writepos;
|
||||
primary_done = 0;
|
||||
|
@ -735,7 +735,7 @@ static DWORD DSOUND_MixOne(IDirectSoundBufferImpl *dsb, DWORD playpos, DWORD wri
|
|||
(dsb->probably_valid_to == dsb->startpos) &&
|
||||
dsb->leadin)
|
||||
probably_valid_left = dsb->buflen;
|
||||
TRACE("streaming buffer probably_valid_to=%ld, probably_valid_left=%ld\n",
|
||||
TRACE("streaming buffer probably_valid_to=%d, probably_valid_left=%d\n",
|
||||
dsb->probably_valid_to, probably_valid_left);
|
||||
/* check whether the app's time is already up */
|
||||
if (probably_valid_left < dsb->writelead) {
|
||||
|
@ -753,7 +753,7 @@ static DWORD DSOUND_MixOne(IDirectSoundBufferImpl *dsb, DWORD playpos, DWORD wri
|
|||
dsb->device->pwfx->nBlockAlign;
|
||||
/* check whether to clip mix_len */
|
||||
if (probably_valid_left < mixlen) {
|
||||
TRACE("clipping to probably_valid_left=%ld\n", probably_valid_left);
|
||||
TRACE("clipping to probably_valid_left=%d\n", probably_valid_left);
|
||||
mixlen = probably_valid_left;
|
||||
}
|
||||
}
|
||||
|
@ -762,11 +762,11 @@ static DWORD DSOUND_MixOne(IDirectSoundBufferImpl *dsb, DWORD playpos, DWORD wri
|
|||
if (mixlen < primary_done) {
|
||||
/* huh? and still CalcPlayPosition didn't
|
||||
* detect an underrun? */
|
||||
FIXME("problem with underrun detection (mixlen=%ld < primary_done=%ld)\n", mixlen, primary_done);
|
||||
FIXME("problem with underrun detection (mixlen=%d < primary_done=%d)\n", mixlen, primary_done);
|
||||
return 0;
|
||||
}
|
||||
len = mixlen - primary_done;
|
||||
TRACE("remaining mixlen=%ld\n", len);
|
||||
TRACE("remaining mixlen=%d\n", len);
|
||||
|
||||
if (len < dsb->device->fraglen) {
|
||||
/* smaller than a fragment, wait until it gets larger
|
||||
|
@ -792,8 +792,8 @@ static DWORD DSOUND_MixOne(IDirectSoundBufferImpl *dsb, DWORD playpos, DWORD wri
|
|||
|
||||
if ((dsb->state == STATE_STOPPED) || !slen) break;
|
||||
}
|
||||
TRACE("new primary_mixpos=%ld, primary_advbase=%ld\n", dsb->primary_mixpos, dsb->device->mixpos);
|
||||
TRACE("mixed data len=%ld, still_behind=%d\n", mixlen-len, still_behind);
|
||||
TRACE("new primary_mixpos=%d, primary_advbase=%d\n", dsb->primary_mixpos, dsb->device->mixpos);
|
||||
TRACE("mixed data len=%d, still_behind=%d\n", mixlen-len, still_behind);
|
||||
|
||||
post_mix:
|
||||
/* check if buffer should be considered complete */
|
||||
|
@ -817,7 +817,7 @@ post_mix:
|
|||
dsb->device->mixpos;
|
||||
if (slen > mixlen) {
|
||||
/* the primary_done and still_behind checks above should have worked */
|
||||
FIXME("problem with advancement calculation (advlen=%ld > mixlen=%ld)\n", slen, mixlen);
|
||||
FIXME("problem with advancement calculation (advlen=%d > mixlen=%d)\n", slen, mixlen);
|
||||
slen = 0;
|
||||
}
|
||||
return slen;
|
||||
|
@ -828,12 +828,12 @@ static DWORD DSOUND_MixToPrimary(DirectSoundDevice *device, DWORD playpos, DWORD
|
|||
INT i, len, maxlen = 0;
|
||||
IDirectSoundBufferImpl *dsb;
|
||||
|
||||
TRACE("(%ld,%ld,%ld,%d)\n", playpos, writepos, mixlen, recover);
|
||||
TRACE("(%d,%d,%d,%d)\n", playpos, writepos, mixlen, recover);
|
||||
for (i = 0; i < device->nrofbuffers; i++) {
|
||||
dsb = device->buffers[i];
|
||||
|
||||
if (dsb->buflen && dsb->state && !dsb->hwbuf) {
|
||||
TRACE("Checking %p, mixlen=%ld\n", dsb, mixlen);
|
||||
TRACE("Checking %p, mixlen=%d\n", dsb, mixlen);
|
||||
EnterCriticalSection(&(dsb->lock));
|
||||
if (dsb->state == STATE_STOPPING) {
|
||||
DSOUND_MixCancel(dsb, writepos, TRUE);
|
||||
|
@ -868,7 +868,7 @@ static void DSOUND_MixReset(DirectSoundDevice *device, DWORD writepos)
|
|||
IDirectSoundBufferImpl *dsb;
|
||||
int nfiller;
|
||||
|
||||
TRACE("(%p,%ld)\n", device, writepos);
|
||||
TRACE("(%p,%d)\n", device, writepos);
|
||||
|
||||
/* the sound of silence */
|
||||
nfiller = device->pwfx->wBitsPerSample == 8 ? 128 : 0;
|
||||
|
@ -908,7 +908,7 @@ static void DSOUND_MixReset(DirectSoundDevice *device, DWORD writepos)
|
|||
|
||||
static void DSOUND_CheckReset(DirectSoundDevice *device, DWORD writepos)
|
||||
{
|
||||
TRACE("(%p,%ld)\n",device,writepos);
|
||||
TRACE("(%p,%d)\n",device,writepos);
|
||||
if (device->need_remix) {
|
||||
DSOUND_MixReset(device, writepos);
|
||||
device->need_remix = FALSE;
|
||||
|
@ -928,9 +928,9 @@ static void DSOUND_CheckReset(DirectSoundDevice *device, DWORD writepos)
|
|||
|
||||
void DSOUND_WaveQueue(DirectSoundDevice *device, DWORD mixq)
|
||||
{
|
||||
TRACE("(%p,%ld)\n", device, mixq);
|
||||
TRACE("(%p,%d)\n", device, mixq);
|
||||
if (mixq + device->pwqueue > ds_hel_queue) mixq = ds_hel_queue - device->pwqueue;
|
||||
TRACE("queueing %ld buffers, starting at %d\n", mixq, device->pwwrite);
|
||||
TRACE("queueing %d buffers, starting at %d\n", mixq, device->pwwrite);
|
||||
for (; mixq; mixq--) {
|
||||
waveOutWrite(device->hwo, device->pwave[device->pwwrite], sizeof(WAVEHDR));
|
||||
device->pwwrite++;
|
||||
|
@ -980,7 +980,7 @@ static void DSOUND_PerformMix(DirectSoundDevice *device)
|
|||
writepos %= device->buflen;
|
||||
}
|
||||
}
|
||||
TRACE("primary playpos=%ld, writepos=%ld, clrpos=%ld, mixpos=%ld, buflen=%ld\n",
|
||||
TRACE("primary playpos=%d, writepos=%d, clrpos=%d, mixpos=%d, buflen=%d\n",
|
||||
playpos,writepos,device->playpos,device->mixpos,device->buflen);
|
||||
assert(device->playpos < device->buflen);
|
||||
/* wipe out just-played sound data */
|
||||
|
@ -1020,7 +1020,7 @@ static void DSOUND_PerformMix(DirectSoundDevice *device)
|
|||
/* the playback position must have passed our last
|
||||
* mixed position, i.e. it's an underrun, or we have
|
||||
* nothing more to play */
|
||||
TRACE("reached end of mixed data (inq=%ld, maxq=%ld)\n", inq, maxq);
|
||||
TRACE("reached end of mixed data (inq=%d, maxq=%d)\n", inq, maxq);
|
||||
inq = 0;
|
||||
/* stop the playback now, to allow buffers to refill */
|
||||
if (device->state == STATE_PLAYING) {
|
||||
|
@ -1031,7 +1031,7 @@ static void DSOUND_PerformMix(DirectSoundDevice *device)
|
|||
}
|
||||
else {
|
||||
/* how can we have an underrun if we aren't playing? */
|
||||
WARN("unexpected primary state (%ld)\n", device->state);
|
||||
WARN("unexpected primary state (%d)\n", device->state);
|
||||
}
|
||||
#ifdef SYNC_CALLBACK
|
||||
/* DSOUND_callback may need this lock */
|
||||
|
@ -1114,7 +1114,7 @@ void CALLBACK DSOUND_timer(UINT timerID, UINT msg, DWORD_PTR dwUser,
|
|||
DWORD start_time = GetTickCount();
|
||||
DWORD end_time;
|
||||
TRACE("(%d,%d,0x%lx,0x%lx,0x%lx)\n",timerID,msg,dwUser,dw1,dw2);
|
||||
TRACE("entering at %ld\n", start_time);
|
||||
TRACE("entering at %d\n", start_time);
|
||||
|
||||
if (DSOUND_renderer[device->drvdesc.dnDevNode] != device) {
|
||||
ERR("dsound died without killing us?\n");
|
||||
|
@ -1131,14 +1131,14 @@ void CALLBACK DSOUND_timer(UINT timerID, UINT msg, DWORD_PTR dwUser,
|
|||
RtlReleaseResource(&(device->buffer_list_lock));
|
||||
|
||||
end_time = GetTickCount();
|
||||
TRACE("completed processing at %ld, duration = %ld\n", end_time, end_time - start_time);
|
||||
TRACE("completed processing at %d, duration = %d\n", end_time, end_time - start_time);
|
||||
}
|
||||
|
||||
void CALLBACK DSOUND_callback(HWAVEOUT hwo, UINT msg, DWORD dwUser, DWORD dw1, DWORD dw2)
|
||||
{
|
||||
DirectSoundDevice * device = (DirectSoundDevice*)dwUser;
|
||||
TRACE("(%p,%x,%lx,%lx,%lx)\n",hwo,msg,dwUser,dw1,dw2);
|
||||
TRACE("entering at %ld, msg=%08x(%s)\n", GetTickCount(), msg,
|
||||
TRACE("(%p,%x,%x,%x,%x)\n",hwo,msg,dwUser,dw1,dw2);
|
||||
TRACE("entering at %d, msg=%08x(%s)\n", GetTickCount(), msg,
|
||||
msg==MM_WOM_DONE ? "MM_WOM_DONE" : msg==MM_WOM_CLOSE ? "MM_WOM_CLOSE" :
|
||||
msg==MM_WOM_OPEN ? "MM_WOM_OPEN" : "UNKNOWN");
|
||||
if (msg == MM_WOM_DONE) {
|
||||
|
@ -1163,7 +1163,7 @@ void CALLBACK DSOUND_callback(HWAVEOUT hwo, UINT msg, DWORD dwUser, DWORD dw1, D
|
|||
mixq = inq / fraglen;
|
||||
if ((inq - (mixq * fraglen)) > 0) mixq++;
|
||||
/* complete the playing buffer */
|
||||
TRACE("done playing primary pos=%ld\n", playpos);
|
||||
TRACE("done playing primary pos=%d\n", playpos);
|
||||
pwplay++;
|
||||
if (pwplay >= DS_HEL_FRAGS) pwplay = 0;
|
||||
/* write new values */
|
||||
|
|
|
@ -51,7 +51,7 @@ static void DSOUND_RecalcPrimary(DirectSoundDevice *device)
|
|||
/* (FIXME: this may or may not be a good idea) */
|
||||
while (device->buflen % fraglen) fraglen -= nBlockAlign;
|
||||
device->fraglen = fraglen;
|
||||
TRACE("fraglen=%ld\n", device->fraglen);
|
||||
TRACE("fraglen=%d\n", device->fraglen);
|
||||
}
|
||||
/* calculate the 10ms write lead */
|
||||
device->writelead = (device->pwfx->nSamplesPerSec / 100) * nBlockAlign;
|
||||
|
@ -74,7 +74,7 @@ static HRESULT DSOUND_PrimaryOpen(DirectSoundDevice *device)
|
|||
/* use fragments of 10ms (1/100s) each (which should get us within
|
||||
* the documented write cursor lead of 10-15ms) */
|
||||
buflen = ((device->pwfx->nSamplesPerSec / 100) * device->pwfx->nBlockAlign) * DS_HEL_FRAGS;
|
||||
TRACE("desired buflen=%ld, old buffer=%p\n", buflen, device->buffer);
|
||||
TRACE("desired buflen=%d, old buffer=%p\n", buflen, device->buffer);
|
||||
/* reallocate emulated primary buffer */
|
||||
|
||||
if (device->buffer)
|
||||
|
@ -116,7 +116,7 @@ static HRESULT DSOUND_PrimaryOpen(DirectSoundDevice *device)
|
|||
device->playpos = 0;
|
||||
device->mixpos = 0;
|
||||
FillMemory(device->buffer, device->buflen, (device->pwfx->wBitsPerSample == 8) ? 128 : 0);
|
||||
TRACE("fraglen=%ld\n", device->fraglen);
|
||||
TRACE("fraglen=%d\n", device->fraglen);
|
||||
DSOUND_WaveQueue(device, (DWORD)-1);
|
||||
}
|
||||
if ((err == DS_OK) && (merr != DS_OK))
|
||||
|
@ -314,7 +314,7 @@ HRESULT DSOUND_PrimaryGetPosition(DirectSoundDevice *device, LPDWORD playpos, LP
|
|||
*writepos -= device->buflen;
|
||||
}
|
||||
}
|
||||
TRACE("playpos = %ld, writepos = %ld (%p, time=%ld)\n", playpos?*playpos:0, writepos?*writepos:0, device, GetTickCount());
|
||||
TRACE("playpos = %d, writepos = %d (%p, time=%d)\n", playpos?*playpos:0, writepos?*writepos:0, device, GetTickCount());
|
||||
return DS_OK;
|
||||
}
|
||||
|
||||
|
@ -335,8 +335,8 @@ HRESULT DSOUND_PrimarySetFormat(DirectSoundDevice *device, LPCWAVEFORMATEX wfex)
|
|||
WARN("invalid parameter: wfex==NULL!\n");
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
TRACE("(formattag=0x%04x,chans=%d,samplerate=%ld,"
|
||||
"bytespersec=%ld,blockalign=%d,bitspersamp=%d,cbSize=%d)\n",
|
||||
TRACE("(formattag=0x%04x,chans=%d,samplerate=%d,"
|
||||
"bytespersec=%d,blockalign=%d,bitspersamp=%d,cbSize=%d)\n",
|
||||
wfex->wFormatTag, wfex->nChannels, wfex->nSamplesPerSec,
|
||||
wfex->nAvgBytesPerSec, wfex->nBlockAlign,
|
||||
wfex->wBitsPerSample, wfex->cbSize);
|
||||
|
@ -443,7 +443,7 @@ static HRESULT WINAPI PrimaryBufferImpl_SetVolume(
|
|||
DWORD ampfactors;
|
||||
DSVOLUMEPAN volpan;
|
||||
HRESULT hres = DS_OK;
|
||||
TRACE("(%p,%ld)\n", iface, vol);
|
||||
TRACE("(%p,%d)\n", iface, vol);
|
||||
|
||||
if (!(device->dsbd.dwFlags & DSBCAPS_CTRLVOLUME)) {
|
||||
WARN("control unavailable\n");
|
||||
|
@ -451,7 +451,7 @@ static HRESULT WINAPI PrimaryBufferImpl_SetVolume(
|
|||
}
|
||||
|
||||
if ((vol > DSBVOLUME_MAX) || (vol < DSBVOLUME_MIN)) {
|
||||
WARN("invalid parameter: vol = %ld\n", vol);
|
||||
WARN("invalid parameter: vol = %d\n", vol);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -511,7 +511,7 @@ static HRESULT WINAPI PrimaryBufferImpl_SetFrequency(
|
|||
LPDIRECTSOUNDBUFFER8 iface,DWORD freq
|
||||
) {
|
||||
PrimaryBufferImpl *This = (PrimaryBufferImpl *)iface;
|
||||
TRACE("(%p,%ld)\n",This,freq);
|
||||
TRACE("(%p,%d)\n",This,freq);
|
||||
|
||||
/* You cannot set the frequency of the primary buffer */
|
||||
WARN("control unavailable\n");
|
||||
|
@ -522,10 +522,10 @@ static HRESULT WINAPI PrimaryBufferImpl_Play(
|
|||
LPDIRECTSOUNDBUFFER8 iface,DWORD reserved1,DWORD reserved2,DWORD flags
|
||||
) {
|
||||
DirectSoundDevice *device = ((PrimaryBufferImpl *)iface)->device;
|
||||
TRACE("(%p,%08lx,%08lx,%08lx)\n", iface, reserved1, reserved2, flags);
|
||||
TRACE("(%p,%08x,%08x,%08x)\n", iface, reserved1, reserved2, flags);
|
||||
|
||||
if (!(flags & DSBPLAY_LOOPING)) {
|
||||
WARN("invalid parameter: flags = %08lx\n", flags);
|
||||
WARN("invalid parameter: flags = %08x\n", flags);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -566,7 +566,7 @@ static ULONG WINAPI PrimaryBufferImpl_AddRef(LPDIRECTSOUNDBUFFER8 iface)
|
|||
{
|
||||
PrimaryBufferImpl *This = (PrimaryBufferImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -574,7 +574,7 @@ static ULONG WINAPI PrimaryBufferImpl_Release(LPDIRECTSOUNDBUFFER8 iface)
|
|||
{
|
||||
PrimaryBufferImpl *This = (PrimaryBufferImpl *)iface;
|
||||
DWORD ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
This->device->primary = NULL;
|
||||
|
@ -602,7 +602,7 @@ static HRESULT WINAPI PrimaryBufferImpl_GetCurrentPosition(
|
|||
*writepos += device->writelead;
|
||||
while (*writepos >= device->buflen) *writepos -= device->buflen;
|
||||
}
|
||||
TRACE("playpos = %ld, writepos = %ld (%p, time=%ld)\n", playpos?*playpos:0, writepos?*writepos:0, device, GetTickCount());
|
||||
TRACE("playpos = %d, writepos = %d (%p, time=%d)\n", playpos?*playpos:0, writepos?*writepos:0, device, GetTickCount());
|
||||
return DS_OK;
|
||||
}
|
||||
|
||||
|
@ -622,7 +622,7 @@ static HRESULT WINAPI PrimaryBufferImpl_GetStatus(
|
|||
(device->state == STATE_PLAYING))
|
||||
*status |= DSBSTATUS_PLAYING | DSBSTATUS_LOOPING;
|
||||
|
||||
TRACE("status=%lx\n", *status);
|
||||
TRACE("status=%x\n", *status);
|
||||
return DS_OK;
|
||||
}
|
||||
|
||||
|
@ -635,7 +635,7 @@ static HRESULT WINAPI PrimaryBufferImpl_GetFormat(
|
|||
{
|
||||
DWORD size;
|
||||
DirectSoundDevice *device = ((PrimaryBufferImpl *)iface)->device;
|
||||
TRACE("(%p,%p,%ld,%p)\n", iface, lpwf, wfsize, wfwritten);
|
||||
TRACE("(%p,%p,%d,%p)\n", iface, lpwf, wfsize, wfwritten);
|
||||
|
||||
size = sizeof(WAVEFORMATEX) + device->pwfx->cbSize;
|
||||
|
||||
|
@ -667,7 +667,7 @@ static HRESULT WINAPI PrimaryBufferImpl_Lock(
|
|||
) {
|
||||
HRESULT hres;
|
||||
DirectSoundDevice *device = ((PrimaryBufferImpl *)iface)->device;
|
||||
TRACE("(%p,%ld,%ld,%p,%p,%p,%p,0x%08lx) at %ld\n",
|
||||
TRACE("(%p,%d,%d,%p,%p,%p,%p,0x%08x) at %d\n",
|
||||
iface,
|
||||
writecursor,
|
||||
writebytes,
|
||||
|
@ -699,13 +699,13 @@ static HRESULT WINAPI PrimaryBufferImpl_Lock(
|
|||
writebytes = device->buflen;
|
||||
|
||||
if (writecursor >= device->buflen) {
|
||||
WARN("Invalid parameter, writecursor: %lu >= buflen: %lu\n",
|
||||
WARN("Invalid parameter, writecursor: %u >= buflen: %u\n",
|
||||
writecursor, device->buflen);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
if (writebytes > device->buflen) {
|
||||
WARN("Invalid parameter, writebytes: %lu > buflen: %lu\n",
|
||||
WARN("Invalid parameter, writebytes: %u > buflen: %u\n",
|
||||
writebytes, device->buflen);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
@ -728,7 +728,7 @@ static HRESULT WINAPI PrimaryBufferImpl_Lock(
|
|||
*(LPBYTE*)lplpaudioptr2 = NULL;
|
||||
if (audiobytes2)
|
||||
*audiobytes2 = 0;
|
||||
TRACE("->%ld.0\n",writebytes);
|
||||
TRACE("->%d.0\n",writebytes);
|
||||
} else {
|
||||
*(LPBYTE*)lplpaudioptr1 = device->buffer+writecursor;
|
||||
*audiobytes1 = device->buflen-writecursor;
|
||||
|
@ -736,7 +736,7 @@ static HRESULT WINAPI PrimaryBufferImpl_Lock(
|
|||
*(LPBYTE*)lplpaudioptr2 = device->buffer;
|
||||
if (audiobytes2)
|
||||
*audiobytes2 = writebytes-(device->buflen-writecursor);
|
||||
TRACE("->%ld.%ld\n",*audiobytes1,audiobytes2?*audiobytes2:0);
|
||||
TRACE("->%d.%d\n",*audiobytes1,audiobytes2?*audiobytes2:0);
|
||||
}
|
||||
}
|
||||
return DS_OK;
|
||||
|
@ -746,7 +746,7 @@ static HRESULT WINAPI PrimaryBufferImpl_SetCurrentPosition(
|
|||
LPDIRECTSOUNDBUFFER8 iface,DWORD newpos
|
||||
) {
|
||||
PrimaryBufferImpl *This = (PrimaryBufferImpl *)iface;
|
||||
TRACE("(%p,%ld)\n",This,newpos);
|
||||
TRACE("(%p,%d)\n",This,newpos);
|
||||
|
||||
/* You cannot set the position of the primary buffer */
|
||||
WARN("invalid call\n");
|
||||
|
@ -760,7 +760,7 @@ static HRESULT WINAPI PrimaryBufferImpl_SetPan(
|
|||
DWORD ampfactors;
|
||||
DSVOLUMEPAN volpan;
|
||||
HRESULT hres = DS_OK;
|
||||
TRACE("(%p,%ld)\n", iface, pan);
|
||||
TRACE("(%p,%d)\n", iface, pan);
|
||||
|
||||
if (!(device->dsbd.dwFlags & DSBCAPS_CTRLPAN)) {
|
||||
WARN("control unavailable\n");
|
||||
|
@ -768,7 +768,7 @@ static HRESULT WINAPI PrimaryBufferImpl_SetPan(
|
|||
}
|
||||
|
||||
if ((pan > DSBPAN_RIGHT) || (pan < DSBPAN_LEFT)) {
|
||||
WARN("invalid parameter: pan = %ld\n", pan);
|
||||
WARN("invalid parameter: pan = %d\n", pan);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -828,7 +828,7 @@ static HRESULT WINAPI PrimaryBufferImpl_Unlock(
|
|||
LPDIRECTSOUNDBUFFER8 iface,LPVOID p1,DWORD x1,LPVOID p2,DWORD x2
|
||||
) {
|
||||
DirectSoundDevice *device = ((PrimaryBufferImpl *)iface)->device;
|
||||
TRACE("(%p,%p,%ld,%p,%ld)\n", iface, p1, x1, p2, x2);
|
||||
TRACE("(%p,%p,%d,%p,%d)\n", iface, p1, x1, p2, x2);
|
||||
|
||||
if (device->priolevel != DSSCL_WRITEPRIMARY) {
|
||||
WARN("failed priority check!\n");
|
||||
|
@ -873,7 +873,7 @@ static HRESULT WINAPI PrimaryBufferImpl_GetFrequency(
|
|||
}
|
||||
|
||||
*freq = device->pwfx->nSamplesPerSec;
|
||||
TRACE("-> %ld\n", *freq);
|
||||
TRACE("-> %d\n", *freq);
|
||||
|
||||
return DS_OK;
|
||||
}
|
||||
|
@ -883,7 +883,7 @@ static HRESULT WINAPI PrimaryBufferImpl_SetFX(
|
|||
) {
|
||||
PrimaryBufferImpl *This = (PrimaryBufferImpl *)iface;
|
||||
DWORD u;
|
||||
FIXME("(%p,%lu,%p,%p): stub\n",This,dwEffectsCount,pDSFXDesc,pdwResultCodes);
|
||||
FIXME("(%p,%u,%p,%p): stub\n",This,dwEffectsCount,pDSFXDesc,pdwResultCodes);
|
||||
|
||||
if (pdwResultCodes)
|
||||
for (u=0; u<dwEffectsCount; u++) pdwResultCodes[u] = DSFXR_UNKNOWN;
|
||||
|
@ -897,7 +897,7 @@ static HRESULT WINAPI PrimaryBufferImpl_AcquireResources(
|
|||
) {
|
||||
PrimaryBufferImpl *This = (PrimaryBufferImpl *)iface;
|
||||
DWORD u;
|
||||
FIXME("(%p,%08lu,%lu,%p): stub\n",This,dwFlags,dwEffectsCount,pdwResultCodes);
|
||||
FIXME("(%p,%08u,%u,%p): stub\n",This,dwFlags,dwEffectsCount,pdwResultCodes);
|
||||
|
||||
if (pdwResultCodes)
|
||||
for (u=0; u<dwEffectsCount; u++) pdwResultCodes[u] = DSFXR_UNKNOWN;
|
||||
|
@ -910,7 +910,7 @@ static HRESULT WINAPI PrimaryBufferImpl_GetObjectInPath(
|
|||
LPDIRECTSOUNDBUFFER8 iface,REFGUID rguidObject,DWORD dwIndex,REFGUID rguidInterface,LPVOID* ppObject
|
||||
) {
|
||||
PrimaryBufferImpl *This = (PrimaryBufferImpl *)iface;
|
||||
FIXME("(%p,%s,%lu,%s,%p): stub\n",This,debugstr_guid(rguidObject),dwIndex,debugstr_guid(rguidInterface),ppObject);
|
||||
FIXME("(%p,%s,%u,%s,%p): stub\n",This,debugstr_guid(rguidObject),dwIndex,debugstr_guid(rguidInterface),ppObject);
|
||||
|
||||
WARN("control unavailable\n");
|
||||
return DSERR_CONTROLUNAVAIL;
|
||||
|
@ -938,7 +938,7 @@ static HRESULT WINAPI PrimaryBufferImpl_GetCaps(
|
|||
}
|
||||
|
||||
if (caps->dwSize < sizeof(*caps)) {
|
||||
WARN("invalid parameter: caps->dwSize = %ld\n", caps->dwSize);
|
||||
WARN("invalid parameter: caps->dwSize = %d\n", caps->dwSize);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -1076,8 +1076,8 @@ HRESULT PrimaryBufferImpl_Create(
|
|||
CopyMemory(&device->dsbd, dsbd, sizeof(*dsbd));
|
||||
|
||||
TRACE("Created primary buffer at %p\n", dsb);
|
||||
TRACE("(formattag=0x%04x,chans=%d,samplerate=%ld,"
|
||||
"bytespersec=%ld,blockalign=%d,bitspersamp=%d,cbSize=%d)\n",
|
||||
TRACE("(formattag=0x%04x,chans=%d,samplerate=%d,"
|
||||
"bytespersec=%d,blockalign=%d,bitspersamp=%d,cbSize=%d)\n",
|
||||
device->pwfx->wFormatTag, device->pwfx->nChannels,
|
||||
device->pwfx->nSamplesPerSec, device->pwfx->nAvgBytesPerSec,
|
||||
device->pwfx->nBlockAlign, device->pwfx->wBitsPerSample,
|
||||
|
|
|
@ -66,7 +66,7 @@ static ULONG WINAPI IKsBufferPropertySetImpl_AddRef(LPKSPROPERTYSET iface)
|
|||
{
|
||||
IKsBufferPropertySetImpl *This = (IKsBufferPropertySetImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -74,7 +74,7 @@ static ULONG WINAPI IKsBufferPropertySetImpl_Release(LPKSPROPERTYSET iface)
|
|||
{
|
||||
IKsBufferPropertySetImpl *This = (IKsBufferPropertySetImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
This->dsb->iks = 0;
|
||||
|
@ -97,7 +97,7 @@ static HRESULT WINAPI IKsBufferPropertySetImpl_Get(
|
|||
{
|
||||
IKsBufferPropertySetImpl *This = (IKsBufferPropertySetImpl *)iface;
|
||||
PIDSDRIVERPROPERTYSET ps;
|
||||
TRACE("(iface=%p,guidPropSet=%s,dwPropID=%ld,pInstanceData=%p,cbInstanceData=%ld,pPropData=%p,cbPropData=%ld,pcbReturned=%p)\n",
|
||||
TRACE("(iface=%p,guidPropSet=%s,dwPropID=%d,pInstanceData=%p,cbInstanceData=%d,pPropData=%p,cbPropData=%d,pcbReturned=%p)\n",
|
||||
This,debugstr_guid(guidPropSet),dwPropID,pInstanceData,cbInstanceData,pPropData,cbPropData,pcbReturned);
|
||||
|
||||
if (This->dsb->hwbuf) {
|
||||
|
@ -134,7 +134,7 @@ static HRESULT WINAPI IKsBufferPropertySetImpl_Set(
|
|||
{
|
||||
IKsBufferPropertySetImpl *This = (IKsBufferPropertySetImpl *)iface;
|
||||
PIDSDRIVERPROPERTYSET ps;
|
||||
TRACE("(%p,%s,%ld,%p,%ld,%p,%ld)\n",This,debugstr_guid(guidPropSet),dwPropID,pInstanceData,cbInstanceData,pPropData,cbPropData);
|
||||
TRACE("(%p,%s,%d,%p,%d,%p,%d)\n",This,debugstr_guid(guidPropSet),dwPropID,pInstanceData,cbInstanceData,pPropData,cbPropData);
|
||||
|
||||
if (This->dsb->hwbuf) {
|
||||
IDsDriver_QueryInterface(This->dsb->hwbuf, &IID_IDsDriverPropertySet, (void **)&ps);
|
||||
|
@ -166,7 +166,7 @@ static HRESULT WINAPI IKsBufferPropertySetImpl_QuerySupport(
|
|||
{
|
||||
IKsBufferPropertySetImpl *This = (IKsBufferPropertySetImpl *)iface;
|
||||
PIDSDRIVERPROPERTYSET ps;
|
||||
TRACE("(%p,%s,%ld,%p)\n",This,debugstr_guid(guidPropSet),dwPropID,pTypeSupport);
|
||||
TRACE("(%p,%s,%d,%p)\n",This,debugstr_guid(guidPropSet),dwPropID,pTypeSupport);
|
||||
|
||||
if (This->dsb->hwbuf) {
|
||||
IDsDriver_QueryInterface(This->dsb->hwbuf, &IID_IDsDriverPropertySet, (void **)&ps);
|
||||
|
@ -250,7 +250,7 @@ static ULONG WINAPI IKsPrivatePropertySetImpl_AddRef(LPKSPROPERTYSET iface)
|
|||
{
|
||||
IKsPrivatePropertySetImpl *This = (IKsPrivatePropertySetImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -258,7 +258,7 @@ static ULONG WINAPI IKsPrivatePropertySetImpl_Release(LPKSPROPERTYSET iface)
|
|||
{
|
||||
IKsPrivatePropertySetImpl *This = (IKsPrivatePropertySetImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
HeapFree(GetProcessHeap(), 0, This);
|
||||
|
@ -274,7 +274,7 @@ static HRESULT WINAPI DSPROPERTY_WaveDeviceMappingA(
|
|||
{
|
||||
HRESULT hr = DSERR_INVALIDPARAM;
|
||||
PDSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A_DATA ppd;
|
||||
TRACE("(pPropData=%p,cbPropData=%ld,pcbReturned=%p)\n",
|
||||
TRACE("(pPropData=%p,cbPropData=%d,pcbReturned=%p)\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
|
||||
ppd = (PDSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_A_DATA) pPropData;
|
||||
|
@ -337,7 +337,7 @@ static HRESULT WINAPI DSPROPERTY_WaveDeviceMappingW(
|
|||
{
|
||||
HRESULT hr = DSERR_INVALIDPARAM;
|
||||
PDSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_W_DATA ppd;
|
||||
TRACE("(pPropData=%p,cbPropData=%ld,pcbReturned=%p)\n",
|
||||
TRACE("(pPropData=%p,cbPropData=%d,pcbReturned=%p)\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
|
||||
ppd = (PDSPROPERTY_DIRECTSOUNDDEVICE_WAVEDEVICEMAPPING_W_DATA) pPropData;
|
||||
|
@ -401,7 +401,7 @@ static HRESULT WINAPI DSPROPERTY_Description1(
|
|||
HRESULT err;
|
||||
GUID guid, dev_guid;
|
||||
PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_1_DATA ppd;
|
||||
TRACE("(pPropData=%p,cbPropData=%ld,pcbReturned=%p)\n",
|
||||
TRACE("(pPropData=%p,cbPropData=%d,pcbReturned=%p)\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
|
||||
ppd = (PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_1_DATA) pPropData;
|
||||
|
@ -421,7 +421,7 @@ static HRESULT WINAPI DSPROPERTY_Description1(
|
|||
} else {
|
||||
TRACE("DataFlow=Unknown(%d)\n", ppd->DataFlow);
|
||||
}
|
||||
FIXME("(pPropData=%p,cbPropData=%ld,pcbReturned=%p) GUID_NULL not implemented!\n",
|
||||
FIXME("(pPropData=%p,cbPropData=%d,pcbReturned=%p) GUID_NULL not implemented!\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
return E_PROP_ID_UNSUPPORTED;
|
||||
}
|
||||
|
@ -567,7 +567,7 @@ static HRESULT WINAPI DSPROPERTY_Description1(
|
|||
|
||||
if (pcbReturned) {
|
||||
*pcbReturned = cbPropData;
|
||||
TRACE("*pcbReturned=%ld\n", *pcbReturned);
|
||||
TRACE("*pcbReturned=%d\n", *pcbReturned);
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
|
@ -581,7 +581,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionA(
|
|||
PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_A_DATA ppd = (PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_A_DATA) pPropData;
|
||||
HRESULT err;
|
||||
GUID dev_guid;
|
||||
TRACE("(pPropData=%p,cbPropData=%ld,pcbReturned=%p)\n",
|
||||
TRACE("(pPropData=%p,cbPropData=%d,pcbReturned=%p)\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
|
||||
TRACE("DeviceId=%s\n",debugstr_guid(&ppd->DeviceId));
|
||||
|
@ -594,7 +594,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionA(
|
|||
} else {
|
||||
TRACE("DataFlow=Unknown(%d)\n", ppd->DataFlow);
|
||||
}
|
||||
FIXME("(pPropData=%p,cbPropData=%ld,pcbReturned=%p) GUID_NULL not implemented!\n",
|
||||
FIXME("(pPropData=%p,cbPropData=%d,pcbReturned=%p) GUID_NULL not implemented!\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
return E_PROP_ID_UNSUPPORTED;
|
||||
}
|
||||
|
@ -710,7 +710,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionA(
|
|||
for (wod = 0; wod < wodn; wod++) {
|
||||
if (IsEqualGUID( &ppd->DeviceId, &DSOUND_renderer_guids[wod] ) ) {
|
||||
DSDRIVERDESC desc;
|
||||
TRACE("DSOUND_renderer_guids[%ld]\n", wod);
|
||||
TRACE("DSOUND_renderer_guids[%d]\n", wod);
|
||||
ppd->DataFlow = DIRECTSOUNDDEVICE_DATAFLOW_RENDER;
|
||||
ppd->WaveDeviceId = wod;
|
||||
err = mmErr(waveOutMessage((HWAVEOUT)wod,DRV_QUERYDSOUNDDESC,(DWORD_PTR)&(desc),0));
|
||||
|
@ -759,7 +759,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionA(
|
|||
for (wid = 0; wid < widn; wid++) {
|
||||
if (IsEqualGUID( &ppd->DeviceId, &DSOUND_capture_guids[wid] ) ) {
|
||||
DSDRIVERDESC desc;
|
||||
TRACE("DSOUND_capture_guids[%ld]\n", wid);
|
||||
TRACE("DSOUND_capture_guids[%d]\n", wid);
|
||||
ppd->WaveDeviceId = wid;
|
||||
err = mmErr(waveInMessage((HWAVEIN)wid,DRV_QUERYDSOUNDDESC,(DWORD_PTR)&(desc),0));
|
||||
if (err == DS_OK) {
|
||||
|
@ -807,7 +807,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionA(
|
|||
|
||||
if (pcbReturned) {
|
||||
*pcbReturned = cbPropData;
|
||||
TRACE("*pcbReturned=%ld\n", *pcbReturned);
|
||||
TRACE("*pcbReturned=%d\n", *pcbReturned);
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
|
@ -821,7 +821,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionW(
|
|||
PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_W_DATA ppd = (PDSPROPERTY_DIRECTSOUNDDEVICE_DESCRIPTION_W_DATA) pPropData;
|
||||
HRESULT err;
|
||||
GUID dev_guid;
|
||||
TRACE("pPropData=%p,cbPropData=%ld,pcbReturned=%p)\n",
|
||||
TRACE("pPropData=%p,cbPropData=%d,pcbReturned=%p)\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
|
||||
TRACE("DeviceId=%s\n",debugstr_guid(&ppd->DeviceId));
|
||||
|
@ -834,7 +834,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionW(
|
|||
} else {
|
||||
TRACE("DataFlow=Unknown(%d)\n", ppd->DataFlow);
|
||||
}
|
||||
FIXME("(pPropData=%p,cbPropData=%ld,pcbReturned=%p) GUID_NULL not implemented!\n",
|
||||
FIXME("(pPropData=%p,cbPropData=%d,pcbReturned=%p) GUID_NULL not implemented!\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
return E_PROP_ID_UNSUPPORTED;
|
||||
}
|
||||
|
@ -855,7 +855,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionW(
|
|||
for (wod = 0; wod < wodn; wod++) {
|
||||
if (IsEqualGUID( &dev_guid, &DSOUND_renderer_guids[wod] ) ) {
|
||||
DSDRIVERDESC desc;
|
||||
TRACE("DSOUND_renderer_guids[%ld]\n", wod);
|
||||
TRACE("DSOUND_renderer_guids[%d]\n", wod);
|
||||
ppd->WaveDeviceId = wod;
|
||||
err = mmErr(waveOutMessage((HWAVEOUT)wod,DRV_QUERYDSOUNDDESC,(DWORD_PTR)&(desc),0));
|
||||
if (err == DS_OK) {
|
||||
|
@ -951,7 +951,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionW(
|
|||
for (wod = 0; wod < wodn; wod++) {
|
||||
if (IsEqualGUID( &ppd->DeviceId, &DSOUND_renderer_guids[wod] ) ) {
|
||||
DSDRIVERDESC desc;
|
||||
TRACE("DSOUND_renderer_guids[%ld]\n", wod);
|
||||
TRACE("DSOUND_renderer_guids[%d]\n", wod);
|
||||
ppd->DataFlow = DIRECTSOUNDDEVICE_DATAFLOW_RENDER;
|
||||
ppd->WaveDeviceId = wod;
|
||||
err = mmErr(waveOutMessage((HWAVEOUT)wod,DRV_QUERYDSOUNDDESC,(DWORD_PTR)&(desc),0));
|
||||
|
@ -1000,7 +1000,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionW(
|
|||
for (wid = 0; wid < widn; wid++) {
|
||||
if (IsEqualGUID( &dev_guid, &DSOUND_capture_guids[wid] ) ) {
|
||||
DSDRIVERDESC desc;
|
||||
TRACE("DSOUND_capture_guids[%ld]\n", wid);
|
||||
TRACE("DSOUND_capture_guids[%d]\n", wid);
|
||||
ppd->WaveDeviceId = wid;
|
||||
err = mmErr(waveInMessage((HWAVEIN)wid,DRV_QUERYDSOUNDDESC,(DWORD_PTR)&(desc),0));
|
||||
if (err == DS_OK) {
|
||||
|
@ -1048,7 +1048,7 @@ static HRESULT WINAPI DSPROPERTY_DescriptionW(
|
|||
|
||||
if (pcbReturned) {
|
||||
*pcbReturned = cbPropData;
|
||||
TRACE("*pcbReturned=%ld\n", *pcbReturned);
|
||||
TRACE("*pcbReturned=%d\n", *pcbReturned);
|
||||
}
|
||||
|
||||
return S_OK;
|
||||
|
@ -1061,7 +1061,7 @@ static HRESULT WINAPI DSPROPERTY_Enumerate1(
|
|||
{
|
||||
PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_1_DATA ppd = (PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_1_DATA) pPropData;
|
||||
HRESULT err;
|
||||
TRACE("(pPropData=%p,cbPropData=%ld,pcbReturned=%p)\n",
|
||||
TRACE("(pPropData=%p,cbPropData=%d,pcbReturned=%p)\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
|
||||
if (ppd) {
|
||||
|
@ -1130,7 +1130,7 @@ static HRESULT WINAPI DSPROPERTY_Enumerate1(
|
|||
|
||||
if (pcbReturned) {
|
||||
*pcbReturned = 0;
|
||||
FIXME("*pcbReturned=%ld\n", *pcbReturned);
|
||||
FIXME("*pcbReturned=%d\n", *pcbReturned);
|
||||
}
|
||||
|
||||
return E_PROP_ID_UNSUPPORTED;
|
||||
|
@ -1143,7 +1143,7 @@ static HRESULT WINAPI DSPROPERTY_EnumerateA(
|
|||
{
|
||||
PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_A_DATA ppd = (PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_A_DATA) pPropData;
|
||||
HRESULT err;
|
||||
TRACE("(pPropData=%p,cbPropData=%ld,pcbReturned=%p)\n",
|
||||
TRACE("(pPropData=%p,cbPropData=%d,pcbReturned=%p)\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
|
||||
if (ppd) {
|
||||
|
@ -1240,7 +1240,7 @@ static HRESULT WINAPI DSPROPERTY_EnumerateA(
|
|||
|
||||
if (pcbReturned) {
|
||||
*pcbReturned = 0;
|
||||
FIXME("*pcbReturned=%ld\n", *pcbReturned);
|
||||
FIXME("*pcbReturned=%d\n", *pcbReturned);
|
||||
}
|
||||
|
||||
return E_PROP_ID_UNSUPPORTED;
|
||||
|
@ -1253,7 +1253,7 @@ static HRESULT WINAPI DSPROPERTY_EnumerateW(
|
|||
{
|
||||
PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W_DATA ppd = (PDSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W_DATA) pPropData;
|
||||
HRESULT err;
|
||||
TRACE("(pPropData=%p,cbPropData=%ld,pcbReturned=%p)\n",
|
||||
TRACE("(pPropData=%p,cbPropData=%d,pcbReturned=%p)\n",
|
||||
pPropData,cbPropData,pcbReturned);
|
||||
|
||||
if (ppd) {
|
||||
|
@ -1359,7 +1359,7 @@ static HRESULT WINAPI DSPROPERTY_EnumerateW(
|
|||
|
||||
if (pcbReturned) {
|
||||
*pcbReturned = 0;
|
||||
FIXME("*pcbReturned=%ld\n", *pcbReturned);
|
||||
FIXME("*pcbReturned=%d\n", *pcbReturned);
|
||||
}
|
||||
|
||||
return E_PROP_ID_UNSUPPORTED;
|
||||
|
@ -1376,7 +1376,7 @@ static HRESULT WINAPI IKsPrivatePropertySetImpl_Get(
|
|||
PULONG pcbReturned )
|
||||
{
|
||||
IKsPrivatePropertySetImpl *This = (IKsPrivatePropertySetImpl *)iface;
|
||||
TRACE("(iface=%p,guidPropSet=%s,dwPropID=%ld,pInstanceData=%p,cbInstanceData=%ld,pPropData=%p,cbPropData=%ld,pcbReturned=%p)\n",
|
||||
TRACE("(iface=%p,guidPropSet=%s,dwPropID=%d,pInstanceData=%p,cbInstanceData=%d,pPropData=%p,cbPropData=%d,pcbReturned=%p)\n",
|
||||
This,debugstr_guid(guidPropSet),dwPropID,pInstanceData,cbInstanceData,pPropData,cbPropData,pcbReturned);
|
||||
|
||||
if ( IsEqualGUID( &DSPROPSETID_DirectSoundDevice, guidPropSet) ) {
|
||||
|
@ -1398,7 +1398,7 @@ static HRESULT WINAPI IKsPrivatePropertySetImpl_Get(
|
|||
case DSPROPERTY_DIRECTSOUNDDEVICE_ENUMERATE_W:
|
||||
return DSPROPERTY_EnumerateW(pPropData,cbPropData,pcbReturned);
|
||||
default:
|
||||
FIXME("unsupported ID: %ld\n",dwPropID);
|
||||
FIXME("unsupported ID: %d\n",dwPropID);
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
|
@ -1407,7 +1407,7 @@ static HRESULT WINAPI IKsPrivatePropertySetImpl_Get(
|
|||
|
||||
if (pcbReturned) {
|
||||
*pcbReturned = 0;
|
||||
FIXME("*pcbReturned=%ld\n", *pcbReturned);
|
||||
FIXME("*pcbReturned=%d\n", *pcbReturned);
|
||||
}
|
||||
|
||||
return E_PROP_ID_UNSUPPORTED;
|
||||
|
@ -1424,7 +1424,7 @@ static HRESULT WINAPI IKsPrivatePropertySetImpl_Set(
|
|||
{
|
||||
IKsPrivatePropertySetImpl *This = (IKsPrivatePropertySetImpl *)iface;
|
||||
|
||||
FIXME("(%p,%s,%ld,%p,%ld,%p,%ld), stub!\n",This,debugstr_guid(guidPropSet),dwPropID,pInstanceData,cbInstanceData,pPropData,cbPropData);
|
||||
FIXME("(%p,%s,%d,%p,%d,%p,%d), stub!\n",This,debugstr_guid(guidPropSet),dwPropID,pInstanceData,cbInstanceData,pPropData,cbPropData);
|
||||
return E_PROP_ID_UNSUPPORTED;
|
||||
}
|
||||
|
||||
|
@ -1435,7 +1435,7 @@ static HRESULT WINAPI IKsPrivatePropertySetImpl_QuerySupport(
|
|||
PULONG pTypeSupport )
|
||||
{
|
||||
IKsPrivatePropertySetImpl *This = (IKsPrivatePropertySetImpl *)iface;
|
||||
TRACE("(%p,%s,%ld,%p)\n",This,debugstr_guid(guidPropSet),dwPropID,pTypeSupport);
|
||||
TRACE("(%p,%s,%d,%p)\n",This,debugstr_guid(guidPropSet),dwPropID,pTypeSupport);
|
||||
|
||||
if ( IsEqualGUID( &DSPROPSETID_DirectSoundDevice, guidPropSet) ) {
|
||||
switch (dwPropID) {
|
||||
|
@ -1464,7 +1464,7 @@ static HRESULT WINAPI IKsPrivatePropertySetImpl_QuerySupport(
|
|||
*pTypeSupport = KSPROPERTY_SUPPORT_GET;
|
||||
return S_OK;
|
||||
default:
|
||||
FIXME("unsupported ID: %ld\n",dwPropID);
|
||||
FIXME("unsupported ID: %d\n",dwPropID);
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
|
|
|
@ -244,7 +244,7 @@ void DSOUND_Calc3DBuffer(IDirectSoundBufferImpl *dsb)
|
|||
lVolume = log10(flIntensity/DEFAULT_INTENSITY);
|
||||
lVolume *= 1000; /* convert back to hundreths of dB */
|
||||
lVolume -= 10000; /* we need to do it in ms way */
|
||||
TRACE("dist. att: Distance = %f, MinDistance = %f => adjusting volume %ld to %f\n", flDistance, dsb->ds3db_ds3db.flMinDistance, dsb->ds3db_lVolume, lVolume);
|
||||
TRACE("dist. att: Distance = %f, MinDistance = %f => adjusting volume %d to %f\n", flDistance, dsb->ds3db_ds3db.flMinDistance, dsb->ds3db_lVolume, lVolume);
|
||||
|
||||
/* conning */
|
||||
/* sometimes it happens that vConeOrientation vector = (0,0,0); in this case angle is "nan" and it's useless*/
|
||||
|
@ -271,7 +271,7 @@ void DSOUND_Calc3DBuffer(IDirectSoundBufferImpl *dsb)
|
|||
/* this probably isn't the right thing, but it's ok for the time being */
|
||||
lVolume += ((dsb->ds3db_ds3db.lConeOutsideVolume)/((dwOutsideConeAngle) - (dwInsideConeAngle))) * flAngle;
|
||||
}
|
||||
TRACE("conning: Angle = %f deg; InsideConeAngle(/2) = %ld deg; OutsideConeAngle(/2) = %ld deg; ConeOutsideVolume = %ld => adjusting volume to %f\n",
|
||||
TRACE("conning: Angle = %f deg; InsideConeAngle(/2) = %d deg; OutsideConeAngle(/2) = %d deg; ConeOutsideVolume = %d => adjusting volume to %f\n",
|
||||
flAngle, dsb->ds3db_ds3db.dwInsideConeAngle/2, dsb->ds3db_ds3db.dwOutsideConeAngle/2, dsb->ds3db_ds3db.lConeOutsideVolume, lVolume);
|
||||
}
|
||||
dsb->volpan.lVolume = lVolume;
|
||||
|
@ -291,7 +291,7 @@ void DSOUND_Calc3DBuffer(IDirectSoundBufferImpl *dsb)
|
|||
/* for now, we'll use "linear formula" (which is probably incorrect); if someone has it in book, correct it */
|
||||
dsb->volpan.lPan = 10000*2*flAngle/M_PI - 10000;
|
||||
}
|
||||
TRACE("panning: Angle = %f rad, lPan = %ld\n", flAngle, dsb->volpan.lPan);
|
||||
TRACE("panning: Angle = %f rad, lPan = %d\n", flAngle, dsb->volpan.lPan);
|
||||
|
||||
/* FIXME: Doppler Effect disabled since i have no idea which frequency to change and how to do it */
|
||||
#if 0
|
||||
|
@ -367,7 +367,7 @@ static ULONG WINAPI IDirectSound3DBufferImpl_AddRef(LPDIRECTSOUND3DBUFFER iface)
|
|||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -375,7 +375,7 @@ static ULONG WINAPI IDirectSound3DBufferImpl_Release(LPDIRECTSOUND3DBUFFER iface
|
|||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
This->dsb->ds3db = NULL;
|
||||
|
@ -400,7 +400,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_GetAllParameters(
|
|||
}
|
||||
|
||||
if (lpDs3dBuffer->dwSize < sizeof(*lpDs3dBuffer)) {
|
||||
WARN("invalid parameter: lpDs3dBuffer->dwSize = %ld\n",lpDs3dBuffer->dwSize);
|
||||
WARN("invalid parameter: lpDs3dBuffer->dwSize = %d\n",lpDs3dBuffer->dwSize);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -415,7 +415,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_GetConeAngles(
|
|||
LPDWORD lpdwOutsideConeAngle)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("returning: Inside Cone Angle = %ld degrees; Outside Cone Angle = %ld degrees\n",
|
||||
TRACE("returning: Inside Cone Angle = %d degrees; Outside Cone Angle = %d degrees\n",
|
||||
This->dsb->ds3db_ds3db.dwInsideConeAngle, This->dsb->ds3db_ds3db.dwOutsideConeAngle);
|
||||
*lpdwInsideConeAngle = This->dsb->ds3db_ds3db.dwInsideConeAngle;
|
||||
*lpdwOutsideConeAngle = This->dsb->ds3db_ds3db.dwOutsideConeAngle;
|
||||
|
@ -440,7 +440,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_GetConeOutsideVolume(
|
|||
LPLONG lplConeOutsideVolume)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("returning: Cone Outside Volume = %ld\n", This->dsb->ds3db_ds3db.lConeOutsideVolume);
|
||||
TRACE("returning: Cone Outside Volume = %d\n", This->dsb->ds3db_ds3db.lConeOutsideVolume);
|
||||
*lplConeOutsideVolume = This->dsb->ds3db_ds3db.lConeOutsideVolume;
|
||||
return DS_OK;
|
||||
}
|
||||
|
@ -470,7 +470,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_GetMode(
|
|||
LPDWORD lpdwMode)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("returning: Mode = %ld\n", This->dsb->ds3db_ds3db.dwMode);
|
||||
TRACE("returning: Mode = %d\n", This->dsb->ds3db_ds3db.dwMode);
|
||||
*lpdwMode = This->dsb->ds3db_ds3db.dwMode;
|
||||
return DS_OK;
|
||||
}
|
||||
|
@ -508,7 +508,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_SetAllParameters(
|
|||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
DWORD status = DSERR_INVALIDPARAM;
|
||||
TRACE("(%p,%p,%lx)\n",iface,lpcDs3dBuffer,dwApply);
|
||||
TRACE("(%p,%p,%x)\n",iface,lpcDs3dBuffer,dwApply);
|
||||
|
||||
if (lpcDs3dBuffer == NULL) {
|
||||
WARN("invalid parameter: lpcDs3dBuffer == NULL\n");
|
||||
|
@ -516,11 +516,11 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_SetAllParameters(
|
|||
}
|
||||
|
||||
if (lpcDs3dBuffer->dwSize != sizeof(DS3DBUFFER)) {
|
||||
WARN("invalid parameter: lpcDs3dBuffer->dwSize = %ld\n", lpcDs3dBuffer->dwSize);
|
||||
WARN("invalid parameter: lpcDs3dBuffer->dwSize = %d\n", lpcDs3dBuffer->dwSize);
|
||||
return status;
|
||||
}
|
||||
|
||||
TRACE("setting: all parameters; dwApply = %ld\n", dwApply);
|
||||
TRACE("setting: all parameters; dwApply = %d\n", dwApply);
|
||||
This->dsb->ds3db_ds3db = *lpcDs3dBuffer;
|
||||
|
||||
if (dwApply == DS3D_IMMEDIATE)
|
||||
|
@ -540,7 +540,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_SetConeAngles(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("setting: Inside Cone Angle = %ld; Outside Cone Angle = %ld; dwApply = %ld\n",
|
||||
TRACE("setting: Inside Cone Angle = %d; Outside Cone Angle = %d; dwApply = %d\n",
|
||||
dwInsideConeAngle, dwOutsideConeAngle, dwApply);
|
||||
This->dsb->ds3db_ds3db.dwInsideConeAngle = dwInsideConeAngle;
|
||||
This->dsb->ds3db_ds3db.dwOutsideConeAngle = dwOutsideConeAngle;
|
||||
|
@ -558,7 +558,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_SetConeOrientation(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("setting: Cone Orientation vector = (%f,%f,%f); dwApply = %ld\n", x, y, z, dwApply);
|
||||
TRACE("setting: Cone Orientation vector = (%f,%f,%f); dwApply = %d\n", x, y, z, dwApply);
|
||||
This->dsb->ds3db_ds3db.vConeOrientation.x = x;
|
||||
This->dsb->ds3db_ds3db.vConeOrientation.y = y;
|
||||
This->dsb->ds3db_ds3db.vConeOrientation.z = z;
|
||||
|
@ -577,7 +577,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_SetConeOutsideVolume(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("setting: ConeOutsideVolume = %ld; dwApply = %ld\n", lConeOutsideVolume, dwApply);
|
||||
TRACE("setting: ConeOutsideVolume = %d; dwApply = %d\n", lConeOutsideVolume, dwApply);
|
||||
This->dsb->ds3db_ds3db.lConeOutsideVolume = lConeOutsideVolume;
|
||||
if (dwApply == DS3D_IMMEDIATE)
|
||||
{
|
||||
|
@ -594,7 +594,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_SetMaxDistance(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("setting: MaxDistance = %f; dwApply = %ld\n", fMaxDistance, dwApply);
|
||||
TRACE("setting: MaxDistance = %f; dwApply = %d\n", fMaxDistance, dwApply);
|
||||
This->dsb->ds3db_ds3db.flMaxDistance = fMaxDistance;
|
||||
if (dwApply == DS3D_IMMEDIATE)
|
||||
{
|
||||
|
@ -611,7 +611,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_SetMinDistance(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("setting: MinDistance = %f; dwApply = %ld\n", fMinDistance, dwApply);
|
||||
TRACE("setting: MinDistance = %f; dwApply = %d\n", fMinDistance, dwApply);
|
||||
This->dsb->ds3db_ds3db.flMinDistance = fMinDistance;
|
||||
if (dwApply == DS3D_IMMEDIATE)
|
||||
{
|
||||
|
@ -628,7 +628,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_SetMode(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("setting: Mode = %ld; dwApply = %ld\n", dwMode, dwApply);
|
||||
TRACE("setting: Mode = %d; dwApply = %d\n", dwMode, dwApply);
|
||||
This->dsb->ds3db_ds3db.dwMode = dwMode;
|
||||
if (dwApply == DS3D_IMMEDIATE)
|
||||
{
|
||||
|
@ -645,7 +645,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_SetPosition(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("setting: Position vector = (%f,%f,%f); dwApply = %ld\n", x, y, z, dwApply);
|
||||
TRACE("setting: Position vector = (%f,%f,%f); dwApply = %d\n", x, y, z, dwApply);
|
||||
This->dsb->ds3db_ds3db.vPosition.x = x;
|
||||
This->dsb->ds3db_ds3db.vPosition.y = y;
|
||||
This->dsb->ds3db_ds3db.vPosition.z = z;
|
||||
|
@ -664,7 +664,7 @@ static HRESULT WINAPI IDirectSound3DBufferImpl_SetVelocity(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DBufferImpl *This = (IDirectSound3DBufferImpl *)iface;
|
||||
TRACE("setting: Velocity vector = (%f,%f,%f); dwApply = %ld\n", x, y, z, dwApply);
|
||||
TRACE("setting: Velocity vector = (%f,%f,%f); dwApply = %d\n", x, y, z, dwApply);
|
||||
This->dsb->ds3db_ds3db.vVelocity.x = x;
|
||||
This->dsb->ds3db_ds3db.vVelocity.y = y;
|
||||
This->dsb->ds3db_ds3db.vVelocity.z = z;
|
||||
|
@ -802,7 +802,7 @@ static ULONG WINAPI IDirectSound3DListenerImpl_AddRef(LPDIRECTSOUND3DLISTENER if
|
|||
{
|
||||
IDirectSound3DListenerImpl *This = (IDirectSound3DListenerImpl *)iface;
|
||||
ULONG ref = InterlockedIncrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref - 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref - 1);
|
||||
return ref;
|
||||
}
|
||||
|
||||
|
@ -810,7 +810,7 @@ static ULONG WINAPI IDirectSound3DListenerImpl_Release(LPDIRECTSOUND3DLISTENER i
|
|||
{
|
||||
IDirectSound3DListenerImpl *This = (IDirectSound3DListenerImpl *)iface;
|
||||
ULONG ref = InterlockedDecrement(&(This->ref));
|
||||
TRACE("(%p) ref was %ld\n", This, ref + 1);
|
||||
TRACE("(%p) ref was %d\n", This, ref + 1);
|
||||
|
||||
if (!ref) {
|
||||
This->device->listener = 0;
|
||||
|
@ -834,7 +834,7 @@ static HRESULT WINAPI IDirectSound3DListenerImpl_GetAllParameter(
|
|||
}
|
||||
|
||||
if (lpDS3DL->dwSize < sizeof(*lpDS3DL)) {
|
||||
WARN("invalid parameter: lpDS3DL->dwSize = %ld\n",lpDS3DL->dwSize);
|
||||
WARN("invalid parameter: lpDS3DL->dwSize = %d\n",lpDS3DL->dwSize);
|
||||
return DSERR_INVALIDPARAM;
|
||||
}
|
||||
|
||||
|
@ -913,7 +913,7 @@ static HRESULT WINAPI IDirectSound3DListenerImpl_SetAllParameters(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DListenerImpl *This = (IDirectSound3DListenerImpl *)iface;
|
||||
TRACE("setting: all parameters; dwApply = %ld\n", dwApply);
|
||||
TRACE("setting: all parameters; dwApply = %d\n", dwApply);
|
||||
This->device->ds3dl = *lpcDS3DL;
|
||||
if (dwApply == DS3D_IMMEDIATE)
|
||||
{
|
||||
|
@ -930,7 +930,7 @@ static HRESULT WINAPI IDirectSound3DListenerImpl_SetDistanceFactor(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DListenerImpl *This = (IDirectSound3DListenerImpl *)iface;
|
||||
TRACE("setting: Distance Factor = %f; dwApply = %ld\n", fDistanceFactor, dwApply);
|
||||
TRACE("setting: Distance Factor = %f; dwApply = %d\n", fDistanceFactor, dwApply);
|
||||
This->device->ds3dl.flDistanceFactor = fDistanceFactor;
|
||||
if (dwApply == DS3D_IMMEDIATE)
|
||||
{
|
||||
|
@ -947,7 +947,7 @@ static HRESULT WINAPI IDirectSound3DListenerImpl_SetDopplerFactor(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DListenerImpl *This = (IDirectSound3DListenerImpl *)iface;
|
||||
TRACE("setting: Doppler Factor = %f; dwApply = %ld\n", fDopplerFactor, dwApply);
|
||||
TRACE("setting: Doppler Factor = %f; dwApply = %d\n", fDopplerFactor, dwApply);
|
||||
This->device->ds3dl.flDopplerFactor = fDopplerFactor;
|
||||
if (dwApply == DS3D_IMMEDIATE)
|
||||
{
|
||||
|
@ -965,7 +965,7 @@ static HRESULT WINAPI IDirectSound3DListenerImpl_SetOrientation(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DListenerImpl *This = (IDirectSound3DListenerImpl *)iface;
|
||||
TRACE("setting: Front vector = (%f,%f,%f); Top vector = (%f,%f,%f); dwApply = %ld\n", \
|
||||
TRACE("setting: Front vector = (%f,%f,%f); Top vector = (%f,%f,%f); dwApply = %d\n", \
|
||||
xFront, yFront, zFront, xTop, yTop, zTop, dwApply);
|
||||
This->device->ds3dl.vOrientFront.x = xFront;
|
||||
This->device->ds3dl.vOrientFront.y = yFront;
|
||||
|
@ -988,7 +988,7 @@ static HRESULT WINAPI IDirectSound3DListenerImpl_SetPosition(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DListenerImpl *This = (IDirectSound3DListenerImpl *)iface;
|
||||
TRACE("setting: Position vector = (%f,%f,%f); dwApply = %ld\n", x, y, z, dwApply);
|
||||
TRACE("setting: Position vector = (%f,%f,%f); dwApply = %d\n", x, y, z, dwApply);
|
||||
This->device->ds3dl.vPosition.x = x;
|
||||
This->device->ds3dl.vPosition.y = y;
|
||||
This->device->ds3dl.vPosition.z = z;
|
||||
|
@ -1007,7 +1007,7 @@ static HRESULT WINAPI IDirectSound3DListenerImpl_SetRolloffFactor(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DListenerImpl *This = (IDirectSound3DListenerImpl *)iface;
|
||||
TRACE("setting: Rolloff Factor = %f; dwApply = %ld\n", fRolloffFactor, dwApply);
|
||||
TRACE("setting: Rolloff Factor = %f; dwApply = %d\n", fRolloffFactor, dwApply);
|
||||
This->device->ds3dl.flRolloffFactor = fRolloffFactor;
|
||||
if (dwApply == DS3D_IMMEDIATE)
|
||||
{
|
||||
|
@ -1024,7 +1024,7 @@ static HRESULT WINAPI IDirectSound3DListenerImpl_SetVelocity(
|
|||
DWORD dwApply)
|
||||
{
|
||||
IDirectSound3DListenerImpl *This = (IDirectSound3DListenerImpl *)iface;
|
||||
TRACE("setting: Velocity vector = (%f,%f,%f); dwApply = %ld\n", x, y, z, dwApply);
|
||||
TRACE("setting: Velocity vector = (%f,%f,%f); dwApply = %d\n", x, y, z, dwApply);
|
||||
This->device->ds3dl.vVelocity.x = x;
|
||||
This->device->ds3dl.vVelocity.y = y;
|
||||
This->device->ds3dl.vVelocity.z = z;
|
||||
|
|
Loading…
Reference in a new issue