org.jzy3d.plot3d.rendering.view
Class AbstractViewportManager
- java.lang.Object
-
- org.jzy3d.plot3d.rendering.view.AbstractViewportManager
-
- Direct Known Subclasses:
- AWTImageViewport, Camera
public abstract class AbstractViewportManager extends java.lang.ObjectAnAbstractViewportManagerdescribes an element that occupies the whole renderingICanvasor only a vertical slice of it. TheAbstractViewportManageralso provides a utility function for debugging the slices, that is the ability to display a 10*10 grid for checking the space occupied by the actual viewport definition.
-
-
Constructor Summary
Constructors Constructor and Description AbstractViewportManager()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method and Description ViewportConfigurationgetLastViewPort()ViewportModegetMode()RectanglegetRectangle()Returns the (x,y) offset that was applied to make thisAbstractViewportManagerstand in the appropriate canvas part.voidsetScreenGridDisplayed(boolean status)Set the status of the screen grid.voidsetViewPort(int width, int height)Set the view port (size of the renderer).voidsetViewPort(int width, int height, float left, float right)Set the view port (size of the renderer).voidsetViewPort(ViewportConfiguration viewport)voidsetViewportMode(ViewportMode mode)
-
-
-
Method Detail
-
setViewPort
public void setViewPort(int width, int height)Set the view port (size of the renderer).- Parameters:
width- the width of the target window.height- the height of the target window.
-
getMode
public ViewportMode getMode()
-
setViewportMode
public void setViewportMode(ViewportMode mode)
-
setViewPort
public void setViewPort(int width, int height, float left, float right)Set the view port (size of the renderer).- Parameters:
width- the width of the target window.height- the height of the target window.left- the width's ratio where this subscreen starts in the target window.right- the width's ratio where this subscreen stops in the target window.- Throws:
an- IllegalArgumentException if right is not greater than left.
-
setViewPort
public void setViewPort(ViewportConfiguration viewport)
-
getLastViewPort
public ViewportConfiguration getLastViewPort()
-
getRectangle
public Rectangle getRectangle()
Returns the (x,y) offset that was applied to make thisAbstractViewportManagerstand in the appropriate canvas part. and the actual width and height of the viewport. Only relevant after a call toapplyViewPort.
-
setScreenGridDisplayed
public void setScreenGridDisplayed(boolean status)
Set the status of the screen grid.- Parameters:
status- the grid is displayed if status is set to true
-
-
DMelt 3.0 © DataMelt by jWork.ORG