diff --git a/stepmania/src/RageDisplay.h b/stepmania/src/RageDisplay.h index 386895d953..ea7af8ed9e 100644 --- a/stepmania/src/RageDisplay.h +++ b/stepmania/src/RageDisplay.h @@ -178,11 +178,11 @@ public: bool bGenerateMipMaps ) = 0; virtual void UpdateTexture( - unsigned uTexHandle, + unsigned iTexHandle, RageSurface* img, int xoffset, int yoffset, int width, int height ) = 0; - virtual void DeleteTexture( unsigned uTexHandle ) = 0; + virtual void DeleteTexture( unsigned iTexHandle ) = 0; virtual void ClearAllTextures() = 0; virtual int GetNumTextureUnits() = 0; virtual void SetTexture( TextureUnit tu, unsigned iTexture ) = 0; diff --git a/stepmania/src/RageDisplay_D3D.cpp b/stepmania/src/RageDisplay_D3D.cpp index 1c823253cf..10934835bb 100644 --- a/stepmania/src/RageDisplay_D3D.cpp +++ b/stepmania/src/RageDisplay_D3D.cpp @@ -1342,16 +1342,16 @@ void RageDisplay_D3D::SetCullMode( CullMode mode ) } } -void RageDisplay_D3D::DeleteTexture( unsigned uTexHandle ) +void RageDisplay_D3D::DeleteTexture( unsigned iTexHandle ) { - IDirect3DTexture8* pTex = (IDirect3DTexture8*) uTexHandle; + IDirect3DTexture8* pTex = (IDirect3DTexture8*) iTexHandle; pTex->Release(); // Delete palette (if any) - if( g_TexResourceToPaletteIndex.find(uTexHandle) != g_TexResourceToPaletteIndex.end() ) - g_TexResourceToPaletteIndex.erase( g_TexResourceToPaletteIndex.find(uTexHandle) ); - if( g_TexResourceToTexturePalette.find(uTexHandle) != g_TexResourceToTexturePalette.end() ) - g_TexResourceToTexturePalette.erase( g_TexResourceToTexturePalette.find(uTexHandle) ); + if( g_TexResourceToPaletteIndex.find(iTexHandle) != g_TexResourceToPaletteIndex.end() ) + g_TexResourceToPaletteIndex.erase( g_TexResourceToPaletteIndex.find(iTexHandle) ); + if( g_TexResourceToTexturePalette.find(iTexHandle) != g_TexResourceToTexturePalette.end() ) + g_TexResourceToTexturePalette.erase( g_TexResourceToTexturePalette.find(iTexHandle) ); } diff --git a/stepmania/src/RageDisplay_D3D.h b/stepmania/src/RageDisplay_D3D.h index 18801d3c7e..52e8fcac89 100644 --- a/stepmania/src/RageDisplay_D3D.h +++ b/stepmania/src/RageDisplay_D3D.h @@ -28,11 +28,11 @@ public: RageSurface* img, bool bGenerateMipMaps ); void UpdateTexture( - unsigned uTexHandle, + unsigned iTexHandle, RageSurface* img, int xoffset, int yoffset, int width, int height ); - void DeleteTexture( unsigned uTexHandle ); + void DeleteTexture( unsigned iTexHandle ); void ClearAllTextures(); int GetNumTextureUnits(); void SetTexture( TextureUnit tu, unsigned iTexture ); diff --git a/stepmania/src/RageDisplay_Null.h b/stepmania/src/RageDisplay_Null.h index 13404e3ecc..4d6cdbf513 100644 --- a/stepmania/src/RageDisplay_Null.h +++ b/stepmania/src/RageDisplay_Null.h @@ -25,11 +25,11 @@ public: RageSurface* img, bool bGenerateMipMaps ) { return 1; } void UpdateTexture( - unsigned uTexHandle, + unsigned iTexHandle, RageSurface* img, int xoffset, int yoffset, int width, int height ) { } - void DeleteTexture( unsigned uTexHandle ) { } + void DeleteTexture( unsigned iTexHandle ) { } void ClearAllTextures() { } int GetNumTextureUnits() { return 1; } void SetTexture( TextureUnit tu, unsigned iTexture ) { } diff --git a/stepmania/src/RageDisplay_OGL.cpp b/stepmania/src/RageDisplay_OGL.cpp index 00dcacd66b..7f89229bec 100644 --- a/stepmania/src/RageDisplay_OGL.cpp +++ b/stepmania/src/RageDisplay_OGL.cpp @@ -1715,11 +1715,11 @@ unsigned RageDisplay_OGL::CreateTexture( } // allocate OpenGL texture resource - unsigned int uTexHandle; - glGenTextures( 1, reinterpret_cast(&uTexHandle) ); - ASSERT( uTexHandle ); + unsigned int iTexHandle; + glGenTextures( 1, reinterpret_cast(&iTexHandle) ); + ASSERT( iTexHandle ); - glBindTexture( GL_TEXTURE_2D, uTexHandle ); + glBindTexture( GL_TEXTURE_2D, iTexHandle ); glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_LINEAR ); GLint iMinFilter; if( bGenerateMipMaps ) @@ -1823,15 +1823,15 @@ unsigned RageDisplay_OGL::CreateTexture( if( bFreeImg ) delete pImg; - return uTexHandle; + return iTexHandle; } void RageDisplay_OGL::UpdateTexture( - unsigned uTexHandle, + unsigned iTexHandle, RageSurface* pImg, int iXOffset, int iYOffset, int iWidth, int iHeight ) { - glBindTexture( GL_TEXTURE_2D, uTexHandle ); + glBindTexture( GL_TEXTURE_2D, iTexHandle ); bool bFreeImg; PixelFormat SurfacePixFmt = GetImgPixelFormat( pImg, bFreeImg, iWidth, iHeight, false ); diff --git a/stepmania/src/RageDisplay_OGL.h b/stepmania/src/RageDisplay_OGL.h index ead86c61cb..1860ca83c9 100644 --- a/stepmania/src/RageDisplay_OGL.h +++ b/stepmania/src/RageDisplay_OGL.h @@ -35,11 +35,11 @@ public: RageSurface* img, bool bGenerateMipMaps ); void UpdateTexture( - unsigned uTexHandle, + unsigned iTexHandle, RageSurface* img, int xoffset, int yoffset, int width, int height ); - void DeleteTexture( unsigned uTexHandle ); + void DeleteTexture( unsigned iTexHandle ); void ClearAllTextures(); int GetNumTextureUnits(); void SetTexture( TextureUnit tu, unsigned iTexture );