-
public class BoxaWrapper for Leptonica's native BOXA.
-
-
Constructor Summary
Constructors Constructor Description Boxa(long nativeBoxa)Creates a new Box wrapper for the specified native BOX.
-
Method Summary
Modifier and Type Method Description longgetNativeBoxa()Returns a pointer to the native Boxa object. intgetCount()RectgetRect(int index)Returns an android.graphics.Rect containing the coordinatesof this box. Array<int>getGeometry(int index)Returns an array containing the coordinates of this box. booleangetGeometry(int index, @Size(min = 4) Array<int> geometry)Fills an array containing the coordinates of this box. synchronized voidrecycle()Releases resources and frees any memory associated with this Box. -
-
Method Detail
-
getNativeBoxa
long getNativeBoxa()
Returns a pointer to the native Boxa object.
-
getCount
int getCount()
-
getRect
Rect getRect(int index)
Returns an android.graphics.Rect containing the coordinatesof this box.
- Parameters:
index- which box element to refer to
-
getGeometry
Array<int> getGeometry(int index)
Returns an array containing the coordinates of this box. See INDEX_*constants for indices.
- Parameters:
index- which box element to refer to
-
getGeometry
boolean getGeometry(int index, @Size(min = 4) Array<int> geometry)
Fills an array containing the coordinates of this box. See INDEX_*constants for indices.
- Parameters:
index- which box element to refer togeometry- A 4+ element integer array to fill with coordinates.
-
recycle
synchronized void recycle()
Releases resources and frees any memory associated with this Box.
-
-
-
-