From 8d7a01963e1cd1e0a0af7e07794d6efc2c1b24ab Mon Sep 17 00:00:00 2001 From: Ivan Gyurdiev Date: Tue, 31 Oct 2006 03:20:12 -0500 Subject: [PATCH] wined3d: Use D3DCUBEMAP_FACES consistently in the WINED3D namespace. --- dlls/wined3d/cubetexture.c | 10 +++++----- dlls/wined3d/device.c | 2 +- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/dlls/wined3d/cubetexture.c b/dlls/wined3d/cubetexture.c index 62509756ee0..c16740af37f 100644 --- a/dlls/wined3d/cubetexture.c +++ b/dlls/wined3d/cubetexture.c @@ -145,7 +145,7 @@ static void WINAPI IWineD3DCubeTextureImpl_PreLoad(IWineD3DCubeTexture *iface) { /* If were dirty then reload the surfaces */ if (This->baseTexture.dirty) { for (i = 0; i < This->baseTexture.levels; i++) { - for (j = D3DCUBEMAP_FACE_POSITIVE_X; j <= D3DCUBEMAP_FACE_NEGATIVE_Z ; j++) { + for (j = WINED3DCUBEMAP_FACE_POSITIVE_X; j <= WINED3DCUBEMAP_FACE_NEGATIVE_Z ; j++) { if(setGlTextureDesc) IWineD3DSurface_SetGlTextureDesc(This->surfaces[j][i], This->baseTexture.textureName, cube_targets[j]); IWineD3DSurface_LoadTexture(This->surfaces[j][i]); @@ -280,7 +280,7 @@ static HRESULT WINAPI IWineD3DCubeTextureImpl_GetCubeMapSurface(IWineD3DCubeText IWineD3DCubeTextureImpl *This = (IWineD3DCubeTextureImpl *)iface; HRESULT hr = WINED3DERR_INVALIDCALL; - if (Level < This->baseTexture.levels && FaceType >= D3DCUBEMAP_FACE_POSITIVE_X && FaceType <= D3DCUBEMAP_FACE_NEGATIVE_Z) { + if (Level < This->baseTexture.levels && FaceType >= WINED3DCUBEMAP_FACE_POSITIVE_X && FaceType <= WINED3DCUBEMAP_FACE_NEGATIVE_Z) { *ppCubeMapSurface = This->surfaces[FaceType][Level]; IWineD3DSurface_AddRef(*ppCubeMapSurface); @@ -299,7 +299,7 @@ static HRESULT WINAPI IWineD3DCubeTextureImpl_LockRect(IWineD3DCubeTexture *ifac HRESULT hr = WINED3DERR_INVALIDCALL; IWineD3DCubeTextureImpl *This = (IWineD3DCubeTextureImpl *)iface; - if (Level < This->baseTexture.levels && FaceType >= D3DCUBEMAP_FACE_POSITIVE_X && FaceType <= D3DCUBEMAP_FACE_NEGATIVE_Z) { + if (Level < This->baseTexture.levels && FaceType >= WINED3DCUBEMAP_FACE_POSITIVE_X && FaceType <= WINED3DCUBEMAP_FACE_NEGATIVE_Z) { hr = IWineD3DSurface_LockRect(This->surfaces[FaceType][Level], pLockedRect, pRect, Flags); } @@ -316,7 +316,7 @@ static HRESULT WINAPI IWineD3DCubeTextureImpl_UnlockRect(IWineD3DCubeTexture *if HRESULT hr = WINED3DERR_INVALIDCALL; IWineD3DCubeTextureImpl *This = (IWineD3DCubeTextureImpl *)iface; - if (Level < This->baseTexture.levels && FaceType >= D3DCUBEMAP_FACE_POSITIVE_X && FaceType <= D3DCUBEMAP_FACE_NEGATIVE_Z) { + if (Level < This->baseTexture.levels && FaceType >= WINED3DCUBEMAP_FACE_POSITIVE_X && FaceType <= WINED3DCUBEMAP_FACE_NEGATIVE_Z) { hr = IWineD3DSurface_UnlockRect(This->surfaces[FaceType][Level]); } @@ -333,7 +333,7 @@ static HRESULT WINAPI IWineD3DCubeTextureImpl_AddDirtyRect(IWineD3DCubeTexture IWineD3DCubeTextureImpl *This = (IWineD3DCubeTextureImpl *)iface; This->baseTexture.dirty = TRUE; TRACE("(%p) : dirtyfication of faceType(%d) Level (0)\n", This, FaceType); - if (FaceType >= D3DCUBEMAP_FACE_POSITIVE_X && FaceType <= D3DCUBEMAP_FACE_NEGATIVE_Z) { + if (FaceType >= WINED3DCUBEMAP_FACE_POSITIVE_X && FaceType <= WINED3DCUBEMAP_FACE_NEGATIVE_Z) { hr = IWineD3DSurface_AddDirtyRect(This->surfaces[FaceType][0], pDirtyRect); } else { WARN("(%p) overflow FaceType(%d)\n", This, FaceType); diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c index 31644b25ec0..0ee1045188a 100644 --- a/dlls/wined3d/device.c +++ b/dlls/wined3d/device.c @@ -6343,7 +6343,7 @@ static HRESULT WINAPI IWineD3DDeviceImpl_UpdateTexture (IWineD3DDevice *iface, I for (i = 0 ; i < levels ; ++i) { /* Update each cube face */ - for (faceType = D3DCUBEMAP_FACE_POSITIVE_X; faceType <= D3DCUBEMAP_FACE_NEGATIVE_Z; ++faceType){ + for (faceType = WINED3DCUBEMAP_FACE_POSITIVE_X; faceType <= WINED3DCUBEMAP_FACE_NEGATIVE_Z; ++faceType){ hr = IWineD3DCubeTexture_GetCubeMapSurface((IWineD3DCubeTexture *)pSourceTexture, faceType, i, &srcSurface); if (WINED3D_OK != hr) { FIXME("(%p) : Failed to get src cube surface facetype %d, level %d\n", This, faceType, i);