Class ImplConvertRaster

java.lang.Object
boofcv.io.image.impl.ImplConvertRaster

public class ImplConvertRaster
extends Object
Routines for converting to and from BufferedImage that use its internal raster for better performance.
  • Constructor Details

    • ImplConvertRaster

      public ImplConvertRaster()
  • Method Details

    • bufferedToGray

      public static void bufferedToGray​(DataBufferUShort buffer, WritableRaster src, GrayI16 dst)
      A faster convert that works directly with a specific raster
    • from_4BU8_to_U8

      public static void from_4BU8_to_U8​(byte[] srcData, int srcStride, int srcOffset, GrayU8 dst)
    • from_1BU8_to_U8

      public static void from_1BU8_to_U8​(byte[] srcData, int size, int srcStride, int srcOffset, int srcStrideDiff, GrayU8 dst)
    • from_3BU8_to_U8

      public static void from_3BU8_to_U8​(byte[] srcData, int srcStride, int srcOffset, GrayU8 dst)
    • from_4BU8_to_F32

      public static void from_4BU8_to_F32​(byte[] srcData, int srcStride, int srcOffset, GrayF32 dst)
    • from_1BU8_to_F32

      public static void from_1BU8_to_F32​(byte[] srcData, int srcStride, int srcOffset, GrayF32 dst)
    • from_3BU8_to_F32

      public static void from_3BU8_to_F32​(byte[] srcData, int srcStride, int srcOffset, GrayF32 dst)
    • bufferedToInterleaved

      public static void bufferedToInterleaved​(DataBufferByte buffer, WritableRaster src, InterleavedF32 dst)
      A faster convert that works directly with a specific raster
    • bufferedToInterleaved

      public static void bufferedToInterleaved​(DataBufferByte buffer, WritableRaster src, InterleavedU8 dst)
    • from_4BU8_to_PLF32

      public static void from_4BU8_to_PLF32​(byte[] srcData, int srcStride, int srcOffset, Planar<GrayF32> dst)
    • from_1BU8_to_PLF32

      public static void from_1BU8_to_PLF32​(byte[] srcData, int srcStride, int srcOffset, Planar<GrayF32> dst)
    • from_3BU8_to_PLF32

      public static void from_3BU8_to_PLF32​(byte[] srcData, int srcStride, int srcOffset, Planar<GrayF32> dst)
    • from_4BU8_to_PLU8

      public static void from_4BU8_to_PLU8​(byte[] srcData, int srcStride, int srcOffset, Planar<GrayU8> dst)
    • from_1BU8_to_PLU8

      public static void from_1BU8_to_PLU8​(byte[] srcData, int srcStride, int srcOffset, Planar<GrayU8> dst)
    • from_3BU8_to_PLU8

      public static void from_3BU8_to_PLU8​(byte[] srcData, int srcStride, int srcOffset, Planar<GrayU8> dst)
    • bufferedToGray

      public static void bufferedToGray​(DataBufferInt buffer, WritableRaster src, GrayU8 dst)
      A faster convert that works directly with a specific raster
    • bufferedToGray

      public static void bufferedToGray​(DataBufferInt buffer, WritableRaster src, GrayF32 dst)
      A faster convert that works directly with a specific raster
    • bufferedToPlanar_U8

      public static void bufferedToPlanar_U8​(DataBufferInt buffer, WritableRaster src, Planar<GrayU8> dst)
      A faster convert that works directly with a specific raster
    • bufferedToPlanar_F32

      public static void bufferedToPlanar_F32​(DataBufferInt buffer, WritableRaster src, Planar<GrayF32> dst)
      A faster convert that works directly with a specific raster
    • bufferedToInterleaved

      public static void bufferedToInterleaved​(DataBufferInt buffer, WritableRaster src, InterleavedU8 dst)
      A faster convert that works directly with a specific raster
    • bufferedToInterleaved

      public static void bufferedToInterleaved​(DataBufferInt buffer, WritableRaster src, InterleavedF32 dst)
    • bufferedToGray

      public static void bufferedToGray​(BufferedImage src, byte[] dstData, int dstStartIndex, int dstStride)
    • bufferedToGray

      public static void bufferedToGray​(BufferedImage src, GrayI16 dst)

      Converts a buffered image into an 16bit intensity image using the BufferedImage's RGB interface.

      This is much slower than working directly with the BufferedImage's internal raster and should be avoided if possible.

      Parameters:
      src - Input image.
      dst - Output image.
    • bufferedToGray

      public static void bufferedToGray​(BufferedImage src, float[] data, int dstStartIndex, int dstStride)
    • bufferedToPlanar_U8

      public static void bufferedToPlanar_U8​(BufferedImage src, Planar<GrayU8> dst)

      Converts a buffered image into an planar image using the BufferedImage's RGB interface.

      This is much slower than working directly with the BufferedImage's internal raster and should be avoided if possible.

      Parameters:
      src - Input image.
      dst - Output image.
    • bufferedToPlanar_F32

      public static void bufferedToPlanar_F32​(BufferedImage src, Planar<GrayF32> dst)

      Converts a buffered image into an planar image using the BufferedImage's RGB interface.

      This is much slower than working directly with the BufferedImage's internal raster and should be avoided if possible.

      Parameters:
      src - Input image.
      dst - Output image.
    • bufferedToInterleaved

      public static void bufferedToInterleaved​(BufferedImage src, InterleavedF32 dst)
    • bufferedToInterleaved

      public static void bufferedToInterleaved​(BufferedImage src, InterleavedU8 dst)

      Converts a buffered image into an planar image using the BufferedImage's RGB interface.

      This is much slower than working directly with the BufferedImage's internal raster and should be avoided if possible.

      Parameters:
      src - Input image.
      dst - Output image.
    • grayToBuffered

      public static void grayToBuffered​(GrayU8 src, DataBufferByte buffer, WritableRaster dst)
    • grayToBuffered

      public static void grayToBuffered​(GrayI16 src, DataBufferByte buffer, WritableRaster dst)
    • grayToBuffered

      public static void grayToBuffered​(GrayF32 src, DataBufferByte buffer, WritableRaster dst)
    • grayToBuffered

      public static void grayToBuffered​(GrayI16 src, DataBufferUShort buffer, WritableRaster dst)
    • planarToBuffered_U8

      public static void planarToBuffered_U8​(Planar<GrayU8> src, DataBufferByte buffer, WritableRaster dst)
    • planarToBuffered_F32

      public static void planarToBuffered_F32​(Planar<GrayF32> src, DataBufferByte buffer, WritableRaster dst)
    • grayToBuffered

      public static void grayToBuffered​(GrayU8 src, DataBufferInt buffer, WritableRaster dst)
    • grayToBuffered

      public static void grayToBuffered​(GrayI16 src, DataBufferInt buffer, WritableRaster dst)
    • grayToBuffered

      public static void grayToBuffered​(GrayF32 src, DataBufferInt buffer, WritableRaster dst)
    • planarToBuffered_U8

      public static void planarToBuffered_U8​(Planar<GrayU8> src, DataBufferInt buffer, WritableRaster dst)
    • planarToBuffered_F32

      public static void planarToBuffered_F32​(Planar<GrayF32> src, DataBufferInt buffer, WritableRaster dst)
    • grayToBuffered

      public static void grayToBuffered​(GrayU8 src, BufferedImage dst)
    • grayToBuffered

      public static void grayToBuffered​(GrayI16 src, BufferedImage dst)
    • grayToBuffered

      public static void grayToBuffered​(GrayF32 src, BufferedImage dst)
    • planarToBuffered_U8

      public static void planarToBuffered_U8​(Planar<GrayU8> src, BufferedImage dst)
    • planarToBuffered_F32

      public static void planarToBuffered_F32​(Planar<GrayF32> src, BufferedImage dst)
    • interleavedToBuffered

      public static void interleavedToBuffered​(InterleavedU8 src, DataBufferInt buffer, WritableRaster dst)
    • interleavedToBuffered

      public static void interleavedToBuffered​(InterleavedU8 src, DataBufferByte buffer, WritableRaster dst)
    • interleavedToBuffered

      public static void interleavedToBuffered​(InterleavedU8 src, BufferedImage dst)
    • interleavedToBuffered

      public static void interleavedToBuffered​(InterleavedF32 src, DataBufferInt buffer, WritableRaster dst)
    • interleavedToBuffered

      public static void interleavedToBuffered​(InterleavedF32 src, DataBufferByte buffer, WritableRaster dst)
    • interleavedToBuffered

      public static void interleavedToBuffered​(InterleavedF32 src, BufferedImage dst)
    • orderBandsIntoRGB

      public static void orderBandsIntoRGB​(InterleavedU8 image, BufferedImage input)
    • orderBandsIntoRGB

      public static void orderBandsIntoRGB​(InterleavedF32 image, BufferedImage input)
    • orderBandsBufferedFromRGB

      public static void orderBandsBufferedFromRGB​(DataBufferByte buffer, WritableRaster raster, int type)
      The image the BufferedImage was created from had RGB or RGBA color order. This swaps the bytes around to put it into the expected local format
    • orderBandsBufferedFromRGB

      public static void orderBandsBufferedFromRGB​(DataBufferInt buffer, WritableRaster raster, int type)
      The image the BufferedImage was created from had RGB or RGBA color order. This swaps the bytes around to put it into the expected local format