org.jzy3d.plot3d.rendering.view
Class ViewportConfiguration

java.lang.Object
  extended by org.jzy3d.plot3d.rendering.view.ViewportConfiguration

public class ViewportConfiguration
extends Object

A ViewportConfiguration states how a particular GL rendering should occupy a canvas area. It is define by a width and height, and support an X and Y offset

Author:
Martin Pernollet
See Also:
http://www.opengl.org/sdk/docs/man/xhtml/glViewport.xml

Field Summary
protected  int height
           
protected  ViewportMode mode
           
protected  int width
           
protected  int x
           
protected  int y
           
 
Constructor Summary
ViewportConfiguration(ICanvas canvas)
          A viewport configuration that occupies the complete canvas area.
ViewportConfiguration(int width, int height)
           
ViewportConfiguration(int width, int height, int x, int y)
           
 
Method Summary
 int getHeight()
           
 ViewportMode getMode()
           
 int getWidth()
           
 int getX()
           
 int getY()
           
 float ratio()
          computes width/height
 void setHeight(int height)
           
 void setMode(ViewportMode mode)
           
 void setWidth(int width)
           
 void setX(int x)
           
 void setY(int y)
           
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

width

protected int width

height

protected int height

x

protected int x

y

protected int y

mode

protected ViewportMode mode
Constructor Detail

ViewportConfiguration

public ViewportConfiguration(int width,
                             int height)

ViewportConfiguration

public ViewportConfiguration(int width,
                             int height,
                             int x,
                             int y)

ViewportConfiguration

public ViewportConfiguration(ICanvas canvas)
A viewport configuration that occupies the complete canvas area.

Method Detail

getWidth

public int getWidth()

setWidth

public void setWidth(int width)

getHeight

public int getHeight()

setHeight

public void setHeight(int height)

getX

public int getX()

setX

public void setX(int x)

getY

public int getY()

setY

public void setY(int y)

ratio

public float ratio()
computes width/height


getMode

public ViewportMode getMode()

setMode

public void setMode(ViewportMode mode)

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2013. All rights reserved.