summaryrefslogtreecommitdiff
path: root/src/resources/openglimagehelper.cpp
diff options
context:
space:
mode:
authorAndrei Karas <akaras@inbox.ru>2014-07-02 23:05:08 +0300
committerAndrei Karas <akaras@inbox.ru>2014-07-02 23:05:08 +0300
commitd0432e0abdd05cf96741c0b5a88c8060243ff14a (patch)
tree2b6c24ddcaa5c87510e00032552aa8d3239e9211 /src/resources/openglimagehelper.cpp
parent3c9d042fff05fd3ead33b0ee301449345a1c06a9 (diff)
downloadplus-d0432e0abdd05cf96741c0b5a88c8060243ff14a.tar.gz
plus-d0432e0abdd05cf96741c0b5a88c8060243ff14a.tar.bz2
plus-d0432e0abdd05cf96741c0b5a88c8060243ff14a.tar.xz
plus-d0432e0abdd05cf96741c0b5a88c8060243ff14a.zip
Use GL_EXT_direct_state_access in copy to texture function.
Diffstat (limited to 'src/resources/openglimagehelper.cpp')
-rw-r--r--src/resources/openglimagehelper.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/resources/openglimagehelper.cpp b/src/resources/openglimagehelper.cpp
index 27d0e9956..18a220f01 100644
--- a/src/resources/openglimagehelper.cpp
+++ b/src/resources/openglimagehelper.cpp
@@ -388,8 +388,8 @@ void OpenGLImageHelper::copySurfaceToImage(Image *const image,
SDL_Surface *const oldSurface = surface;
surface = convertSurface(surface, surface->w, surface->h);
- bindTexture(image->mGLImage);
- glTexSubImage2D(mTextureType, 0,
+ mglTextureSubImage2D(image->mGLImage,
+ mTextureType, 0,
x, y,
surface->w, surface->h,
GL_RGBA, GL_UNSIGNED_BYTE, surface->pixels);