Class Scatter

java.lang.Object
org.jzy3d.plot3d.primitives.Drawable
org.jzy3d.plot3d.primitives.Scatter
All Implemented Interfaces:
ISingleColorable, IGLRenderer, ISortableDraw
Direct Known Subclasses:
MonitorScatter, SelectableScatter

public class Scatter extends Drawable implements ISingleColorable
A collection of coordinates rendered as dots. Warning : dots having a width of 1 may not be visible in case HiDPI is ON.
Author:
Martin Pernollet
  • Field Details

    • colors

      public Color[] colors
    • coordinates

      public Coord3d[] coordinates
    • rgb

      public Color rgb
    • width

      public float width
  • Constructor Details

    • Scatter

      public Scatter()
    • Scatter

      public Scatter(Coord3d[] coordinates)
    • Scatter

      public Scatter(List<Coord3d> coordinates)
    • Scatter

      public Scatter(Coord3d[] coordinates, Color rgb)
    • Scatter

      public Scatter(List<Coord3d> coordinates, Color rgb)
    • Scatter

      public Scatter(Coord3d[] coordinates, Color rgb, float width)
    • Scatter

      public Scatter(List<Coord3d> coordinates, Color rgb, float width)
    • Scatter

      public Scatter(Coord3ds coords)
    • Scatter

      public Scatter(Coord3d[] coordinates, Color[] colors)
    • Scatter

      public Scatter(Coord3d[] coordinates, Color[] colors, float width)
  • Method Details

    • clear

      public void clear()
    • draw

      public void draw(IPainter painter)
      Description copied from class: Drawable
      Call OpenGL2 routines for rendering the object.
      Specified by:
      draw in interface IGLRenderer
      Specified by:
      draw in class Drawable
    • doDrawPoints

      protected void doDrawPoints(IPainter painter)
    • applyGeometryTransform

      public void applyGeometryTransform(Transform transform)
      Specified by:
      applyGeometryTransform in class Drawable
    • setData

      public void setData(Coord3d[] coordinates)
      Set the coordinates of the point.
      Parameters:
      xyz - point's coordinates
    • setData

      public void setData(List<Coord3d> coordinates)
    • updateBounds

      public void updateBounds()
      Specified by:
      updateBounds in class Drawable
    • getData

      public Coord3d[] getData()
    • setColors

      public void setColors(Color[] colors)
    • setColor

      public void setColor(Color color)
      Description copied from interface: ISingleColorable
      Set the color.
      Specified by:
      setColor in interface ISingleColorable
      Parameters:
      color - the color
    • getColor

      public Color getColor()
      Description copied from interface: ISingleColorable
      Get the color.
      Specified by:
      getColor in interface ISingleColorable
      Returns:
      color the color.
    • setWidth

      public void setWidth(float width)
      Set the width of the point.
      Parameters:
      width - point's width
    • getColors

      public Color[] getColors()
    • getCoordinates

      public Coord3d[] getCoordinates()
    • getWidth

      public float getWidth()