public interface PvDisplayIf extends PsUpdateIf, java.awt.event.KeyListener, java.awt.event.MouseListener, java.awt.event.MouseMotionListener
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.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_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.
|
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.
use
#setEnabledClip |
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.
|
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.
use
#isEnabledClip |
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 |
isShowingTitle()
Check drawing of title north in the display window.
|
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.
|
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 |
showTitle(boolean aFlag)
Enable and disable drawing of title north in the display window.
|
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.
|
getFather, setParent
static final int MODE_ORBIT
static final int MODE_SCALE
static final int MODE_SCALE_RECT
static final int MODE_TRANS
static final int MODE_TRANS_Z
static final int MODE_PICK
static final int MODE_INITIAL_PICK
static final int MODE_HIGHLIGHT
static final int MODE_DISPLAY_PICK
static final int MODE_MARK
static final int MODE_MARK_ELEMENTS
static final int MODE_UNMARK_ELEMENTS
static final int MODE_UNMARK
static final int MODE_ADD
static final int MODE_DELETE
static final int MODE_DUPLICATE
static final int MODE_ADD_ELEMENT
static final int MODE_VERTICAL
static final int MODE_DRAWING
static final int MODE_FLY
static final int MODE_URL
static final int MODE_DETAIL
static final int MODE_BOUNDARY_PICK
static final int CAMERA_PERSPECTIVE
static final int CAMERA_ORTHO_XY
static final int CAMERA_ORTHO_XZ
static final int CAMERA_ORTHO_YZ
static final int CAMERA_MODEL
static final java.lang.String[] CAMERA_NAME
static final int TRANSFORM_CAMERA
static final int TRANSFORM_MODEL
static final int TRANSFORM_AMBIENT
static final int GRID_XY
static final int GRID_YZ
static final int GRID_XZ
static final int IMAGE_CENTER
static final int IMAGE_FIT
static final int IMAGE_RESIZE
static final int IMAGE_TESSELATE
static final int MATRIX_TRANS
static final int MATRIX_PROJVIEW
static final int MATRIX_PROJECT
static final int MATRIX_VIEW
static final int MATRIX_MODEL
static final int MATRIX_INV_TRANS
static final int MATRIX_INV_PROJVIEW
static final int MATRIX_INV_PROJECT
static final int MATRIX_INV_VIEW
static final int MATRIX_INV_MODEL
static final int MATRIX_AMBIENT
static final int MATRIX_INV_AMBIENT
static final int MATRIX_TRANS_NON
static final int MATRIX_PROJVIEW_NON
static final int MATRIX_PROJECT_NON
static final int MATRIX_INV_TRANS_NON
static final int MATRIX_INV_PROJVIEW_NON
static final int MATRIX_INV_PROJECT_NON
static final int PAINT_ALL
static final int PAINT_BACKGROUND
static final int PAINT_BORDER
static final int PAINT_ZOOM
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.
static final int PAINT_CROSS
static final int PAINT_BACKGROUND_IMAGE
static final int PAINT_BACKIMAGE
static final int PAINT_FOREGROUND_IMAGE
static final int PAINT_ANTIALIAS
static final int PAINT_BNDBOX
static final int PAINT_INFO
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.
static final int PAINT_FRAME
static final int PAINT_AXES
static final int PAINT_SINGLE
This flag only determines the number of visible geometries. Independent of this flag there may only be a single geometry active.
static final int PAINT_MAGNET
static final int PAINT_CLEAR_SCREEN
static final int PAINT_CENTER
static final int PICK_ALL
static final int PICK_SELECTED
static final int PICK_UNSELECTED
static final int PICK_BACKGROUND
java.lang.String getSceneTitle()
void setSceneTitle(java.lang.String title)
java.lang.String getName()
getName
in interface PsUpdateIf
void setName(java.lang.String name)
void init()
boolean update(java.lang.Object event)
update
in interface PsUpdateIf
event
- carries a lot of informationPsObject
,
PsUpdateIf.getFather()
,
PsUpdateIf.setParent(PsUpdateIf)
boolean isEnabledUpdate()
void setEnabledUpdate(boolean flag)
boolean isEnabledRepaint()
void setEnabledRepaint(boolean flag)
void setAutoCenter(boolean flag)
java.awt.Canvas getCanvas()
boolean addGeometry(PgGeometryIf anObject)
boolean containsGeometry(PgGeometryIf anObject)
boolean removeGeometry(PgGeometryIf anObject)
void removeGeometries()
boolean selectGeometry(PgGeometryIf anObject)
PgGeometryIf getSelectedGeometry()
int getNumGeometries()
PgGeometryIf[] getGeometries()
PgGeometryIf[] getVisibleGeometries()
void center()
boolean fit()
PdMatrix getTransMatrix(int type)
type
- Any matrix type jv.project.PvDisplayIf#MATRIX_...void setTransMatrix(int type, PdMatrix mat)
type
- Any matrix type jv.project.PvDisplayIf#MATRIX_...void setDrawingOrder(int order, PgGeometryIf geom)
PvGeometryIf
boolean isEnabledInspection()
void setEnabledInspection(boolean flag)
boolean isEnabledLocalTransform()
void setEnabledLocalTransform(boolean flag)
boolean isEnabledDirectSelect()
void setEnabledDirectSelect(boolean flag)
int getTransformationMode()
void setTransformationMode(int mode)
void addCameraListener(PvCameraListenerIf listener)
PvCameraEvent
.listener
- which is addedhasCameraListener(PvCameraListenerIf)
,
removeCameraListener(PvCameraListenerIf)
boolean hasCameraListener(PvCameraListenerIf listener)
listener
- which is queriedtrue
if registered listener found.addCameraListener(PvCameraListenerIf)
,
removeCameraListener(PvCameraListenerIf)
boolean removeCameraListener(PvCameraListenerIf listener)
listener
- which is removedfalse
if listener does not exists.addCameraListener(PvCameraListenerIf)
,
hasCameraListener(PvCameraListenerIf)
void addGeometryListener(PvGeometryListenerIf listener)
listener
- which is addedhasGeometryListener(PvGeometryListenerIf)
,
removeGeometryListener(PvGeometryListenerIf)
boolean hasGeometryListener(PvGeometryListenerIf listener)
listener
- which is queriedtrue
if registered listener found.addGeometryListener(PvGeometryListenerIf)
,
removeGeometryListener(PvGeometryListenerIf)
boolean removeGeometryListener(PvGeometryListenerIf listener)
listener
- which is removedfalse
if listener does not exists.addGeometryListener(PvGeometryListenerIf)
,
hasGeometryListener(PvGeometryListenerIf)
void addPickListener(PvPickListenerIf listener)
PvPickEvent
.boolean hasPickListener(PvPickListenerIf listener)
true
if registered listener found.addPickListener(PvPickListenerIf)
,
removePickListener(PvPickListenerIf)
boolean removePickListener(PvPickListenerIf listener)
listener
- which is removedfalse
if listener does not exists.addPickListener(PvPickListenerIf)
,
hasPickListener(PvPickListenerIf)
void requestPickFocus(PvPickListenerIf listener)
listener
- which will receives pick eventsreleasePickFocus()
void releasePickFocus()
requestPickFocus(PvPickListenerIf)
void setMajorMode(int aMode)
PvDisplayIf.MODE_SCALE
aMode
- any of the modes available in PvDisplayIf.getMajorMode()
int getMajorMode()
PvDisplayIf.MODE_SCALE
setMajorMode(int)
void addKeyListener(java.awt.event.KeyListener listener)
void removeKeyListener(java.awt.event.KeyListener listener)
boolean hasPaintTag(long flags)
void setPaintTag(long flags, boolean val)
void setAutoRotation(PdVector axis, double angle)
boolean incrementAutoRotation()
void start()
#setAutoRotation
to specify a rotation axis.
Auto-rotation spawns a new thread.void stop()
start()
to
continue the animation.int getImageFitMode()
void setImageFitMode(int mode)
int getBackgroundImageFit()
void setBackgroundImageFit(int mode)
int getForegroundImageFit()
void setForegroundImageFit(int mode)
boolean isEnabled3DLook()
void setEnabled3DLook(boolean flag)
boolean isEnabledAdaptiveSize()
void setEnabledAdaptiveSize(boolean flag)
boolean isEnabledAnimation()
void setEnabledAnimation(boolean aFlag)
boolean isEnabledAntiAlias()
void setEnabledAntiAlias(boolean flag)
boolean isShowingAxes()
void showAxes(boolean aFlag)
boolean isShowingBackImage()
boolean isShowingBackgroundImage()
void showBackgroundImage(boolean aFlag)
boolean isShowingForegroundImage()
void showForegroundImage(boolean aFlag)
boolean isShowingBndBox()
void showBndBox(boolean aFlag)
boolean isEnabledClip()
void setEnabledClip(boolean aFlag)
boolean isEnabledClipAutoBounds()
void setEnabledClipAutoBounds(boolean aFlag)
boolean isEnabledClipBounds()
void setEnabledClipBounds(boolean aFlag)
boolean isShowingCopyright()
void showCopyright(boolean aFlag)
boolean isShowingDepthcue()
void showDepthcue(boolean aFlag)
boolean isEnabledDoubleBuffer()
void setEnabledDoubleBuffer(boolean flag)
boolean isShowingEdgeAura()
void showEdgeAura(boolean aFlag)
boolean isShowingEdgesOnce()
void showEdgesOnce(boolean aFlag)
boolean isEnabledFillDisplay()
void setEnabledFillDisplay(boolean flag)
boolean isShowingFrame()
void showFrame(boolean aFlag)
boolean isShowingGrid()
void showGrid(boolean aFlag)
PdVector getGridIncrements(int gridOrient)
void setGridIncrements(int gridOrient, PdVector gridIncrements)
gridOrient
- Determines the xy, yz, or xz plane, see PvDisplayIf#GRID_XY.gridIncrements
- Determine the spacing for both gridlines.boolean isEnabledIntegerPick()
void setEnabledIntegerPick(boolean flag)
boolean isShowingMagnet()
void showMagnet(boolean aFlag)
boolean isEnabledPainters()
void setEnabledPainters(boolean aFlag)
boolean isShowingTitle()
void showTitle(boolean aFlag)
boolean isEnabledZBuffer()
void setEnabledZBuffer(boolean flag)
java.awt.Color getBndBoxColor()
void setBndBoxColor(java.awt.Color color)
color
- color of bounding boxdouble getBndBoxSize()
void setBndBoxSize(double size)
size
- thickness of edges bounding boxPdVector getBoxRatio()
void setBoxRatio(PdVector ratio)
ratio
- scaling factors of coordinate axesboolean isEnabledBoxRatio()
void setEnabledBoxRatio(boolean aFlag)
boolean isClip()
#isEnabledClip
void enableClip(boolean aFlag)
#setEnabledClip
double getNearClip()
void setNearClip(double dist)
double getFarClip()
void setFarClip(double dist)
int getClipBoundsType()
void setClipBoundsType(int type)
double[] getClipBounds(int ind)
ind
- index of ruler of axes in which direction is clippedvoid setClipBounds(int ind, double[] range)
ind
- index of ruler of axes in which direction is clippedrange
- minimum and maximum of visible range in axis directionjava.awt.Color getBackgroundColor()
void setBackgroundColor(java.awt.Color aColor)
java.awt.Color getForegroundColor()
void setForegroundColor(java.awt.Color aColor)
java.awt.Image getBackgroundImage()
void setBackgroundImage(java.awt.Image image)
java.lang.String getBackgroundImageFile()
void setBackgroundImageFile(java.lang.String fileName)
fileName
- relative file name of image.java.awt.Image getForegroundImage()
void setForegroundImage(java.awt.Image image)
java.lang.String getForegroundImageFile()
void setForegroundImageFile(java.lang.String fileName)
fileName
- relative file name of image.PvCameraIf getCamera()
PvCameraIf[] getCameras()
PvCameraIf getCamera(int type)
PvCameraIf#CAMERA_PERSPECTIVE
,
PvCameraIf#CAMERA_ORTHO_XY
,
PvCameraIf#CAMERA_ORTHO_XZ
,
PvCameraIf#CAMERA_ORTHO_YZ
,
For a list of possible types see PvDisplayIf
.boolean hasCamera(int type)
PvCameraIf#CAMERA_PERSPECTIVE
,
PvCameraIf#CAMERA_ORTHO_XY
,
PvCameraIf#CAMERA_ORTHO_XZ
,
PvCameraIf#CAMERA_ORTHO_YZ
,
For a list of possible types see PvDisplayIf
.boolean selectCamera(int type)
PvCameraIf#CAMERA_PERSPECTIVE
,
PvCameraIf#CAMERA_ORTHO_XY
,
PvCameraIf#CAMERA_ORTHO_XZ
,
PvCameraIf#CAMERA_ORTHO_YZ
,
For a list of possible types see PvDisplayIf
.boolean removeCamera(int type)
PvCameraIf#CAMERA_PERSPECTIVE
,
PvCameraIf#CAMERA_ORTHO_XY
,
PvCameraIf#CAMERA_ORTHO_XZ
,
PvCameraIf#CAMERA_ORTHO_YZ
,
For a list of possible types see PvDisplayIf
.int getLightingModel()
void setLightingModel(int model)
boolean addLight(PvLightIf light)
light
- new light added to sceneint getNumLights()
PvLightIf getLight()
PvLightIf[] getLights()
boolean hasLight(PvLightIf light)
light
- a light objecttrue
if light is registered.void removeLights()
boolean removeLight(PvLightIf light)
light
- a light objecttrue
if light was found and successfully removed.PvLightIf getSelectedLight()
true
if light was found and successfully selected.boolean selectLight(PvLightIf light)
light
- a light objecttrue
if light was found and successfully selected.PsPanel getCameraPanel()
PsPanel getInfoPanel()
PsPanel getLightPanel()
java.awt.Frame getFrame()
void setFrame(java.awt.Frame frame)
PvViewerIf getViewer()
void setViewer(PvViewerIf viewer)
java.awt.Image getImage()
java.awt.Dimension getSize()
void setSizeWithinFrame(int width, int height)
void clearPopupMenu()
addPopupItem(int)
void addPopupItem(int menuID)
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.
clearPopupMenu()
"