fix tiler to handle large float rects

The issue is around needing to go from a float rect to a clipped (intersected
with the clip bounds) irect.

The old code promoted the clip bounds to rect,
intersected with the rect, and then rounded to ints. This is problematic
since convert float --> int can produce float values that are larger than
their int counter-parts. (e.g. int:67108863 becomes float:67108864).
This error goes on to confuse subsequent logic.

The fix is to round the rect to int first (knowing that very large floats
will saturate to maxint), and then intersect.

Bug: 927075
Change-Id: If6c7d72ff15184700b87532e1922e576d1348ee8
Reviewed-on: https://skia-review.googlesource.com/c/188307
Commit-Queue: Mike Reed <reed@google.com>
Reviewed-by: Florin Malita <fmalita@chromium.org>
2 files changed