Package boofcv.struct.image
Class GrayI8<T extends GrayI8<T>>
java.lang.Object
boofcv.struct.image.ImageBase<T>
boofcv.struct.image.ImageGray<T>
boofcv.struct.image.GrayI<T>
boofcv.struct.image.GrayI8<T>
- All Implemented Interfaces:
Serializable
,Cloneable
Base class for images with 8-bit pixels.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class boofcv.struct.image.GrayI
GrayI.EachPixel
Nested classes/interfaces inherited from class boofcv.struct.image.ImageBase
ImageBase.PixelXY
-
Field Summary
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprotected Object
_getData()
Returns the data array the image is stored in.void
Sets the image's internal data array.void
Copies the column into the array.byte[]
getData()
Returns image type informationvoid
set
(int x, int y, int value) Sets the value of the specified pixel.void
setData
(byte[] data) void
unsafe_set
(int x, int y, int value) Set function which does not perform bounds checking.Methods inherited from class boofcv.struct.image.GrayI
forEachPixel, get, print, printBinary, printNotZero, unsafe_get
Methods inherited from class boofcv.struct.image.ImageGray
copyRow, create, createSameShape, initialize, reshape, reshape, setTo, subimage
Methods inherited from class boofcv.struct.image.ImageBase
clone, createNew, createSameShape, forEachXY, getImageType, getIndex, indexToPixelX, indexToPixelY, isInBounds, isSameShape, isSubimage, reshapeTo, subimage, totalPixels
-
Field Details
-
data
public byte[] data
-
-
Constructor Details
-
GrayI8
protected GrayI8(int width, int height) Creates a new gray scale (single band/color) image.- Parameters:
width
- number of columns in the image.height
- number of rows in the image.
-
GrayI8
protected GrayI8() -
GrayI8
protected GrayI8(byte[][] input) Create a copy from the two array. input[y][x]
-
-
Method Details
-
set
public void set(int x, int y, int value) Sets the value of the specified pixel. -
copyCol
Description copied from class:ImageBase
Copies the column into the array. -
unsafe_set
public void unsafe_set(int x, int y, int value) Description copied from class:GrayI
Set function which does not perform bounds checking.- Specified by:
unsafe_set
in classGrayI<T extends GrayI8<T>>
- Parameters:
x
- pixel coordinate.y
- pixel coordinate.value
- The pixel's new value.
-
_getData
Description copied from class:ImageGray
Returns the data array the image is stored in. -
_setData
Description copied from class:ImageGray
Sets the image's internal data array. -
getDataType
Description copied from class:ImageGray
Returns image type information- Overrides:
getDataType
in classGrayI<T extends GrayI8<T>>
- Returns:
- The type of image.
-
getData
public byte[] getData() -
setData
public void setData(byte[] data)
-