LocalizedTextLinesUnit
The LocalizedTextLinesUnit class represents a unit that contains localized text lines. It inherits from the IntermediateResultUnit class.
Definition
Namespace: com.dynamsoft.dlr.intermediate_results
Assembly: DynamsoftCaptureVisionBundle.aar
class LocalizedTextLinesUnit extends IntermediateResultUnit
Inheritance: IntermediateResultUnit -> LocalizedTextLinesUnit
Methods
| Method | Description |
|---|---|
getLocalizedTextLine |
Returns an array of LocalizedTextLineElement objects, each representing a localized text line. |
getCount |
Returns the number of text lines that are localized from the image. |
getLocalizedTextLine |
Returns the localized text line at the specified index in a LocalizedTextLineElement object. |
removeAllLocalizedTextLines |
Removes all the localized text lines from the unit. |
removeLocalizedTextLine |
Removes a localized text line from the unit. |
addLocalizedTextLine |
Adds a LocalizedTextLineElement to the unit. |
setLocalizedTextLine |
Sets the LocalizedTextLineElement at the specified index. |
getAuxiliaryRegionElements |
Returns an array of AuxiliaryRegionElement objects. |
getAuxiliaryRegionElementsCount |
Returns the number of auxiliary region elements in this unit. |
getAuxiliaryRegionElement |
Returns the auxiliary region element at the specified index. |
setAuxiliaryRegionElement |
Sets or replaces the auxiliary region element at the specified index. |
addAuxiliaryRegionElement |
Adds a new auxiliary region element to this unit. |
removeAuxiliaryRegionElement |
Removes the auxiliary region element at the specified index. |
removeAllAuxiliaryRegionElements |
Removes all the auxiliary region elements from this unit. |
getLocalizedTextLines
Returns an array of LocalizedTextLineElement objects, each representing a localized text line.
LocalizedTextLineElement[] getLocalizedTextLines();
Return value
Returns an array of LocalizedTextLineElement, which is the basic unit of the localized text line result.
getCount
Returns the number of LocalizedTextLineElement objects from the image.
int getCount();
Return value
Returns the number of text lines that are localized from the image.
getLocalizedTextLine
Returns the localized text line at the specified index in a LocalizedTextLineElement object.
LocalizedTextLineElement getLocalizedTextLine(int index);
Parameters
index: The index of the LocalizedTextLineElement to be retrieved.
removeAllLocalizedTextLines
Removes all the LocalizedTextLineElement objects from the unit.
void removeAllLocalizedTextLines();
removeLocalizedTextLine
Removes a LocalizedTextLineElement from the unit.
int removeLocalizedTextLine(int index);
Parameters
index: The index of the LocalizedTextLineElement to be removed.
Return value
Returns the ErrorCode if failed. Otherwise, returns 0.
addLocalizedTextLine
Adds a LocalizedTextLineElement to the unit.
int addLocalizedTextLine(LocalizedTextLineElement element, Matrix matrixToOriginalImage);
Parameters
element: A LocalizedTextLineElement object as the localized text line to be added to the unit.
matrixToOriginalImage: The matrix to convert the coordinates of the localized text line to the original image.
Return value
Returns the ErrorCode if failed. Otherwise, returns 0.
setLocalizedTextLine
Sets the LocalizedTextLineElement at the specified index.
int setLocalizedTextLine(int index, LocalizedTextLineElement element, Matrix matrixToOriginalImage);
Parameters
index: The index of the localized text line to be set.
element: A LocalizedTextLineElement object as the localized text line to be set.
matrixToOriginalImage: The matrix to convert the coordinates of the localized text line to the original image.
Return value
Returns the ErrorCode if failed. Otherwise, returns 0.
getAuxiliaryRegionElements
Returns an array of AuxiliaryRegionElement objects, each representing an auxiliary region.
AuxiliaryRegionElement[] getAuxiliaryRegionElements();
Return value
Returns an array of AuxiliaryRegionElement objects.
getAuxiliaryRegionElementsCount
Returns the number of auxiliary region elements in this unit.
int getAuxiliaryRegionElementsCount();
Return value
Returns the number of auxiliary region elements.
getAuxiliaryRegionElement
Returns the auxiliary region element at the specified index.
AuxiliaryRegionElement getAuxiliaryRegionElement(int index);
Parameters
index: The zero-based index of the auxiliary region element to retrieve.
Return value
Returns the auxiliary region element at the specified index, or null if the index is out of range.
setAuxiliaryRegionElement
Sets or replaces the auxiliary region element at the specified index.
int setAuxiliaryRegionElement(int index, AuxiliaryRegionElement element, Matrix matrixToOriginalImage);
Parameters
index: The zero-based index where the element should be set.
element: The auxiliary region element to set.
matrixToOriginalImage: The transformation matrix from the current image to the original image.
Return value
Returns the ErrorCode if failed. Otherwise, returns 0.
addAuxiliaryRegionElement
Adds a new auxiliary region element to this unit.
int addAuxiliaryRegionElement(AuxiliaryRegionElement element, Matrix matrixToOriginalImage);
Parameters
element: The auxiliary region element to add.
matrixToOriginalImage: The transformation matrix from the current image to the original image.
Return value
Returns the ErrorCode if failed. Otherwise, returns 0.
removeAuxiliaryRegionElement
Removes the auxiliary region element at the specified index.
int removeAuxiliaryRegionElement(int index);
Parameters
index: The zero-based index of the auxiliary region element to remove.
Return value
Returns the ErrorCode if failed. Otherwise, returns 0.
removeAllAuxiliaryRegionElements
Removes all the auxiliary region elements from this unit.
void removeAllAuxiliaryRegionElements();