Fix rendering error in some animated gifs
The code for handling of the rarely used "restore to previous" frame disposal option would mistakenly clear the entire existing frame. It looks like this was a copy/paste mistake in the code; the intention obviously was to clear the newly created backingstore instead. This fixes the rendering of http://media1.giphy.com/media/9Jevgp0CgvAnm/giphy.gif Task-number: QTBUG-55141 Change-Id: I4d344b7733edd62346656154e215c21727f9b6bb Reviewed-by: Lars Knoll <lars.knoll@qt.io>bb10
parent
d9e66f63a9
commit
b674d0d5cc
|
|
@ -409,7 +409,7 @@ int QGIFFormat::decode(QImage *image, const uchar *buffer, int length,
|
|||
backingstore = QImage(qMax(backingstore.width(), w),
|
||||
qMax(backingstore.height(), h),
|
||||
QImage::Format_RGB32);
|
||||
memset(bits, 0, image->byteCount());
|
||||
memset(backingstore.bits(), 0, backingstore.byteCount());
|
||||
}
|
||||
const int dest_bpl = backingstore.bytesPerLine();
|
||||
unsigned char *dest_data = backingstore.bits();
|
||||
|
|
|
|||
Loading…
Reference in New Issue