Documentation of 'boofcv.gui.binary.VisualizeBinaryData' Java class
VisualizeBinaryData
boofcv.gui.binary

Class VisualizeBinaryData



  • public class VisualizeBinaryData
    extends java.lang.Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method and Description
      static int[] checkColors(int[] colors, int size) 
      static java.awt.image.BufferedImage renderBinary(GrayU8 binaryImage, boolean invert, java.awt.image.BufferedImage out)
      Renders a binary image.
      static java.awt.image.BufferedImage renderContours(java.util.List<Contour> contours, int[] colorExternal, int colorInternal, int width, int height, java.awt.image.BufferedImage out)
      Draws contours.
      static java.awt.image.BufferedImage renderContours(java.util.List<Contour> contours, int colorExternal, int colorInternal, int width, int height, java.awt.image.BufferedImage out)
      Draws contours.
      static java.awt.image.BufferedImage renderContours(java.util.List<EdgeContour> edges, int[] colors, int width, int height, java.awt.image.BufferedImage out) 
      static void renderExternal(java.util.List<Contour> contours, boolean internal, boolean external, double scale, java.awt.Graphics2D g2) 
      static java.awt.image.BufferedImage renderExternal(java.util.List<Contour> contours, java.awt.Color color, java.awt.image.BufferedImage out) 
      static void renderExternal(java.util.List<Contour> contours, int[] colors, java.awt.image.BufferedImage out)
      Renders only the external contours.
      static java.awt.image.BufferedImage renderLabeled(GrayS32 labelImage, int[] colors, java.awt.image.BufferedImage out) 
      static java.awt.image.BufferedImage renderLabeled(GrayS32 labelImage, int numRegions, java.awt.image.BufferedImage out)
      Renders a labeled where each region is assigned a random color.
      static java.awt.image.BufferedImage renderLabeledBG(GrayS32 labelImage, int numRegions, java.awt.image.BufferedImage out)
      Renders a labeled image where label=0 is assumed to be the background and is always set to black.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • VisualizeBinaryData

        public VisualizeBinaryData()
    • Method Detail

      • renderContours

        public static java.awt.image.BufferedImage renderContours(java.util.List<EdgeContour> edges,
                                                                  int[] colors,
                                                                  int width,
                                                                  int height,
                                                                  java.awt.image.BufferedImage out)
      • renderContours

        public static java.awt.image.BufferedImage renderContours(java.util.List<Contour> contours,
                                                                  int colorExternal,
                                                                  int colorInternal,
                                                                  int width,
                                                                  int height,
                                                                  java.awt.image.BufferedImage out)
        Draws contours. Internal and external contours are different user specified colors.
        Parameters:
        contours - List of contours
        colorExternal - RGB color
        colorInternal - RGB color
        width - Image width
        height - Image height
        out - (Optional) storage for output image
        Returns:
        Rendered contours
      • renderContours

        public static java.awt.image.BufferedImage renderContours(java.util.List<Contour> contours,
                                                                  int[] colorExternal,
                                                                  int colorInternal,
                                                                  int width,
                                                                  int height,
                                                                  java.awt.image.BufferedImage out)
        Draws contours. Internal and external contours are different user specified colors.
        Parameters:
        contours - List of contours
        colorExternal - (Optional) Array of RGB colors for each external contour
        colorInternal - RGB color
        width - Image width
        height - Image height
        out - (Optional) storage for output image
        Returns:
        Rendered contours
      • renderExternal

        public static void renderExternal(java.util.List<Contour> contours,
                                          int[] colors,
                                          java.awt.image.BufferedImage out)
        Renders only the external contours. Each contour is individually colored as specified by 'colors'
        Parameters:
        contours - List of contours
        colors - List of RGB colors for each element in contours. If null then random colors will be used.
        out - (Optional) Storage for output
      • checkColors

        public static int[] checkColors(int[] colors,
                                        int size)
      • renderExternal

        public static java.awt.image.BufferedImage renderExternal(java.util.List<Contour> contours,
                                                                  java.awt.Color color,
                                                                  java.awt.image.BufferedImage out)
      • renderExternal

        public static void renderExternal(java.util.List<Contour> contours,
                                          boolean internal,
                                          boolean external,
                                          double scale,
                                          java.awt.Graphics2D g2)
      • renderLabeled

        public static java.awt.image.BufferedImage renderLabeled(GrayS32 labelImage,
                                                                 int[] colors,
                                                                 java.awt.image.BufferedImage out)
      • renderLabeledBG

        public static java.awt.image.BufferedImage renderLabeledBG(GrayS32 labelImage,
                                                                   int numRegions,
                                                                   java.awt.image.BufferedImage out)
        Renders a labeled image where label=0 is assumed to be the background and is always set to black. All other labels are assigned a random color.
        Parameters:
        labelImage - Labeled image with background having a value of 0
        numRegions - Number of labeled in the image, excluding the background.
        out - Output image. If null a new image is declared
        Returns:
        Colorized labeled image
      • renderLabeled

        public static java.awt.image.BufferedImage renderLabeled(GrayS32 labelImage,
                                                                 int numRegions,
                                                                 java.awt.image.BufferedImage out)
        Renders a labeled where each region is assigned a random color.
        Parameters:
        labelImage - Labeled image with labels from 0 to numRegions-1
        numRegions - Number of labeled in the image
        out - Output image. If null a new image is declared
        Returns:
        Colorized labeled image
      • renderBinary

        public static java.awt.image.BufferedImage renderBinary(GrayU8 binaryImage,
                                                                boolean invert,
                                                                java.awt.image.BufferedImage out)
        Renders a binary image. 0 = black and 1 = white.
        Parameters:
        binaryImage - (Input) Input binary image.
        invert - (Input) if true it will invert the image on output
        out - (Output) optional storage for output image
        Returns:
        Output rendered binary image

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.