Skip to content
Commit 5495c726 authored by Chet Haase's avatar Chet Haase
Browse files

Dirty rect must expand, not contract.

Different devices have different precision, leading to different pixels
being touched during rendering operations. We need to ensure that the
dirty rect we draw with (and which gets erased on the following frame)
encompasses all possible pixels instead of some ideal rounded rectangle.

The bug from this code led to dropped-pixels artifacts on some devices,
where we'd scale a view, drawing it into some pixels, then invalidate
that same area on the next frame, but the invalidation rectangle didn't
cover the same pixels as the device drew into.

The fix is to floor() the left/top pixels and ceil() the right/bottom
pixels of the transformed invalidation rectangle.

Issue #8971348 dropped pixel artifacts during some scaling operations

Change-Id: Iedb1afd5621dff43bf7a3919bdbd8d2251647fd2
parent 60347e98
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment