public class Rectangle
extends java.lang.Object
implements android.os.Parcelable
Modifier and Type | Field and Description |
---|---|
static android.os.Parcelable.Creator |
CREATOR |
Constructor and Description |
---|
Rectangle(float x,
float y,
float width,
float height)
Rectangle constructor.
|
Modifier and Type | Method and Description |
---|---|
int |
describeContents() |
static Rectangle |
getDefaultROI()
Returns the default rectangle that defines the whole image or view
|
float |
getHeight() |
float |
getWidth() |
float |
getX() |
float |
getY() |
boolean |
isRelative()
Return true if rectangle is given in relative coordinates.
|
void |
log() |
void |
normalizeToUnitRectangle() |
android.graphics.RectF |
toRectF() |
java.lang.String |
toString() |
void |
writeToParcel(android.os.Parcel dest,
int flags) |
public Rectangle(float x, float y, float width, float height)
x
- top left x coordinatey
- top left y coordinatewidth
- rectangle widthheight
- rectangle heightpublic boolean isRelative()
@NonNull public static Rectangle getDefaultROI()
@NonNull public java.lang.String toString()
toString
in class java.lang.Object
public void log()
public void normalizeToUnitRectangle()
@NonNull public android.graphics.RectF toRectF()
public float getX()
public float getY()
public float getWidth()
public float getHeight()
public int describeContents()
describeContents
in interface android.os.Parcelable
public void writeToParcel(@NonNull android.os.Parcel dest, int flags)
writeToParcel
in interface android.os.Parcelable