Fix glPixelStore in GLTexture::update
Resetting glPixelStore is bound to the variable useUnpack, but setting was only bound to a subset of the checks going into useUnpack variable. This could cause an assert if one updated with a QImage not in format ARGB32_Premultiplied. REVIEW: 122521
This commit is contained in:
parent
7b5cf8bcdc
commit
d344b6cc3d
1 changed files with 1 additions and 1 deletions
|
@ -338,7 +338,7 @@ void GLTexture::update(const QImage &image, const QPoint &offset, const QRect &s
|
|||
QImage tmpImage;
|
||||
|
||||
if (!src.isNull()) {
|
||||
if (d->s_supportsUnpack) {
|
||||
if (useUnpack) {
|
||||
glPixelStorei(GL_UNPACK_ROW_LENGTH, image.width());
|
||||
glPixelStorei(GL_UNPACK_SKIP_PIXELS, src.x());
|
||||
glPixelStorei(GL_UNPACK_SKIP_ROWS, src.y());
|
||||
|
|
Loading…
Reference in a new issue