Rect and RectF in Android SDK

What is the difference between Rect and RectF in the Android SDK?

+43
android android-canvas rect
Feb 06 2018-11-11T00:
source share
2 answers

Using Rect , you define its edges using integers and using RectF , they are defined as float.

Looking at them more carefully, I found several differences. I will only list that one implementation is larger than the other.

Rect

Rectf

Therefore, apparently, there are some differences.

+40
Feb 06 2018-11-11T00:
source share

Rect final, RectF can be expanded

+10
Apr 20 '13 at 16:29
source share



All Articles