Package geomss

Interface GeomSSScene

  • All Known Implementing Classes:
    GeomSSBatch.PublicScene

    public interface GeomSSScene
    The public interface for the GeomSS 3D scene that is intended to be accessed from the BeanShell scripting environment.

    Modified by: Joseph A. Huwaldt

    Version:
    September 4, 2015
    Author:
    Joseph A. Huwaldt, Date: May 3, 2009
    • Method Detail

      • draw

        void draw​(GeomElement newGeom)
        Draws the specified geometry element into the 3D scene without erasing the existing geometry. This is identical to draw(newGeom, false);.
        Parameters:
        newGeom - The new geometry to be displayed on the 3D canvas.
      • draw

        void draw​(GeomElement newGeom,
                  boolean erase)
        Draws the specified geometry element in the 3D scene.
        Parameters:
        newGeom - The new geometry to be displayed on the 3D canvas.
        erase - Set to true to erase the geometry currently displayed. Set to false to add the new geometry to the existing display.
      • erase

        void erase()
        Erases all the geometry from the 3D scene.
      • erase

        void erase​(GeomElement geometry)
        Erases the specified geometry from the 3D scene (if possible).
        Parameters:
        geometry - The specific geometry to be erased from the 3D scene.
      • center

        void center()
        Centers the geometry in the display.
      • centerAndZoom

        void centerAndZoom()
        Centers the geometry in the display and zooms until the geometry fills the display.
      • pick

        GeomList pick()
        Pick items from the scene by control-clicking with the mouse. Returns a list of selected items.
        Returns:
        A list of picked items.
      • setMirrored

        void setMirrored​(boolean mirrored)
        Sets a flag indicating that the geometry is mirrored about the XZ plane of symmetry.
        Parameters:
        mirrored - Set to true to turn on mirroring.
      • isMirrored

        boolean isMirrored()
        Returns:
        a flag indicating if the geometry display is currently mirrored about the XZ plane of symmetry or not.
      • setPointColor

        void setPointColor​(java.awt.Color color)
        Sets the color used when rendering points.
        Parameters:
        color - The color to use for points drawn in the future.
      • getPointColor

        java.awt.Color getPointColor()
        Returns the color used when rendering points.
        Returns:
        the color used when rendering points.
      • setPointSize

        void setPointSize​(int pixels)
        Set the size that Point objects are rendered in pixels.
        Parameters:
        pixels - The number of pixels to use when displaying points.
      • getPointSize

        int getPointSize()
        Returns:
        the size that Point objects are rendered in pixels.
      • setLineColor

        void setLineColor​(java.awt.Color color)
        Sets the color used when rendering curves and lines.
        Parameters:
        color - The color to use when rendering lines in the future.
      • getLineColor

        java.awt.Color getLineColor()
        Returns:
        the color used when rendering curves and lines.
      • setLineWidth

        void setLineWidth​(int pixels)
        Set the width that line/curve objects are rendered in pixels.
        Parameters:
        pixels - The number of pixels line-width to use when rendering lines.
      • getLineWidth

        int getLineWidth()
        Returns:
        the width that line/curve objects are rendered in pixels.
      • setDrawTolerance

        void setDrawTolerance​(Parameter<javax.measure.quantity.Length> tol)
        Set the tolerance used when drawing parametric objects such as curves and surfaces. This tolerance is used when determining how to subdivide parametric objects for rendering. If the input value is null or equal to 0, it will be silently ignored.
        Parameters:
        tol - The tolerance used when drawing parametric objects such as curves and surfaces.
      • getDrawTolerance

        Parameter<javax.measure.quantity.Length> getDrawTolerance()
        Return the tolerance used when drawing parametric objects such as curves and surfaces. This tolerance is used when determining how to subdivide parametric objects for rendering.
        Returns:
        The tolerance used when drawing parametric objects such as curves and surfaces.
      • setProjectionPolicy

        void setProjectionPolicy​(ProjectionPolicy policy)
        Sets the projection policy for this scene. This specifies the type of projection transform that will be generated. A value of PARALLEL_PROJECTION specifies that a parallel projection transform is generated. A value of PERSPECTIVE_PROJECTION specifies that a perspective projection transform is generated.
        Parameters:
        policy - The new projection policy, one of PARALLEL_PROJECTION or PERSPECTIVE_PROJECTION.
      • setSurfaceColor

        void setSurfaceColor​(SurfaceColorType colorType,
                             java.awt.Color color)
        Set the color (of the specified type) used to render surfaces and point-arrays.
        Parameters:
        colorType - The aspect or type of the surface color that is being set.
        color - The color to use for the specified type of surface color. The alpha is ignored.
        See Also:
        setSurfaceAlpha(float)
      • getSurfaceColor

        java.awt.Color getSurfaceColor​(SurfaceColorType colorType)
        Get the color (of the specified type) used to render surfaces and point-arrays.
        Parameters:
        colorType - The aspect or type of the surface color that is being set.
        Returns:
        The color used for the specified type of surface color. Alpha is ignored.
        See Also:
        getSurfaceAlpha()
      • setSurfaceAlpha

        void setSurfaceAlpha​(float alpha)
        Set the alpha or transparency used to render surfaces and point-arrays.
        Parameters:
        alpha - The alpha value to use (0.0=completely transparent, 1.0=completely opaque).
      • getSurfaceAlpha

        float getSurfaceAlpha()
        Get the alpha or transparency used when rendering surfaces or point-arrays.
        Returns:
        The alpha value used (0.0=completely transparent, 1.0=completely opaque).
      • setSurfaceShininess

        void setSurfaceShininess​(float shininess)
        Set the shininess used when rendering surfaces and point-arrays.
        Parameters:
        shininess - The shininess to use in the range [0.0, 1.0] where 0.0 is not shiny and 1.0 is very shiny. Values outside this range are clamped.
      • getSurfaceShininess

        float getSurfaceShininess()
        Get the shininess used when rendering surfaces and point-arrays.
        Returns:
        The shininess to use in the range [0.0, 1.0] where 0.0 is not shiny and 1.0 is very shiny.