opengl: Fix a typo in GLTexture::upload()
For glTexStorage2D(), we need to check whether texture storage is supported, not that ARGB32 textures are supported. Those are two distinct things.
This commit is contained in:
parent
3e3bbd3034
commit
8ca94eed44
1 changed files with 1 additions and 1 deletions
|
@ -571,7 +571,7 @@ std::unique_ptr<GLTexture> GLTexture::upload(const QImage &image)
|
|||
type = GL_UNSIGNED_INT_8_8_8_8_REV;
|
||||
}
|
||||
|
||||
if (context->supportsARGB32Textures()) {
|
||||
if (context->supportsTextureStorage()) {
|
||||
glTexStorage2D(GL_TEXTURE_2D, 1, internalFormat, im.width(), im.height());
|
||||
glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, im.width(), im.height(),
|
||||
format, type, im.constBits());
|
||||
|
|
Loading…
Reference in a new issue