toColorBuffer
Converts a GrayU8 object into a ColorBuffer where each pixel in the grayscale image is mapped to an RGB color with identical red, green, and blue values.
If the target parameter is provided, the conversion is performed in-place within the specified ColorBuffer. Otherwise, a new ColorBuffer is created and returned. The returned or updated ColorBuffer has an RGB format and uses unsigned 8-bit integers for its color components.
Return
A ColorBuffer containing the RGB representation of the GrayU8 image.
Parameters
An optional ColorBuffer to store the converted image. If null, a new ColorBuffer is created.
Converts a GrayF32 object into a ColorBuffer where each pixel in the grayscale image is mapped to an RGB color with identical red, green, and blue values.
If the target parameter is provided, the conversion is performed in-place within the specified ColorBuffer. Otherwise, a new ColorBuffer is created and returned. The returned or updated ColorBuffer has an RGB format and uses 32-bit floats for its color components.
Return
A ColorBuffer containing the RGB representation of the GrayF32 image.
Parameters
An optional ColorBuffer to store the converted image. If null, a new ColorBuffer is created.
Converts a Planar<GrayU8> object into a ColorBuffer with the same number of channels (bands).
If the target parameter is provided, the conversion is performed in-place within the specified ColorBuffer. Otherwise, a new ColorBuffer is created and returned. The returned or updated ColorBuffer has an RGB format and uses unsigned 8-bit integers for its color components.
Return
A ColorBuffer containing the RGB representation of the Planar<GrayU8> image.
Parameters
An optional ColorBuffer to store the converted image. If null, a new ColorBuffer is created.
Converts a Planar<GrayF32> object into a ColorBuffer with the same number of channels (bands).
If the target parameter is provided, the conversion is performed in-place within the specified ColorBuffer. Otherwise, a new ColorBuffer is created and returned. The returned or updated ColorBuffer has an RGB format and uses 32-bit floats for its color components.
Return
A ColorBuffer containing the RGB representation of the Planar<GrayF32> image.
Parameters
An optional ColorBuffer to store the converted image. If null, a new ColorBuffer is created.