diff --git a/src/modules/graphics/opengl/Graphics.cpp b/src/modules/graphics/opengl/Graphics.cpp index 825ed2f33..77226a42a 100644 --- a/src/modules/graphics/opengl/Graphics.cpp +++ b/src/modules/graphics/opengl/Graphics.cpp @@ -316,7 +316,7 @@ void Graphics::discardStencil() glDisable(GL_STENCIL_TEST); } -int Graphics::getMaxImageSize() const +int Graphics::getMaxTextureSize() const { return gl.getMaxTextureSize(); } diff --git a/src/modules/graphics/opengl/Graphics.h b/src/modules/graphics/opengl/Graphics.h index f153c694f..36e3c10bb 100644 --- a/src/modules/graphics/opengl/Graphics.h +++ b/src/modules/graphics/opengl/Graphics.h @@ -187,10 +187,9 @@ public: void discardStencil(); /** - * Gets the maximum supported width or height of Images and Canvases on this - * system. + * Gets the maximum supported width or height of Textures on this system. **/ - int getMaxImageSize() const; + int getMaxTextureSize() const; /** * Creates an Image object with padding and/or optimization. diff --git a/src/modules/graphics/opengl/wrap_Graphics.cpp b/src/modules/graphics/opengl/wrap_Graphics.cpp index ac64ea2a7..a7f27e7fa 100644 --- a/src/modules/graphics/opengl/wrap_Graphics.cpp +++ b/src/modules/graphics/opengl/wrap_Graphics.cpp @@ -135,9 +135,9 @@ int w_setInvertedStencil(lua_State *L) return setStencil(L, true); } -int w_getMaxImageSize(lua_State *L) +int w_getMaxTextureSize(lua_State *L) { - lua_pushinteger(L, instance->getMaxImageSize()); + lua_pushinteger(L, instance->getMaxTextureSize()); return 1; } @@ -1339,7 +1339,7 @@ static const luaL_Reg functions[] = { "getPointSize", w_getPointSize }, { "getPointStyle", w_getPointStyle }, { "getMaxPointSize", w_getMaxPointSize }, - { "getMaxImageSize", w_getMaxImageSize }, + { "getMaxTextureSize", w_getMaxTextureSize }, { "newScreenshot", w_newScreenshot }, { "setCanvas", w_setCanvas }, { "getCanvas", w_getCanvas }, @@ -1382,6 +1382,9 @@ static const luaL_Reg functions[] = { "shear", w_shear }, { "origin", w_origin }, + // Deprecated since 0.9.1. + { "getMaxImageSize", w_getMaxTextureSize }, + { 0, 0 } }; diff --git a/src/modules/graphics/opengl/wrap_Graphics.h b/src/modules/graphics/opengl/wrap_Graphics.h index 8a23424c3..4514bb68b 100644 --- a/src/modules/graphics/opengl/wrap_Graphics.h +++ b/src/modules/graphics/opengl/wrap_Graphics.h @@ -50,7 +50,7 @@ int w_setScissor(lua_State *L); int w_getScissor(lua_State *L); int w_setStencil(lua_State *L); int w_setInvertedStencil(lua_State *L); -int w_getMaxImageSize(lua_State *L); +int w_getMaxTextureSize(lua_State *L); int w_newImage(lua_State *L); int w_newQuad(lua_State *L); int w_newFont(lua_State *L);