forked from rosebudai/OpenRCT2-Web
Fix crash after alt-tab (#16070)
This commit is contained in:
1 parent
e9213e3ecf
commit
fd4e6bd031
1 file changed
+4
@@ -527,6 +527,10 @@ void lightfx_render_lights_to_frontbuffer()
|
||||
continue;
|
||||
}
|
||||
|
||||
// Clamp the reads to be no larger than the buffer size
|
||||
bufReadHeight = std::min<uint32_t>(_pixelInfo.height, bufReadHeight);
|
||||
bufReadWidth = std::min<uint32_t>(_pixelInfo.width, bufReadWidth);
|
||||
|
||||
bufWriteX = inRectCentreX - bufReadWidth / 2;
|
||||
bufWriteY = inRectCentreY - bufReadHeight / 2;
|
||||
|
||||
|
||||
Reference in new issue
Block a user