Documentation of 'jv.project.PvDisplayIf' Java class
PvDisplayIf ("JavaView Reference Manual")
"JavaView? v5.03.003"
jv.project

Interface PvDisplayIf

  • All Superinterfaces:
    java.util.EventListener, java.awt.event.KeyListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener, PsUpdateIf
    All Known Implementing Classes:
    PvDisplay


    public interface PvDisplayIf
    extends PsUpdateIf, java.awt.event.KeyListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener
    This interface must be implemented by all displays to be registered in JavaView, and which want to display any of the geometries implementing the interface PgGeometryIf. Each geometry instance may be registered in a set of displays. If a geometry is modified then it must notify the associated displays via a call display.update(geometry) to invoke a repaint(). In response to this update the display calls the geometries paint(PvGeometryIf cont) method in which a container is filled with the modified data of the geometry.
    See Also:
    PgGeometryIf, PgGeometryIf.paint(PvGeometryIf), PvDisplay
    Author:
    Konrad Polthier
    Version:
    11.02.14, 3.60 revised (kp) Methods to show scenegraph added.
    07.01.07, 3.50 revised (kp) Two new methods clearPopupMenu() and addPopupItem() added.
    04.09.06, 3.40 revised (kp) New flags PICK_yyy added which determine sets of pickable geometries.
    24.09.05, 3.30 revised (kp) Fill display added which 2D-scales the projected data.
    20.04.03, 3.20 revised (kp) Method getVisibleGeometries() added.
    19.03.03, 3.10 revised (kp) Scene title handling added.
    22.12.02, 3.00 revised (kp) Methods for model and ambient transformations added.
    09.12.02, 2.90 revised (kp) Methods for PvGeometryListenerIf added.
    11.08.02, 2.80 revised (kp) Some static camera variables transferred to PvCameraIf.
    06.05.02, 2.80 revised (kp) New methods for doubleBuffering added.
    20.12.01, 2.70 revised (ep) Internationalization.
    09.11.01, 2.60 revised (kp) New tag to unmark elements added.
    15.03.01, 2.50 revised (kp) New method getCameras() added.
    21.01.01, 2.40 revised (kp) New methods for positioning a background image added.
    05.01.01, 2.30 revised (kp) Methods for z-buffered drawing added.
    16.11.00, 2.20 revised (kp) New mode DUPLICATE added for reflection.
    29.10.00, 2.10 revised (kp) New mode DELETE added.
    29.09.00, 2.00 revised (kp) Many set/get methods renamed to show/isShowing.
    29.09.00, 1.99 revised (kp) Renamed to PvDisplayIf from PgDisplayIf.
    26.09.00, 1.90 revised (kp) Dependency on package jv.anim removed.
    10.08.00, 1.80 revised (kp) Two methods for get/setting filename of background image removed.
    28.07.00, 1.70 revised (kp) Implementation of mouse and key event interfaces added.
    18.07.00, 1.50 revised (kp) Mode MODE_DISPLAY_PICK now returns display pick events and no geometries.
    03.07.00, 1.40 revised (kp) Additional paint flags added.
    06.05.00, 1.35 revised (kp) Number of methods to access PvPickListener reduced.
    27.03.00, 1.31 revised (ep) changed return type of getCamera() to PvCameraIf.
    07.02.00, 1.30 revised (kp) Additional mode to scale to specified rectangle added.
    23.12.99, 1.20 revised (kp) Access to components of transformation matrix.
    31.10.99, 1.10 revised (kp) Some methods added.
    09.02.98, 1.00 created (kp)
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      static int CAMERA_MODEL
      Deprecated. 
      use corresponding instance of PvCameraIf
      static java.lang.String[] CAMERA_NAME
      Deprecated. 
      use PvCameraIf#CAMERA_NAME
      static int CAMERA_ORTHO_XY
      Deprecated. 
      use corresponding instance of PvCameraIf
      static int CAMERA_ORTHO_XZ
      Deprecated. 
      use corresponding instance of PvCameraIf
      static int CAMERA_ORTHO_YZ
      Deprecated. 
      use corresponding instance of PvCameraIf
      static int CAMERA_PERSPECTIVE
      Deprecated. 
      use corresponding instance of PvCameraIf
      static int GRID_XY
      Orientation of the grid to lie in the xy-plane.
      static int GRID_XZ
      Orientation of the grid to lie in the xz-plane.
      static int GRID_YZ
      Orientation of the grid to lie in the yz-plane.
      static int IMAGE_CENTER
      Determines that a background image is positioned in the center of a display.
      static int IMAGE_FIT
      Determines that a background image is uniformly scaled to fill the display.
      static int IMAGE_RESIZE
      Determines that a background image is (non-uniformly) resized to fill the display.
      static int IMAGE_TESSELATE
      Determines that a background image is repeated to fill the display.
      static int MATRIX_AMBIENT
      Type of geometry ambient modeling matrix used by cameras and display.
      static int MATRIX_INV_AMBIENT
      Type of inverse geometry ambient modeling matrix used by cameras and display.
      static int MATRIX_INV_MODEL
      Type of inverse geometry modeling matrix used by cameras and display.
      static int MATRIX_INV_PROJECT
      Type of inverse projection matrix used by cameras and display.
      static int MATRIX_INV_PROJECT_NON
      Type of inverse projection matrix used by cameras and display.
      static int MATRIX_INV_PROJVIEW
      Type of inverse transformation matrix PV^-1 used by cameras and display.
      static int MATRIX_INV_PROJVIEW_NON
      Type of inverse transformation matrix PV^-1 used by cameras and display.
      static int MATRIX_INV_TRANS
      Type of inverse full transformation matrix PVM^-1 used by cameras and display.
      static int MATRIX_INV_TRANS_NON
      Type of inverse full transformation matrix PVM^-1 used by cameras and display.
      static int MATRIX_INV_VIEW
      Type of inverse camera viewing matrix used by cameras and display.
      static int MATRIX_MODEL
      Type of geometry modeling matrix used by cameras and display.
      static int MATRIX_PROJECT
      Type of projection matrix used by cameras and display.
      static int MATRIX_PROJECT_NON
      Type of projection matrix used by cameras and display.
      static int MATRIX_PROJVIEW
      Type of transformation matrix PV used by cameras and display.
      static int MATRIX_PROJVIEW_NON
      Type of transformation matrix PV used by cameras and display.
      static int MATRIX_TRANS
      Type of full transformation matrix PVM used by cameras and display.
      static int MATRIX_TRANS_NON
      Type of full transformation matrix PVM used by cameras and display.
      static int MATRIX_VIEW
      Type of camera viewing matrix used by cameras and display.
      static int MODE_ADD
      Major mode in display to add new points of geometries.
      static int MODE_ADD_ELEMENT
      Major mode in display to add new elements to geometry.
      static int MODE_BOUNDARY_PICK
      Minor mode in display to pick boundaries of geometries.
      static int MODE_DELETE
      Major mode in display to delete items or geometries.
      static int MODE_DETAIL
      Minor mode in display to show detail information of geometry items.
      static int MODE_DISPLAY_PICK
      Major mode in display to select initial points in display without picking geometries.
      static int MODE_DRAWING
      Major mode allows to draw sketches in the display which are then converted to strokes.
      static int MODE_DUPLICATE
      Major mode in display to duplicate geometries.
      static int MODE_FLY
      Minor mode in display to fly towards to or away from the camera interest.
      static int MODE_HIGHLIGHT
      Major mode in display to highlight items on geometries if they receive focus.
      static int MODE_INITIAL_PICK
      Major mode in display to select initial points on geometries.
      static int MODE_MARK
      Major mode in display to mark a set of points on geometries.
      static int MODE_MARK_ELEMENT 
      static int MODE_MARK_ELEMENTS
      Major mode in display to mark a set of elements on geometries.
      static int MODE_ORBIT
      Major mode in display to rotate geometry.
      static int MODE_PICK
      Major mode in display to pick and modify vertices.
      static int MODE_SCALE
      Major mode in display to scale geometry by zooming.
      static int MODE_SCALE_RECT
      Major mode in display to scale geometry by zooming into a specified rectangle.
      static int MODE_TRANS
      Major mode in display to (x,y)-translate geometry.
      static int MODE_TRANS_Z
      Major mode in display to z-translate geometry.
      static int MODE_UNMARK
      Major mode in display to unmark a set of points on surfaces.
      static int MODE_UNMARK_ELEMENTS
      Major mode in display to mark a set of elements on geometries.
      static int MODE_URL
      Minor mode in display to follow hyperlinks attached to vertices and elements.
      static int MODE_VERTICAL
      Major mode in display to rotate geometry either around z-axis of scene or around x-axis of display canvas, depending on larger mouse increment.
      static int PAINT_ALL
      Enable drawing in display canvas, default enabled, otherwise no repaint of the display happens, and nothing is visible nor changes.
      static int PAINT_ANTIALIAS
      Enable antialiasing of display.
      static int PAINT_AXES
      Enable drawing of a coordinate axes around scene in the display.
      static int PAINT_BACKGROUND
      Enable drawing of colored background.
      static int PAINT_BACKGROUND_IMAGE
      Enable drawing of background image.
      static int PAINT_BACKIMAGE
      Deprecated. 
      use PAINT_BACKGROUND_IMAGE
      static int PAINT_BNDBOX
      Enable drawing of bounding box of current geometry.
      static int PAINT_BORDER
      Enable drawing of sunk border around display canvas.
      static int PAINT_CENTER
      Enable drawing of center of active geometry.
      static int PAINT_CLEAR_SCREEN
      Enable clearing of screen after each repaint.
      static int PAINT_CROSS
      Enable drawing of cross at current cursor position.
      static int PAINT_FOREGROUND_IMAGE
      Enable drawing of foreground image.
      static int PAINT_FRAME
      Enable drawing of a small coordinate frame in the lower left corner of the display.
      static int PAINT_INFO
      Enable drawing of additional information close to cursor in overlay window.
      static int PAINT_MAGNET
      Attach cursor to vertices of nearby.
      static int PAINT_SINGLE
      Restrict drawing to a single geometry at the same time.
      static int PAINT_ZOOM
      Scale transformation matrix to simulate floating point accuracy in pixel integers.
      static int PICK_ALL
      All geometries of a display are pickable in pick and initialPick modes (default).
      static int PICK_BACKGROUND
      The background geometry of a display is pickable in pick and initialPick modes.
      static int PICK_SELECTED
      The selected geometry of a display is pickable in pick and initialPick modes.
      static int PICK_UNSELECTED
      The selected geometry of a display is pickable in pick and initialPick modes.
      static int TRANSFORM_AMBIENT
      Viewing transformations affect the ambient modeling matrix of geometry.
      static int TRANSFORM_CAMERA
      Viewing transformations affect the camera viewing matrix.
      static int TRANSFORM_MODEL
      Viewing transformations affect the modeling matrix of geometry.
    • Method Summary

      All Methods Instance Methods Abstract Methods Deprecated Methods 
      Modifier and Type Method and Description
      void addCameraListener(PvCameraListenerIf listener)
      Add camera listener to receive camera events PvCameraEvent.
      boolean addGeometry(PgGeometryIf anObject)
      Register geometry in display.
      void addGeometryListener(PvGeometryListenerIf listener)
      Add geometry listener to receive geometry events.
      void addKeyListener(java.awt.event.KeyListener listener)
      Register a keyListener to receive keyboard events of JavaView.
      boolean addLight(PvLightIf light)
      Add a light to the current scene.
      void addPickListener(PvPickListenerIf listener)
      Add pick listener to receive pick events PvPickEvent.
      void addPopupItem(int menuID)
      Add a menu item to the right-mouse popup menu.
      void center()
      Scale camera such that current geometries are centered in the display.
      void clearPopupMenu()
      Removes all added menu items from right-mouse popup menu, except some standard JavaView items such as "exit".
      boolean containsGeometry(PgGeometryIf anObject)
      Check whether geometry is registered in display.
      void enableClip(boolean aFlag)
      Deprecated. 
      boolean fit()
      Scale camera such that current geometries fit into display.
      java.awt.Color getBackgroundColor()
      Get color of background of display.
      java.awt.Image getBackgroundImage()
      Get background image of display canvas.
      java.lang.String getBackgroundImageFile()
      Get background image filename of display canvas.
      int getBackgroundImageFit()
      Get the mode determining how a background image is scaled w.r.t. the display canvas.
      java.awt.Color getBndBoxColor()
      Get color of bounding box.
      double getBndBoxSize()
      Get thickness of edges of bounding box.
      PdVector getBoxRatio()
      Get individual scaling factors of coordinate axes.
      PvCameraIf getCamera()
      Get current camera.
      PvCameraIf getCamera(int type)
      Get a camera object of given type if registered in display.
      PsPanel getCameraPanel()
      Get info panel of current camera.
      PvCameraIf[] getCameras()
      Get set of registered cameras.
      java.awt.Canvas getCanvas()
      Get canvas of this display.
      double[] getClipBounds(int ind)
      Get minimum and maximum in one dimension of the clipping box.
      int getClipBoundsType()
      Get index of axis which is selected when scene clip bounds is active of becomes active.
      double getFarClip()
      Get far clip distance of current camera.
      java.awt.Color getForegroundColor()
      Get foreground color.
      java.awt.Image getForegroundImage()
      Get foreground image of display canvas.
      java.lang.String getForegroundImageFile()
      Get foreground image filename of display canvas.
      int getForegroundImageFit()
      Get the mode determining how a foreground image is scaled w.r.t. the display canvas.
      java.awt.Frame getFrame()
      Get reference to container frame of display, e.g. to allow display to hide/show frame.
      PgGeometryIf[] getGeometries()
      Get all registered geometry in display.
      java.awt.Graphics getGraphics()
      Deprecated. 
      since JavaView 3.99.011, use getCanvas().getGraphics() instead.
      PdVector getGridIncrements(int gridOrient)
      Get spacing between grid lines in both coordinate directions.
      java.awt.Image getImage()
      Get the rendered image of the scene.
      int getImageFitMode()
      Deprecated. 
      use getBackgroundImageFit()
      PsPanel getInfoPanel()
      Get info panel of display.
      PvLightIf getLight()
      Get current light object.
      int getLightingModel()
      Get currently active lighting model.
      PsPanel getLightPanel()
      Get info panel of current camera.
      PvLightIf[] getLights()
      Get registered lights as enumeration.
      int getMajorMode()
      Get the current interaction mode.
      java.lang.String getName()
      Get name of display, e.g. used as title in info panel and hashtable of PvViewer.
      double getNearClip()
      Get near clip distance of current camera.
      int getNumGeometries()
      Get number of all registered geometry in display.
      int getNumLights()
      Get number of light objects.
      java.lang.String getSceneTitle()
      Get title of scene.
      PgGeometryIf getSelectedGeometry()
      Get selected geometry in display.
      PvLightIf getSelectedLight()
      Select light from the list of registered lights in this scene.
      java.awt.Dimension getSize()
      Get dimension with height and width of drawing canvas.
      int getTransformationMode()
      Check whether transformation of current model is active, i.e. of model matrix.
      PdMatrix getTransMatrix(int type)
      Get 4*4 transformation matrix or components from current camera and display.
      PvViewerIf getViewer()
      Get the viewer manager of display, which manages multiple displays and is key listener.
      PgGeometryIf[] getVisibleGeometries()
      Get all visible registered geometry in display.
      boolean hasCamera(int type)
      Determine whether a camera object of given type is registered in display.
      boolean hasCameraListener(PvCameraListenerIf listener)
      Check for a registered camera listener.
      boolean hasGeometryListener(PvGeometryListenerIf listener)
      Check for a registered geometry listener.
      boolean hasLight(PvLightIf light)
      Determine whether a light is registered in display.
      boolean hasPaintTag(long flags)
      Check whether either of the bits in argument flags has been set.
      boolean hasPickListener(PvPickListenerIf listener)
      Check for a registered pick listener.
      boolean incrementAutoRotation()
      Do an increment of the auto-rotation animation.
      void init()
      Initialize and reset display.
      boolean isClip()
      Deprecated. 
      boolean isEnabled3DLook()
      Check whether thick vertices and edges are drawn as 3d shapes in z-buffer mode.
      boolean isEnabledAdaptiveSize()
      Check whether adaptive thickness of vertices and edges is enabled.
      boolean isEnabledAnimation()
      Check whether auto-rotation is enabled.
      boolean isEnabledAntiAlias()
      Check if antialiased drawing is enabled.
      boolean isEnabledBoxRatio()
      Check whether individual scaling factors of coordinate axes is enabled.
      boolean isEnabledClip()
      Check whether clipping with front and back plane is enabled.
      boolean isEnabledClipAutoBounds()
      Check whether automatic recalculation of clip range is enabled when clipRange is switched on.
      boolean isEnabledClipBounds()
      Check whether clipping along coordinate axes is enabled.
      boolean isEnabledDirectSelect()
      Check whether selecting is enabled during mouse pick.
      boolean isEnabledDoubleBuffer()
      Check if double buffered drawing is enabled.
      boolean isEnabledFillDisplay()
      Check if scaling of scene to fill display is enabled.
      boolean isEnabledInspection()
      Check whether display and selected geometry can be inspected in control window.
      boolean isEnabledIntegerPick()
      Check whether picking is constrained to an integer grid.
      boolean isEnabledLocalTransform()
      Get flag whether local coordinate system is used in camera transformations.
      boolean isEnabledPainters()
      Check whether painter's algorithm during drawing is enabled.
      boolean isEnabledRepaint()
      Determine whether painting is enabled.
      boolean isEnabledUpdate()
      Determine whether update mechanism is enabled.
      boolean isEnabledZBuffer()
      Check whether z-buffered drawing is enabled.
      boolean isShowingAxes()
      Check whether axes of active geometry is currently showing.
      boolean isShowingBackgroundImage()
      Check drawing of background image of display window.
      boolean isShowingBackImage()
      Check drawing of background image of display window. // * @deprecated use showBackgroundImage(boolean)
      boolean isShowingBndBox()
      Check whether bounding box of active geometry is currently showing.
      boolean isShowingCopyright()
      Check drawing of copyright information in the display window.
      boolean isShowingDepthcue()
      Check if depthcued drawing is enabled.
      boolean isShowingEdgeAura()
      Check flag of drawing of edges by one or both elements adjacent to an edge.
      boolean isShowingEdgesOnce()
      Check flag of drawing of edges by one or both elements adjacent to an edge.
      boolean isShowingForegroundImage()
      Check drawing of foreground image of display window.
      boolean isShowingFrame()
      Check whether coordinate frame is currently showing.
      boolean isShowingGrid()
      Check whether grid is currently showing.
      boolean isShowingMagnet()
      Check whether cursor attached to vertices if nearby.
      boolean isShowingScenegraph()
      True if scenegraph is enabled.
      boolean isShowingTitle()
      Check drawing of title north in the display window.
      boolean isShowingVisible()
      True if visible geometries are show by the display.
      void releasePickFocus()
      Release pick focus, i.e. to be the unique listener who receives pick events.
      boolean removeCamera(int type)
      Remove camera from the list of installed camera to be current camera in the display.
      boolean removeCameraListener(PvCameraListenerIf listener)
      Remove a registered camera listener from list of registered listeners.
      void removeGeometries()
      Remove all geometries from display and remove any registered pick listener.
      boolean removeGeometry(PgGeometryIf anObject)
      Remove geometry from display.
      boolean removeGeometryListener(PvGeometryListenerIf listener)
      Remove a registered geometry listener from list of registered listeners.
      void removeKeyListener(java.awt.event.KeyListener listener)
      Remove a keyListener to receive keyboard events of JavaView.
      boolean removeLight(PvLightIf light)
      Remove light from list of registered lights in this scene.
      void removeLights()
      Remove all lights from list of registered lights in this scene.
      boolean removePickListener(PvPickListenerIf listener)
      Remove a registered pick listener from list of registered listeners.
      void requestPickFocus(PvPickListenerIf listener)
      Request pick focus, i.e. to be the unique listener who receives pick events.
      void saveDefaults()
      ALPHA: Save current status of display as default state to which display returns when project and user settings need to be reset.
      void saveInitials()
      Save current status of display as initial state to which display returns when project and user settings need to be reset.
      boolean selectCamera(int type)
      Select camera from the list of installed camera to be current camera in the display.
      boolean selectGeometry(PgGeometryIf anObject)
      Select geometry in display to receive pick events.
      boolean selectLight(PvLightIf light)
      Select light from the list of registered lights in this scene.
      void setAutoCenter(boolean flag)
      Set flag which determines whether camera will automatically center on geometry.
      void setAutoRotation(PdVector axis, double angle)
      Set axis and angle for auto-rotation.
      void setBackgroundColor(java.awt.Color aColor)
      Set color of background of display.
      void setBackgroundImage(java.awt.Image image)
      Set background image of display canvas.
      void setBackgroundImageFile(java.lang.String fileName)
      Set filename of background image of display canvas.
      void setBackgroundImageFit(int mode)
      Set the mode determining how a background image is scaled w.r.t. the display canvas.
      void setBndBoxColor(java.awt.Color color)
      Set color of bounding box.
      void setBndBoxSize(double size)
      Set thickness of edges of bounding box.
      void setBoxRatio(PdVector ratio)
      Set individual scaling factors of coordinate axes.
      void setClipBounds(int ind, double[] range)
      Set minimum and maximum in one dimension of the clipping box.
      void setClipBoundsType(int type)
      Set index of axis which is selected when scene clip bounds is active of becomes active.
      void setDrawingOrder(int order, PgGeometryIf geom)
      Choose z-order of geometry when drawn in display.
      void setEnabled3DLook(boolean flag)
      Enable drawing of thick vertices and edges as 3d shapes in z-buffer mode.
      void setEnabledAdaptiveSize(boolean flag)
      Enabled adaptive thickness of vertices and edges.
      void setEnabledAnimation(boolean aFlag)
      Enable and disable auto-rotation of scene.
      void setEnabledAntiAlias(boolean flag)
      Enable antialiased drawing.
      void setEnabledBoxRatio(boolean aFlag)
      Enable and disable individual scaling factors of coordinate axes.
      void setEnabledClip(boolean aFlag)
      Enable and disable clipping with front and back plane.
      void setEnabledClipAutoBounds(boolean aFlag)
      Enable automatic recalculation of clip range when clipRange is switched on.
      void setEnabledClipBounds(boolean aFlag)
      Enable and disable clipping along coordinate axes.
      void setEnabledDirectSelect(boolean flag)
      Enable and disable clipping with front and back plane.
      void setEnabledDoubleBuffer(boolean flag)
      Enable double buffered drawing.
      void setEnabledFillDisplay(boolean flag)
      Determine if scaling of scene to fill display is enabled.
      void setEnabledInspection(boolean flag)
      Enable whether display and selected geometry can be inspected in control window.
      void setEnabledIntegerPick(boolean flag)
      Restrict picking to an integer grid.
      void setEnabledLocalTransform(boolean flag)
      Set flag whether local coordinate system is used in camera transformations.
      void setEnabledPainters(boolean aFlag)
      Enable and disable painter's algorithm during drawing.
      void setEnabledRepaint(boolean flag)
      Set flag which determines whether painting is enabled.
      void setEnabledUpdate(boolean flag)
      Set flag which determines whether update mechanism is enabled.
      void setEnabledZBuffer(boolean flag)
      Enable and disable z-buffered drawing of scene.
      void setFarClip(double dist)
      Set far clip distance of current camera, works even if clipping is disabled.
      void setForegroundColor(java.awt.Color aColor)
      Set foreground color.
      void setForegroundImage(java.awt.Image image)
      Set foreground image of display canvas.
      void setForegroundImageFile(java.lang.String fileName)
      Set foreground image of display canvas.
      void setForegroundImageFit(int mode)
      Set the mode determining how a background image is scaled w.r.t. the display canvas.
      void setFrame(java.awt.Frame frame)
      Set reference to container frame of display, e.g. to allow display to hide/show frame.
      void setGridIncrements(int gridOrient, PdVector gridIncrements)
      Set spacing between grid lines in both coordinate directions.
      void setImageFitMode(int mode)
      Deprecated. 
      use setBackgroundImageFit(int)
      void setLightingModel(int model)
      Set current lighting model.
      void setMajorMode(int aMode)
      Switch between interaction modes like rotating or scaling, usually done interactively.
      void setName(java.lang.String name)
      Set name of display, e.g. used as title in info panel and hashtable of PvViewer.
      void setNearClip(double dist)
      Set near clip distance of current camera, works even if clipping is disabled.
      void setPaintTag(long flags, boolean val)
      Set and clear all bits in argument flags determining painting aspects in the display.
      void setSceneTitle(java.lang.String title)
      Set title of scene.
      void setSizeWithinFrame(int width, int height)
      Set height and width of drawing canvas if canvas is inside a frame.
      void setTransformationMode(int mode)
      Enable transformation of modeling matrix M of single geometry rather than transforming the whole scene by modifying project P and view V matrices.
      void setTransMatrix(int type, PdMatrix mat)
      Set transformation matrix or components in current camera and display.
      void setViewer(PvViewerIf viewer)
      Set the viewer manager of display, which manages multiple displays and is key listener.
      void showAxes(boolean aFlag)
      Set visibility of axes active geometry, and create axes if not available.
      void showBackgroundImage(boolean aFlag)
      Enable and disable drawing of background image of display window.
      void showBndBox(boolean aFlag)
      Set visibility of bounding box active geometry, and create bounding box if not available.
      void showCopyright(boolean aFlag)
      Enable and disable drawing of copyright information in the display window.
      void showDepthcue(boolean aFlag)
      Enable and disable depthcue drawing.
      void showEdgeAura(boolean aFlag)
      Enable and disable drawing of edges by one or both elements adjacent to an edge.
      void showEdgesOnce(boolean aFlag)
      Enable and disable drawing of edges by one or both elements adjacent to an edge.
      void showForegroundImage(boolean aFlag)
      Enable and disable drawing of foreground image of display window.
      void showFrame(boolean aFlag)
      Set visibility of coordinate frame is shown, and create frame if not available.
      void showGrid(boolean aFlag)
      Set visibility of grid, and create grid if not available.
      void showMagnet(boolean aFlag)
      Attach cursor to vertices if nearby.
      void showScenegraph(boolean aFlag)
      Enable and disable scenegraph drawing.
      void showTitle(boolean aFlag)
      Enable and disable drawing of title north in the display window.
      void showVisible(boolean aFlag)
      Enable and disable showing of visible geometries.
      void start()
      Start auto-rotation in viewer where a matrix is constantly multiplied to transformation matrix.
      void stop()
      Stop auto-rotation in viewer.
      boolean update(java.lang.Object event)
      Update mechanism of JavaView.
      • Methods inherited from interface java.awt.event.KeyListener

        keyPressed, keyReleased, keyTyped
      • Methods inherited from interface java.awt.event.MouseListener

        mouseClicked, mouseEntered, mouseExited, mousePressed, mouseReleased
      • Methods inherited from interface java.awt.event.MouseMotionListener

        mouseDragged, mouseMoved
    • Field Detail

      • MODE_ORBIT

        static final int MODE_ORBIT
        Major mode in display to rotate geometry.
        See Also:
        Constant Field Values
      • MODE_SCALE

        static final int MODE_SCALE
        Major mode in display to scale geometry by zooming.
        See Also:
        Constant Field Values
      • MODE_SCALE_RECT

        static final int MODE_SCALE_RECT
        Major mode in display to scale geometry by zooming into a specified rectangle.
        See Also:
        Constant Field Values
      • MODE_TRANS

        static final int MODE_TRANS
        Major mode in display to (x,y)-translate geometry.
        See Also:
        Constant Field Values
      • MODE_TRANS_Z

        static final int MODE_TRANS_Z
        Major mode in display to z-translate geometry.
        See Also:
        Constant Field Values
      • MODE_PICK

        static final int MODE_PICK
        Major mode in display to pick and modify vertices.
        See Also:
        Constant Field Values
      • MODE_INITIAL_PICK

        static final int MODE_INITIAL_PICK
        Major mode in display to select initial points on geometries.
        See Also:
        Constant Field Values
      • MODE_HIGHLIGHT

        static final int MODE_HIGHLIGHT
        Major mode in display to highlight items on geometries if they receive focus.
        See Also:
        Constant Field Values
      • MODE_DISPLAY_PICK

        static final int MODE_DISPLAY_PICK
        Major mode in display to select initial points in display without picking geometries.
        See Also:
        Constant Field Values
      • MODE_MARK

        static final int MODE_MARK
        Major mode in display to mark a set of points on geometries.
        See Also:
        Constant Field Values
      • MODE_MARK_ELEMENTS

        static final int MODE_MARK_ELEMENTS
        Major mode in display to mark a set of elements on geometries.
        See Also:
        Constant Field Values
      • MODE_UNMARK_ELEMENTS

        static final int MODE_UNMARK_ELEMENTS
        Major mode in display to mark a set of elements on geometries.
        See Also:
        Constant Field Values
      • MODE_UNMARK

        static final int MODE_UNMARK
        Major mode in display to unmark a set of points on surfaces.
        See Also:
        Constant Field Values
      • MODE_ADD

        static final int MODE_ADD
        Major mode in display to add new points of geometries.
        See Also:
        Constant Field Values
      • MODE_DELETE

        static final int MODE_DELETE
        Major mode in display to delete items or geometries.
        See Also:
        Constant Field Values
      • MODE_DUPLICATE

        static final int MODE_DUPLICATE
        Major mode in display to duplicate geometries.
        See Also:
        Constant Field Values
      • MODE_ADD_ELEMENT

        static final int MODE_ADD_ELEMENT
        Major mode in display to add new elements to geometry.
        See Also:
        Constant Field Values
      • MODE_VERTICAL

        static final int MODE_VERTICAL
        Major mode in display to rotate geometry either around z-axis of scene or around x-axis of display canvas, depending on larger mouse increment.
        See Also:
        Constant Field Values
      • MODE_DRAWING

        static final int MODE_DRAWING
        Major mode allows to draw sketches in the display which are then converted to strokes.
        See Also:
        Constant Field Values
      • MODE_FLY

        static final int MODE_FLY
        Minor mode in display to fly towards to or away from the camera interest.
        See Also:
        Constant Field Values
      • MODE_URL

        static final int MODE_URL
        Minor mode in display to follow hyperlinks attached to vertices and elements.
        See Also:
        Constant Field Values
      • MODE_DETAIL

        static final int MODE_DETAIL
        Minor mode in display to show detail information of geometry items.
        See Also:
        Constant Field Values
      • MODE_BOUNDARY_PICK

        static final int MODE_BOUNDARY_PICK
        Minor mode in display to pick boundaries of geometries.
        See Also:
        Constant Field Values
      • MODE_MARK_ELEMENT

        static final int MODE_MARK_ELEMENT
        See Also:
        Constant Field Values
        HACK:
        (kp 2014-09-25) Major mode in display to mark a single element on geometries at a time.
      • CAMERA_PERSPECTIVE

        static final int CAMERA_PERSPECTIVE
        Deprecated. use corresponding instance of PvCameraIf
        Camera type and projection mode allowing to arbitrary rotate camera.
        See Also:
        Constant Field Values
      • CAMERA_ORTHO_XY

        static final int CAMERA_ORTHO_XY
        Deprecated. use corresponding instance of PvCameraIf
        Camera type and projection mode projecting orthogonally onto xy-plane.
        See Also:
        Constant Field Values
      • CAMERA_ORTHO_XZ

        static final int CAMERA_ORTHO_XZ
        Deprecated. use corresponding instance of PvCameraIf
        Camera type and projection mode projecting orthogonally onto xz-plane.
        See Also:
        Constant Field Values
      • CAMERA_ORTHO_YZ

        static final int CAMERA_ORTHO_YZ
        Deprecated. use corresponding instance of PvCameraIf
        Camera type and projection mode projecting orthogonally onto yz-plane.
        See Also:
        Constant Field Values
      • CAMERA_MODEL

        static final int CAMERA_MODEL
        Deprecated. use corresponding instance of PvCameraIf
        Misused camera type in display, simulates transformation of modeling matrix of geometry.
        See Also:
        Constant Field Values
      • CAMERA_NAME

        static final java.lang.String[] CAMERA_NAME
        Deprecated. use PvCameraIf#CAMERA_NAME
        Array of camera names. Position of names must match the integer id's of PvDisplayIf.CAMERA_PERSPECTIVE etc.
      • TRANSFORM_CAMERA

        static final int TRANSFORM_CAMERA
        Viewing transformations affect the camera viewing matrix.
        See Also:
        Constant Field Values
      • TRANSFORM_MODEL

        static final int TRANSFORM_MODEL
        Viewing transformations affect the modeling matrix of geometry.
        See Also:
        Constant Field Values
      • TRANSFORM_AMBIENT

        static final int TRANSFORM_AMBIENT
        Viewing transformations affect the ambient modeling matrix of geometry.
        See Also:
        Constant Field Values
      • GRID_XY

        static final int GRID_XY
        Orientation of the grid to lie in the xy-plane.
        See Also:
        Constant Field Values
      • GRID_YZ

        static final int GRID_YZ
        Orientation of the grid to lie in the yz-plane.
        See Also:
        Constant Field Values
      • GRID_XZ

        static final int GRID_XZ
        Orientation of the grid to lie in the xz-plane.
        See Also:
        Constant Field Values
      • IMAGE_CENTER

        static final int IMAGE_CENTER
        Determines that a background image is positioned in the center of a display.
        See Also:
        Constant Field Values
      • IMAGE_FIT

        static final int IMAGE_FIT
        Determines that a background image is uniformly scaled to fill the display.
        See Also:
        Constant Field Values
      • IMAGE_RESIZE

        static final int IMAGE_RESIZE
        Determines that a background image is (non-uniformly) resized to fill the display.
        See Also:
        Constant Field Values
      • IMAGE_TESSELATE

        static final int IMAGE_TESSELATE
        Determines that a background image is repeated to fill the display.
        See Also:
        Constant Field Values
      • MATRIX_TRANS

        static final int MATRIX_TRANS
        Type of full transformation matrix PVM used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_PROJVIEW

        static final int MATRIX_PROJVIEW
        Type of transformation matrix PV used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_PROJECT

        static final int MATRIX_PROJECT
        Type of projection matrix used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_VIEW

        static final int MATRIX_VIEW
        Type of camera viewing matrix used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_MODEL

        static final int MATRIX_MODEL
        Type of geometry modeling matrix used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_INV_TRANS

        static final int MATRIX_INV_TRANS
        Type of inverse full transformation matrix PVM^-1 used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_INV_PROJVIEW

        static final int MATRIX_INV_PROJVIEW
        Type of inverse transformation matrix PV^-1 used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_INV_PROJECT

        static final int MATRIX_INV_PROJECT
        Type of inverse projection matrix used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_INV_VIEW

        static final int MATRIX_INV_VIEW
        Type of inverse camera viewing matrix used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_INV_MODEL

        static final int MATRIX_INV_MODEL
        Type of inverse geometry modeling matrix used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_AMBIENT

        static final int MATRIX_AMBIENT
        Type of geometry ambient modeling matrix used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_INV_AMBIENT

        static final int MATRIX_INV_AMBIENT
        Type of inverse geometry ambient modeling matrix used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_TRANS_NON

        static final int MATRIX_TRANS_NON
        Type of full transformation matrix PVM used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_PROJVIEW_NON

        static final int MATRIX_PROJVIEW_NON
        Type of transformation matrix PV used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_PROJECT_NON

        static final int MATRIX_PROJECT_NON
        Type of projection matrix used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_INV_TRANS_NON

        static final int MATRIX_INV_TRANS_NON
        Type of inverse full transformation matrix PVM^-1 used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_INV_PROJVIEW_NON

        static final int MATRIX_INV_PROJVIEW_NON
        Type of inverse transformation matrix PV^-1 used by cameras and display.
        See Also:
        Constant Field Values
      • MATRIX_INV_PROJECT_NON

        static final int MATRIX_INV_PROJECT_NON
        Type of inverse projection matrix used by cameras and display.
        See Also:
        Constant Field Values
      • PAINT_ALL

        static final int PAINT_ALL
        Enable drawing in display canvas, default enabled, otherwise no repaint of the display happens, and nothing is visible nor changes. Clear this flag to prevent repainting of the display if a number of geometries must be updated at the same time. Further, when setting the tag again, then the display issues a repaint() command. Therefore, if the tag is set after the last of a sequence of geometry updates then the display repaints automatically.
        See Also:
        Constant Field Values
      • PAINT_BACKGROUND

        static final int PAINT_BACKGROUND
        Enable drawing of colored background. If disabled background is white.
        See Also:
        Constant Field Values
      • PAINT_BORDER

        static final int PAINT_BORDER
        Enable drawing of sunk border around display canvas.
        See Also:
        Constant Field Values
      • PAINT_ZOOM

        static final int PAINT_ZOOM
        Scale transformation matrix to simulate floating point accuracy in pixel integers. Required for PostScript printing to increase pixel accuracy.

        HACK: This PostScript Driver temporarily scales all integer valued quantities during display by a factor of 1000 to increase accuracy. The variable PvThickGraphics.ZOOM is set to allow to adjust all 'thickness' sizes as well. The thickness sizes are not scaled by PostScript, so we must do it in PvThickGraphics by hand. This procedure is very error prone.

        See Also:
        Constant Field Values
      • PAINT_CROSS

        static final int PAINT_CROSS
        Enable drawing of cross at current cursor position.
        See Also:
        Constant Field Values
      • PAINT_BACKGROUND_IMAGE

        static final int PAINT_BACKGROUND_IMAGE
        Enable drawing of background image.
        See Also:
        Constant Field Values
      • PAINT_BACKIMAGE

        static final int PAINT_BACKIMAGE
        Deprecated. use PAINT_BACKGROUND_IMAGE
        Enable drawing of background image.
        See Also:
        Constant Field Values
      • PAINT_FOREGROUND_IMAGE

        static final int PAINT_FOREGROUND_IMAGE
        Enable drawing of foreground image.
        See Also:
        Constant Field Values
      • PAINT_ANTIALIAS

        static final int PAINT_ANTIALIAS
        Enable antialiasing of display.
        See Also:
        Constant Field Values
      • PAINT_BNDBOX

        static final int PAINT_BNDBOX
        Enable drawing of bounding box of current geometry.
        See Also:
        Constant Field Values
      • PAINT_INFO

        static final int PAINT_INFO
        Enable drawing of additional information close to cursor in overlay window.

        Note, drawing of additional information can cause the display refresh rate to slow down since after each mouse movement a complex pick event is generated by intersecting all geometries with a ray.

        See Also:
        Constant Field Values
      • PAINT_FRAME

        static final int PAINT_FRAME
        Enable drawing of a small coordinate frame in the lower left corner of the display.
        See Also:
        Constant Field Values
      • PAINT_AXES

        static final int PAINT_AXES
        Enable drawing of a coordinate axes around scene in the display.
        See Also:
        Constant Field Values
      • PAINT_SINGLE

        static final int PAINT_SINGLE
        Restrict drawing to a single geometry at the same time. Unsetting the flag allows multiple geometries to be visible at the same time, which is the default.

        This flag only determines the number of visible geometries. Independent of this flag there may only be a single geometry active.

        See Also:
        Constant Field Values
      • PAINT_MAGNET

        static final int PAINT_MAGNET
        Attach cursor to vertices of nearby.
        See Also:
        Constant Field Values
      • PAINT_CLEAR_SCREEN

        static final int PAINT_CLEAR_SCREEN
        Enable clearing of screen after each repaint.
        See Also:
        Constant Field Values
      • PAINT_CENTER

        static final int PAINT_CENTER
        Enable drawing of center of active geometry.
        See Also:
        Constant Field Values
      • PICK_ALL

        static final int PICK_ALL
        All geometries of a display are pickable in pick and initialPick modes (default). Alternatively, a set of other geometry classes may be determined using or'ed combinations of other PICK_yyy types.
        Since:
        JavaView 3.96.037
        See Also:
        Constant Field Values
        Version:
        04.09.06, 1.00 created (kp)
      • PICK_SELECTED

        static final int PICK_SELECTED
        The selected geometry of a display is pickable in pick and initialPick modes.
        See Also:
        Constant Field Values
      • PICK_UNSELECTED

        static final int PICK_UNSELECTED
        The selected geometry of a display is pickable in pick and initialPick modes.
        See Also:
        Constant Field Values
      • PICK_BACKGROUND

        static final int PICK_BACKGROUND
        The background geometry of a display is pickable in pick and initialPick modes.
        See Also:
        Constant Field Values
    • Method Detail

      • getSceneTitle

        java.lang.String getSceneTitle()
        Get title of scene.
      • setSceneTitle

        void setSceneTitle(java.lang.String title)
        Set title of scene.
      • getName

        java.lang.String getName()
        Get name of display, e.g. used as title in info panel and hashtable of PvViewer.
        Specified by:
        getName in interface PsUpdateIf
      • setName

        void setName(java.lang.String name)
        Set name of display, e.g. used as title in info panel and hashtable of PvViewer.
      • init

        void init()
        Initialize and reset display.
      • saveInitials

        void saveInitials()
        Save current status of display as initial state to which display returns when project and user settings need to be reset. Typically, after a main program sets up the initial configuration of a display, this status might be saved as ground truth of this running session, e.g. end of PvViewer.start().
        Since:
        JavaView 4.70.010
        Version:
        26.10.16, 1.00 created (kp)
      • saveDefaults

        void saveDefaults()
        ALPHA: Save current status of display as default state to which display returns when project and user settings need to be reset.
        Since:
        JavaView 4.70.010
        Version:
        26.10.16, 1.00 created (kp)
      • isEnabledUpdate

        boolean isEnabledUpdate()
        Determine whether update mechanism is enabled.
      • setEnabledUpdate

        void setEnabledUpdate(boolean flag)
        Set flag which determines whether update mechanism is enabled.
      • isEnabledRepaint

        boolean isEnabledRepaint()
        Determine whether painting is enabled.
        Since:
        JavaView 3.62.000
        Version:
        31.10.04, 1.00 created (kp)
      • setEnabledRepaint

        void setEnabledRepaint(boolean flag)
        Set flag which determines whether painting is enabled. Switch off repaint when updating a larger number of geometries at the same time.
        Since:
        JavaView 3.62.000
        Version:
        31.10.04, 1.00 created (kp)
      • setAutoCenter

        void setAutoCenter(boolean flag)
        Set flag which determines whether camera will automatically center on geometry.
      • getGraphics

        java.awt.Graphics getGraphics()
        Deprecated. since JavaView 3.99.011, use getCanvas().getGraphics() instead.
        General AWT getGraphics(Graphics) method included in interface to allow invocation from outside the display.
      • getCanvas

        java.awt.Canvas getCanvas()
        Get canvas of this display. Before GL implementation the display was the canvas, not we return a special instance variable. For some time, display still derives from canvas and will in fact be returned.
        Since:
        JavaView 3.99.010
        Version:
        03.02.08, 1.00 created (kp)
      • addGeometry

        boolean addGeometry(PgGeometryIf anObject)
        Register geometry in display.
      • containsGeometry

        boolean containsGeometry(PgGeometryIf anObject)
        Check whether geometry is registered in display.
      • removeGeometry

        boolean removeGeometry(PgGeometryIf anObject)
        Remove geometry from display.
      • removeGeometries

        void removeGeometries()
        Remove all geometries from display and remove any registered pick listener.
      • selectGeometry

        boolean selectGeometry(PgGeometryIf anObject)
        Select geometry in display to receive pick events.
      • getSelectedGeometry

        PgGeometryIf getSelectedGeometry()
        Get selected geometry in display.
      • getNumGeometries

        int getNumGeometries()
        Get number of all registered geometry in display. Method does not return any special geometries like bounding box, coordinate frames etc.
      • getGeometries

        PgGeometryIf[] getGeometries()
        Get all registered geometry in display. Method does not return any special geometries like bounding box, coordinate frames etc.
      • getVisibleGeometries

        PgGeometryIf[] getVisibleGeometries()
        Get all visible registered geometry in display. Method does not return any special geometries like bounding box, coordinate frames etc.
      • center

        void center()
        Scale camera such that current geometries are centered in the display.
      • fit

        boolean fit()
        Scale camera such that current geometries fit into display.
        Returns:
        true if fitting was successful.
        Version:
        28.11.02, 1.10 revised (kp) Return value added.
      • getTransMatrix

        PdMatrix getTransMatrix(int type)
        Get 4*4 transformation matrix or components from current camera and display. Allows to transform world coordinates into screen coordinates [0,0]*[width-1,height-1] of display.
        Parameters:
        type - Any matrix type jv.project.PvDisplayIf#MATRIX_...
      • setTransMatrix

        void setTransMatrix(int type,
                            PdMatrix mat)
        Set transformation matrix or components in current camera and display. Allows to transform world coordinates into screen coordinates [0,0]*[width-1,height-1] of display.
        Parameters:
        type - Any matrix type jv.project.PvDisplayIf#MATRIX_...
      • setDrawingOrder

        void setDrawingOrder(int order,
                             PgGeometryIf geom)
        Choose z-order of geometry when drawn in display. For possible values see PvGeometryIf#DRAW_ORDER_*.
        See Also:
        PvGeometryIf
      • isEnabledInspection

        boolean isEnabledInspection()
        Check whether display and selected geometry can be inspected in control window.
        Since:
        JavaView 3.96.022
        Version:
        18.06.06, 1.00 created (kp)
      • setEnabledInspection

        void setEnabledInspection(boolean flag)
        Enable whether display and selected geometry can be inspected in control window.
        Since:
        JavaView 3.96.022
        Version:
        18.06.06, 1.00 created (kp)
      • isEnabledLocalTransform

        boolean isEnabledLocalTransform()
        Get flag whether local coordinate system is used in camera transformations.
        Since:
        JavaView 2.48.007
        Version:
        22.12.02, 1.00 created (kp) Added to this interface.
      • setEnabledLocalTransform

        void setEnabledLocalTransform(boolean flag)
        Set flag whether local coordinate system is used in camera transformations.
        Since:
        JavaView 2.48.007
        Version:
        22.12.02, 1.00 created (kp) Added to this interface.
      • isEnabledDirectSelect

        boolean isEnabledDirectSelect()
        Check whether selecting is enabled during mouse pick.
        Since:
        JavaView 2.48.007
        Version:
        22.12.02, 1.00 created (kp) Added to this interface.
      • setEnabledDirectSelect

        void setEnabledDirectSelect(boolean flag)
        Enable and disable clipping with front and back plane.
        Since:
        JavaView 2.48.007
        Version:
        22.12.02, 1.00 created (kp) Added to this interface.
      • getTransformationMode

        int getTransformationMode()
        Check whether transformation of current model is active, i.e. of model matrix. Otherwise, whole scene is transformed, i.e. project and view matrix.
        Since:
        JavaView 2.48.007
        Version:
        22.12.02, 1.00 created (kp) Added to this interface.
      • setTransformationMode

        void setTransformationMode(int mode)
        Enable transformation of modeling matrix M of single geometry rather than transforming the whole scene by modifying project P and view V matrices.
        Since:
        JavaView 2.48.007
        Version:
        22.12.02, 1.00 created (kp) Added to this interface.
      • requestPickFocus

        void requestPickFocus(PvPickListenerIf listener)
        Request pick focus, i.e. to be the unique listener who receives pick events. The focus should only be requested temporarily, and must be released after use.
        Parameters:
        listener - which will receives pick events
        See Also:
        releasePickFocus()
      • releasePickFocus

        void releasePickFocus()
        Release pick focus, i.e. to be the unique listener who receives pick events. The focus should only be requested temporarily, and must be released after use.
        See Also:
        requestPickFocus(PvPickListenerIf)
      • setMajorMode

        void setMajorMode(int aMode)
        Switch between interaction modes like rotating or scaling, usually done interactively. Modes may be changed either interactively using a keyboard shortcuts, or via the display panel or using via method. Modes are available in in jv.project.PvDisplayIf, for example, PvDisplayIf.MODE_SCALE
        Parameters:
        aMode - any of the modes available in PvDisplayIf.
        See Also:
        getMajorMode()
      • getMajorMode

        int getMajorMode()
        Get the current interaction mode. Modes may be changed either interactively using a keyboard shortcuts, or via the display panel or using via method. Modes are available in in jv.project.PvDisplayIf, for example, PvDisplayIf.MODE_SCALE
        Returns:
        aMode any of the modes available in PvDisplayIf.
        See Also:
        setMajorMode(int)
      • addKeyListener

        void addKeyListener(java.awt.event.KeyListener listener)
        Register a keyListener to receive keyboard events of JavaView.
      • removeKeyListener

        void removeKeyListener(java.awt.event.KeyListener listener)
        Remove a keyListener to receive keyboard events of JavaView.
      • hasPaintTag

        boolean hasPaintTag(long flags)
        Check whether either of the bits in argument flags has been set. Possible arguments are all tags PvDisplayIf#PAINT_... If available then preferably use individual isShowing...() methods.
      • setPaintTag

        void setPaintTag(long flags,
                         boolean val)
        Set and clear all bits in argument flags determining painting aspects in the display. Possible arguments are all tags PvDisplayIf#PAINT_... If available then preferably use individual show...(boolean) methods.
      • setAutoRotation

        void setAutoRotation(PdVector axis,
                             double angle)
        Set axis and angle for auto-rotation. This data is valid until the user starts interacting with the display. The main use of this method is to specify an initial axis for an animation when the display opens.
      • incrementAutoRotation

        boolean incrementAutoRotation()
        Do an increment of the auto-rotation animation.
      • start

        void start()
        Start auto-rotation in viewer where a matrix is constantly multiplied to transformation matrix. Use #setAutoRotation to specify a rotation axis. Auto-rotation spawns a new thread.
      • stop

        void stop()
        Stop auto-rotation in viewer. Use start() to continue the animation.
      • getImageFitMode

        int getImageFitMode()
        Deprecated. use getBackgroundImageFit()
        Get the mode determining how a background image is scaled w.r.t. the display canvas.
      • setImageFitMode

        void setImageFitMode(int mode)
        Deprecated. use setBackgroundImageFit(int)
        Set the mode determining how a background image is scaled w.r.t. the display canvas.
      • getBackgroundImageFit

        int getBackgroundImageFit()
        Get the mode determining how a background image is scaled w.r.t. the display canvas.
        Since:
        JavaView 2.36
      • setBackgroundImageFit

        void setBackgroundImageFit(int mode)
        Set the mode determining how a background image is scaled w.r.t. the display canvas.
        Since:
        JavaView 2.36
      • getForegroundImageFit

        int getForegroundImageFit()
        Get the mode determining how a foreground image is scaled w.r.t. the display canvas.
        Since:
        JavaView 2.36
      • setForegroundImageFit

        void setForegroundImageFit(int mode)
        Set the mode determining how a background image is scaled w.r.t. the display canvas.
        Since:
        JavaView 2.36
      • isEnabled3DLook

        boolean isEnabled3DLook()
        Check whether thick vertices and edges are drawn as 3d shapes in z-buffer mode.
        Since:
        JavaView 3.20.004
        Version:
        11.04.04, 1.00 created (kp)
      • setEnabled3DLook

        void setEnabled3DLook(boolean flag)
        Enable drawing of thick vertices and edges as 3d shapes in z-buffer mode.
        Since:
        JavaView 3.20.004
        Version:
        11.04.04, 1.00 created (kp)
      • isEnabledAdaptiveSize

        boolean isEnabledAdaptiveSize()
        Check whether adaptive thickness of vertices and edges is enabled.
        Since:
        JavaView 3.22.000
        Version:
        25.04.04, 1.00 created (kp)
      • setEnabledAdaptiveSize

        void setEnabledAdaptiveSize(boolean flag)
        Enabled adaptive thickness of vertices and edges.
        Since:
        JavaView 3.22.000
        Version:
        25.04.04, 1.00 created (kp)
      • isEnabledAnimation

        boolean isEnabledAnimation()
        Check whether auto-rotation is enabled.
      • setEnabledAnimation

        void setEnabledAnimation(boolean aFlag)
        Enable and disable auto-rotation of scene.
      • isEnabledAntiAlias

        boolean isEnabledAntiAlias()
        Check if antialiased drawing is enabled.
      • setEnabledAntiAlias

        void setEnabledAntiAlias(boolean flag)
        Enable antialiased drawing.
      • isShowingAxes

        boolean isShowingAxes()
        Check whether axes of active geometry is currently showing.
      • showAxes

        void showAxes(boolean aFlag)
        Set visibility of axes active geometry, and create axes if not available.
      • isShowingBackImage

        boolean isShowingBackImage()
        Check drawing of background image of display window. // * @deprecated use showBackgroundImage(boolean)
      • isShowingBackgroundImage

        boolean isShowingBackgroundImage()
        Check drawing of background image of display window.
        Since:
        JavaView 2.31
      • showBackgroundImage

        void showBackgroundImage(boolean aFlag)
        Enable and disable drawing of background image of display window.
        Since:
        JavaView 2.31
      • isShowingForegroundImage

        boolean isShowingForegroundImage()
        Check drawing of foreground image of display window.
        Since:
        JavaView 2.31
      • showForegroundImage

        void showForegroundImage(boolean aFlag)
        Enable and disable drawing of foreground image of display window.
        Since:
        JavaView 2.31
      • isShowingBndBox

        boolean isShowingBndBox()
        Check whether bounding box of active geometry is currently showing.
      • showBndBox

        void showBndBox(boolean aFlag)
        Set visibility of bounding box active geometry, and create bounding box if not available.
      • isEnabledClip

        boolean isEnabledClip()
        Check whether clipping with front and back plane is enabled.
      • setEnabledClip

        void setEnabledClip(boolean aFlag)
        Enable and disable clipping with front and back plane.
      • isEnabledClipAutoBounds

        boolean isEnabledClipAutoBounds()
        Check whether automatic recalculation of clip range is enabled when clipRange is switched on.
      • setEnabledClipAutoBounds

        void setEnabledClipAutoBounds(boolean aFlag)
        Enable automatic recalculation of clip range when clipRange is switched on.
      • isEnabledClipBounds

        boolean isEnabledClipBounds()
        Check whether clipping along coordinate axes is enabled.
      • setEnabledClipBounds

        void setEnabledClipBounds(boolean aFlag)
        Enable and disable clipping along coordinate axes.
      • isShowingCopyright

        boolean isShowingCopyright()
        Check drawing of copyright information in the display window.
      • showCopyright

        void showCopyright(boolean aFlag)
        Enable and disable drawing of copyright information in the display window.
      • isShowingDepthcue

        boolean isShowingDepthcue()
        Check if depthcued drawing is enabled.
      • showDepthcue

        void showDepthcue(boolean aFlag)
        Enable and disable depthcue drawing.
      • isEnabledDoubleBuffer

        boolean isEnabledDoubleBuffer()
        Check if double buffered drawing is enabled.
      • setEnabledDoubleBuffer

        void setEnabledDoubleBuffer(boolean flag)
        Enable double buffered drawing.
      • isShowingEdgeAura

        boolean isShowingEdgeAura()
        Check flag of drawing of edges by one or both elements adjacent to an edge.
      • showEdgeAura

        void showEdgeAura(boolean aFlag)
        Enable and disable drawing of edges by one or both elements adjacent to an edge.
      • isShowingEdgesOnce

        boolean isShowingEdgesOnce()
        Check flag of drawing of edges by one or both elements adjacent to an edge.
      • showEdgesOnce

        void showEdgesOnce(boolean aFlag)
        Enable and disable drawing of edges by one or both elements adjacent to an edge.
      • isEnabledFillDisplay

        boolean isEnabledFillDisplay()
        Check if scaling of scene to fill display is enabled.
        Since:
        JavaView v3.94.003.
        Version:
        28.09.05, 1.00 created (kp)
      • setEnabledFillDisplay

        void setEnabledFillDisplay(boolean flag)
        Determine if scaling of scene to fill display is enabled.
        Since:
        JavaView v3.94.003.
        Version:
        28.09.05, 1.00 created (kp)
      • isShowingFrame

        boolean isShowingFrame()
        Check whether coordinate frame is currently showing.
      • showFrame

        void showFrame(boolean aFlag)
        Set visibility of coordinate frame is shown, and create frame if not available.
      • isShowingGrid

        boolean isShowingGrid()
        Check whether grid is currently showing.
      • showGrid

        void showGrid(boolean aFlag)
        Set visibility of grid, and create grid if not available.
      • getGridIncrements

        PdVector getGridIncrements(int gridOrient)
        Get spacing between grid lines in both coordinate directions.
        Returns:
        Increments determine the spacing for both gridlines.
        Since:
        JavaView 3.96.014
        Version:
        06.06.06, 1.00 created (kp)
      • setGridIncrements

        void setGridIncrements(int gridOrient,
                               PdVector gridIncrements)
        Set spacing between grid lines in both coordinate directions. Must invoke #compute() after orientation has changed.
        Parameters:
        gridOrient - Determines the xy, yz, or xz plane, see PvDisplayIf#GRID_XY.
        gridIncrements - Determine the spacing for both gridlines.
        Since:
        JavaView 3.96.014
        Version:
        06.06.06, 1.00 created (kp)
      • isShowingScenegraph

        boolean isShowingScenegraph()
        True if scenegraph is enabled.
        Since:
        JavaView 4.08.002
        Version:
        11.02.14, 1.00 created (kp)
      • showScenegraph

        void showScenegraph(boolean aFlag)
        Enable and disable scenegraph drawing.
        Since:
        JavaView 4.08.002
        Version:
        11.02.14, 1.00 created (kp)
      • isEnabledIntegerPick

        boolean isEnabledIntegerPick()
        Check whether picking is constrained to an integer grid.
        Since:
        JavaView 3.63.002
      • setEnabledIntegerPick

        void setEnabledIntegerPick(boolean flag)
        Restrict picking to an integer grid.
        Since:
        JavaView 3.63.002
      • isShowingMagnet

        boolean isShowingMagnet()
        Check whether cursor attached to vertices if nearby.
      • showMagnet

        void showMagnet(boolean aFlag)
        Attach cursor to vertices if nearby.
      • isEnabledPainters

        boolean isEnabledPainters()
        Check whether painter's algorithm during drawing is enabled.
      • setEnabledPainters

        void setEnabledPainters(boolean aFlag)
        Enable and disable painter's algorithm during drawing.
      • isShowingTitle

        boolean isShowingTitle()
        Check drawing of title north in the display window.
        Since:
        JavaView 2.49.004
      • showTitle

        void showTitle(boolean aFlag)
        Enable and disable drawing of title north in the display window.
        Since:
        JavaView 2.49.004
      • isShowingVisible

        boolean isShowingVisible()
        True if visible geometries are show by the display.
        Since:
        JavaView 4.81.004
        Version:
        12.05.17, 1.00 created (kp)
      • showVisible

        void showVisible(boolean aFlag)
        Enable and disable showing of visible geometries. Allows to temporarily hide the current set of visible geometries by hiding the internal geometry containers.
        Since:
        JavaView 4.81.004
        Version:
        12.05.17, 1.00 created (kp)
      • isEnabledZBuffer

        boolean isEnabledZBuffer()
        Check whether z-buffered drawing is enabled.
      • setEnabledZBuffer

        void setEnabledZBuffer(boolean flag)
        Enable and disable z-buffered drawing of scene.
      • getBndBoxColor

        java.awt.Color getBndBoxColor()
        Get color of bounding box.
        Returns:
        color of bounding box
        Since:
        JavaView 2.49.005
        Version:
        18.01.03, 1.00 created (kp)
      • setBndBoxColor

        void setBndBoxColor(java.awt.Color color)
        Set color of bounding box.
        Parameters:
        color - color of bounding box
        Since:
        JavaView 2.49.005
        Version:
        18.01.03, 1.00 created (kp)
      • getBndBoxSize

        double getBndBoxSize()
        Get thickness of edges of bounding box.
        Returns:
        thickness of edges bounding box
        Since:
        JavaView 2.49.005
        Version:
        18.01.03, 1.00 created (kp)
      • setBndBoxSize

        void setBndBoxSize(double size)
        Set thickness of edges of bounding box.
        Parameters:
        size - thickness of edges bounding box
        Since:
        JavaView 2.49.005
        Version:
        18.01.03, 1.00 created (kp)
      • getBoxRatio

        PdVector getBoxRatio()
        Get individual scaling factors of coordinate axes.
        Returns:
        scaling factors of coordinate axes
        Since:
        JavaView 2.60.002
        Version:
        15.03.03, 1.00 created (kp)
      • setBoxRatio

        void setBoxRatio(PdVector ratio)
        Set individual scaling factors of coordinate axes.
        Parameters:
        ratio - scaling factors of coordinate axes
        Since:
        JavaView 2.60.002
        Version:
        15.03.03, 1.00 created (kp)
      • isEnabledBoxRatio

        boolean isEnabledBoxRatio()
        Check whether individual scaling factors of coordinate axes is enabled.
      • setEnabledBoxRatio

        void setEnabledBoxRatio(boolean aFlag)
        Enable and disable individual scaling factors of coordinate axes.
      • isClip

        boolean isClip()
        Deprecated. use #isEnabledClip
        Check whether clipping with front and back plane is enabled.
      • enableClip

        void enableClip(boolean aFlag)
        Deprecated. use #setEnabledClip
        Enable and disable clipping with front and back plane.
      • getNearClip

        double getNearClip()
        Get near clip distance of current camera. Returns a value even if clipping is disabled.
      • setNearClip

        void setNearClip(double dist)
        Set near clip distance of current camera, works even if clipping is disabled.
      • getFarClip

        double getFarClip()
        Get far clip distance of current camera. Returns a value even if clipping is disabled.
      • setFarClip

        void setFarClip(double dist)
        Set far clip distance of current camera, works even if clipping is disabled.
      • getClipBoundsType

        int getClipBoundsType()
        Get index of axis which is selected when scene clip bounds is active of becomes active.
        Since:
        JavaView 2.99.012
        Version:
        01.09.03, 1.00 created (kp)
      • setClipBoundsType

        void setClipBoundsType(int type)
        Set index of axis which is selected when scene clip bounds is active of becomes active.
        Since:
        JavaView 2.99.012
        Version:
        01.09.03, 1.00 created (kp)
      • getClipBounds

        double[] getClipBounds(int ind)
        Get minimum and maximum in one dimension of the clipping box.
        Parameters:
        ind - index of ruler of axes in which direction is clipped
        Returns:
        range minimum and maximum of visible range in axis direction
        Since:
        JavaView 2.49.005
        Version:
        19.01.03, 1.00 created (kp)
      • setClipBounds

        void setClipBounds(int ind,
                           double[] range)
        Set minimum and maximum in one dimension of the clipping box.
        Parameters:
        ind - index of ruler of axes in which direction is clipped
        range - minimum and maximum of visible range in axis direction
        Since:
        JavaView 2.49.005
        Version:
        19.01.03, 1.00 created (kp)
      • getBackgroundColor

        java.awt.Color getBackgroundColor()
        Get color of background of display. If background image is set, then color is visible in transparent regions of the image.
      • setBackgroundColor

        void setBackgroundColor(java.awt.Color aColor)
        Set color of background of display. If background image is set, then color is visible in transparent regions of the image.
      • getForegroundColor

        java.awt.Color getForegroundColor()
        Get foreground color. Currently neither defined nor used.
      • setForegroundColor

        void setForegroundColor(java.awt.Color aColor)
        Set foreground color. Currently neither defined nor used.
      • getBackgroundImage

        java.awt.Image getBackgroundImage()
        Get background image of display canvas.
      • setBackgroundImage

        void setBackgroundImage(java.awt.Image image)
        Set background image of display canvas.
      • getBackgroundImageFile

        java.lang.String getBackgroundImageFile()
        Get background image filename of display canvas.
        Returns:
        file name of background image
        Since:
        JavaView 2.31
      • setBackgroundImageFile

        void setBackgroundImageFile(java.lang.String fileName)
        Set filename of background image of display canvas. Method tries to load file immediately.
        Parameters:
        fileName - relative file name of image.
        Since:
        JavaView 2.31
      • getForegroundImage

        java.awt.Image getForegroundImage()
        Get foreground image of display canvas.
        Since:
        JavaView 2.31
      • setForegroundImage

        void setForegroundImage(java.awt.Image image)
        Set foreground image of display canvas.
        Since:
        JavaView 2.31
      • getForegroundImageFile

        java.lang.String getForegroundImageFile()
        Get foreground image filename of display canvas.
        Returns:
        file name of foreground image
        Since:
        JavaView 2.31
      • setForegroundImageFile

        void setForegroundImageFile(java.lang.String fileName)
        Set foreground image of display canvas.
        Parameters:
        fileName - relative file name of image.
        Since:
        JavaView 2.31
      • getCamera

        PvCameraIf getCamera()
        Get current camera.
      • getCameras

        PvCameraIf[] getCameras()
        Get set of registered cameras.
      • getLightingModel

        int getLightingModel()
        Get currently active lighting model.
      • setLightingModel

        void setLightingModel(int model)
        Set current lighting model.
      • addLight

        boolean addLight(PvLightIf light)
        Add a light to the current scene. Light is registered using its name.
        Parameters:
        light - new light added to scene
      • getNumLights

        int getNumLights()
        Get number of light objects.
        Returns:
        number of light objects
      • getLight

        PvLightIf getLight()
        Get current light object.
        Returns:
        current light object
      • getLights

        PvLightIf[] getLights()
        Get registered lights as enumeration.
        Returns:
        array of registered lights
      • hasLight

        boolean hasLight(PvLightIf light)
        Determine whether a light is registered in display.
        Parameters:
        light - a light object
        Returns:
        true if light is registered.
      • removeLights

        void removeLights()
        Remove all lights from list of registered lights in this scene.
      • removeLight

        boolean removeLight(PvLightIf light)
        Remove light from list of registered lights in this scene.
        Parameters:
        light - a light object
        Returns:
        true if light was found and successfully removed.
      • getSelectedLight

        PvLightIf getSelectedLight()
        Select light from the list of registered lights in this scene.
        Returns:
        true if light was found and successfully selected.
      • selectLight

        boolean selectLight(PvLightIf light)
        Select light from the list of registered lights in this scene.
        Parameters:
        light - a light object
        Returns:
        true if light was found and successfully selected.
      • getCameraPanel

        PsPanel getCameraPanel()
        Get info panel of current camera. Camera allocates panel if it does not exist.
      • getInfoPanel

        PsPanel getInfoPanel()
        Get info panel of display. Display allocates panel if it does not exist.
      • getLightPanel

        PsPanel getLightPanel()
        Get info panel of current camera. Camera allocates panel if it does not exist.
      • getFrame

        java.awt.Frame getFrame()
        Get reference to container frame of display, e.g. to allow display to hide/show frame.
      • setFrame

        void setFrame(java.awt.Frame frame)
        Set reference to container frame of display, e.g. to allow display to hide/show frame.
      • getViewer

        PvViewerIf getViewer()
        Get the viewer manager of display, which manages multiple displays and is key listener.
        Since:
        JavaView 2.30
        Version:
        25.07.02, 1.00 created (kp)
      • setViewer

        void setViewer(PvViewerIf viewer)
        Set the viewer manager of display, which manages multiple displays and is key listener.
        Since:
        JavaView 2.30
        Version:
        25.07.02, 1.00 created (kp)
      • getImage

        java.awt.Image getImage()
        Get the rendered image of the scene.
      • getSize

        java.awt.Dimension getSize()
        Get dimension with height and width of drawing canvas.
      • setSizeWithinFrame

        void setSizeWithinFrame(int width,
                                int height)
        Set height and width of drawing canvas if canvas is inside a frame.
      • clearPopupMenu

        void clearPopupMenu()
        Removes all added menu items from right-mouse popup menu, except some standard JavaView items such as "exit". Use addPopupItem(int) to fill popup menu with own selection of menu items.
        Since:
        JavaView 3.97.044
        See Also:
        addPopupItem(int)
        Version:
        05.01.07, 1.00 created (kp)
      • addPopupItem

        void addPopupItem(int menuID)
        Add a menu item to the right-mouse popup menu. Menu items appear in the same order in which they where added.

        Possible menu items are all major modes of PvDisplay specified in PsViewerIf#MENU_DISPLAY_XXX plus MENU_FILE_NEW_DISPLAY, MENU_WINDOW_CONSOLE, MENU_INSPECTOR and MENU_SEPARATOR.

        Since:
        JavaView 3.97.044
        See Also:
        clearPopupMenu()
        Version:
        05.01.07, 1.00 created (kp)
"JavaView? v5.03.003"

"

The software JavaView? is copyright protected. All Rights Reserved.
"

You see the box below because you did not login.