toRawFloatArray
fun toRawFloatArray(image: BufferedImage, colorMode: ColorMode? = null): FloatArray
Content copied to clipboard
Converts image to FloatArray without normalization.
Return
FloatArray with pixel values in the [0, 255]
range
Parameters
image
image to convert
colorMode
color mode to convert the image to. null
value keeps the original color mode.
fun toRawFloatArray(inputStream: InputStream, colorMode: ColorMode? = null): FloatArray
Content copied to clipboard
Reads the image from inputStream and converts it to FloatArray without normalization.
Return
FloatArray with pixel values in [0, 255]
range
Parameters
inputStream
source of the image to convert
colorMode
color mode to convert the image to. null
value keeps the original color mode.
fun toRawFloatArray(imageFile: File, colorMode: ColorMode? = null): FloatArray
Content copied to clipboard
Reads the image from imageFile and converts it to FloatArray without normalization.
Return
FloatArray with pixel values in the [0, 255]
range
Parameters
imageFile
source of the image to convert
colorMode
color mode to convert the image to. null
value keeps the original color mode.