diff options
author | Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> | 2014-11-13 17:07:14 +0100 |
---|---|---|
committer | Sean Harmer <sean.harmer@kdab.com> | 2014-11-14 20:31:48 +0100 |
commit | ef693dcb41fa2307476d082bd0d8691a546f8a7b (patch) | |
tree | a6e4915fed34c0f097649c376a8c11605c865faf /src/gui/opengl/qopengltexture.cpp | |
parent | c0b4e9076b7d62b1fbb1ea8c5983cf3814e0e2dd (diff) |
QOpenGLTexture: Fix a comment
The right function to call is allocateStorage(), not allocate().
Change-Id: Ia26817dbec710d49e511cab2ae3ca5c1fda20722
Reviewed-by: Sean Harmer <sean.harmer@kdab.com>
Diffstat (limited to 'src/gui/opengl/qopengltexture.cpp')
-rw-r--r-- | src/gui/opengl/qopengltexture.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/gui/opengl/qopengltexture.cpp b/src/gui/opengl/qopengltexture.cpp index 285e8cc8a7..b2db40b8ef 100644 --- a/src/gui/opengl/qopengltexture.cpp +++ b/src/gui/opengl/qopengltexture.cpp @@ -2751,7 +2751,7 @@ void QOpenGLTexture::setData(int mipLevel, int layer, CubeMapFace cubeFace, Q_ASSERT(d->textureId); if (!isStorageAllocated()) { qWarning("Cannot set data on a texture that does not have storage allocated.\n" - "To do so call allocate() before this function"); + "To do so call allocateStorage() before this function"); return; } d->setData(mipLevel, layer, cubeFace, sourceFormat, sourceType, data, options); @@ -2809,7 +2809,7 @@ void QOpenGLTexture::setData(int mipLevel, int layer, CubeMapFace cubeFace, Q_ASSERT(d->textureId); if (!isStorageAllocated()) { qWarning("Cannot set data on a texture that does not have storage allocated.\n" - "To do so call allocate() before this function"); + "To do so call allocateStorage() before this function"); return; } d->setData(mipLevel, layer, cubeFace, sourceFormat, sourceType, data, options); @@ -2901,7 +2901,7 @@ void QOpenGLTexture::setCompressedData(int mipLevel, int layer, CubeMapFace cube Q_ASSERT(d->textureId); if (!isStorageAllocated()) { qWarning("Cannot set data on a texture that does not have storage allocated.\n" - "To do so call allocate() before this function"); + "To do so call allocateStorage() before this function"); return; } d->setCompressedData(mipLevel, layer, cubeFace, dataSize, data, options); @@ -2952,7 +2952,7 @@ void QOpenGLTexture::setCompressedData(int mipLevel, int layer, CubeMapFace cube Q_ASSERT(d->textureId); if (!isStorageAllocated()) { qWarning("Cannot set data on a texture that does not have storage allocated.\n" - "To do so call allocate() before this function"); + "To do so call allocateStorage() before this function"); return; } d->setCompressedData(mipLevel, layer, cubeFace, dataSize, data, options); |