GRAPHICS: Fix crash when resizing the window to low width

This commit is contained in:
Orgad Shaneh 2021-06-20 11:47:36 +03:00 committed by Filippos Karapetis
parent 0cc497429d
commit 968e52ee98

View File

@ -279,13 +279,13 @@ protected:
* @param alpha Alpha intensity of the pixel (0-255)
*/
inline void blendFill(PixelType *first, PixelType *last, PixelType color, uint8 alpha) {
while (first != last)
while (first < last)
blendPixelPtr(first++, color, alpha);
}
inline void blendFillClip(PixelType *first, PixelType *last, PixelType color, uint8 alpha, int realX, int realY) {
if (_clippingArea.top <= realY && realY < _clippingArea.bottom) {
while (first != last) {
while (first < last) {
if (_clippingArea.left <= realX && realX < _clippingArea.right)
blendPixelPtr(first++, color, alpha);
else