Package com.digimarc.dms.readers
Class ImageFrame
java.lang.Object
com.digimarc.dms.readers.ImageFrame
The ImageFrame class is used to return camera image frames from the SDK to the application. These
frames are returned within
ReaderResult
objects and contain the image read occurred in.
These frames will require processing before they can be handled as normal bitmaps.
The BitmapUtils
class contains several methods for converting
the images to scaled ARGB thumbnail images.-
Constructor Summary
ConstructorsConstructorDescriptionImageFrame
(ImagePlane[] data, int width, int height, CaptureFormat format) Create an ImageFrame object. -
Method Summary
Modifier and TypeMethodDescriptionboolean
copy
(ImageFrame frame) Copy the contents of a frame into this object.Create a deep copy of this object.android.graphics.Point
int
int
int
-
Constructor Details
-
ImageFrame
Create an ImageFrame object. This will use the data passed in for its storage, so any changes to the buffer outside of this object will affect this object's contents.- Parameters:
data
- Image data.width
- Image width.height
- Image height.format
- Image format.
-
-
Method Details
-
copy
Copy the contents of a frame into this object.- Parameters:
frame
- Frame to copy.- Returns:
- True if the copy was successful. False if either a null frame was passed in or if this object's buffer wasn't large enough to hold the new frame.
-
createCopy
Create a deep copy of this object. New memory allocations will be made and original contents will be copied.- Returns:
- A new deep copy of this object.
-
getImageBuffer
-
getImageWidth
public int getImageWidth() -
getImageHeight
public int getImageHeight() -
getImageDimensions
@NonNull public android.graphics.Point getImageDimensions() -
getImageFormat
public int getImageFormat()
-