Package adams.data.opencv
Class OpenCVImageContainer
- java.lang.Object
-
- adams.data.container.AbstractSimpleContainer<T>
-
- adams.data.image.AbstractImageContainer<org.bytedeco.opencv.opencv_core.Mat>
-
- adams.data.opencv.OpenCVImageContainer
-
- All Implemented Interfaces:
CloneHandler<AbstractSimpleContainer<org.bytedeco.opencv.opencv_core.Mat>>
,UniqueIDHandler
,BufferedImageSupporter
,MutableNotesHandler
,NotesHandler
,MutableReportHandler<Report>
,ReportHandler<Report>
,Serializable
public class OpenCVImageContainer extends AbstractImageContainer<org.bytedeco.opencv.opencv_core.Mat>
Encapsulates an OpenCV image.- Author:
- fracpete (fracpete at waikato dot ac dot nz)
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class adams.data.image.AbstractImageContainer
FIELD_FILENAME, FIELD_NAME, FIELD_PATH
-
Fields inherited from class adams.data.container.AbstractSimpleContainer
m_Content, m_Notes, m_Report, m_UUID
-
-
Constructor Summary
Constructors Constructor Description OpenCVImageContainer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected org.bytedeco.opencv.opencv_core.Mat
cloneContent()
Returns a clone of the content.int
getHeight()
Returns the height of the image.int
getWidth()
Returns the width of the image.BufferedImage
toBufferedImage()
Turns the image into a buffered image.-
Methods inherited from class adams.data.image.AbstractImageContainer
getImage, setImage
-
Methods inherited from class adams.data.container.AbstractSimpleContainer
getClone, getContent, getHeader, getNotes, getReport, getUniqueID, hasReport, initialize, setContent, setNotes, setReport, toString
-
-
-
-
Method Detail
-
getWidth
public int getWidth()
Returns the width of the image.- Specified by:
getWidth
in classAbstractImageContainer<org.bytedeco.opencv.opencv_core.Mat>
- Returns:
- the width
-
getHeight
public int getHeight()
Returns the height of the image.- Specified by:
getHeight
in classAbstractImageContainer<org.bytedeco.opencv.opencv_core.Mat>
- Returns:
- the height
-
toBufferedImage
public BufferedImage toBufferedImage()
Turns the image into a buffered image.- Specified by:
toBufferedImage
in interfaceBufferedImageSupporter
- Specified by:
toBufferedImage
in classAbstractImageContainer<org.bytedeco.opencv.opencv_core.Mat>
- Returns:
- the buffered image
-
cloneContent
protected org.bytedeco.opencv.opencv_core.Mat cloneContent()
Returns a clone of the content.- Specified by:
cloneContent
in classAbstractSimpleContainer<org.bytedeco.opencv.opencv_core.Mat>
- Returns:
- the clone
-
-