public class Motor3D
extends java.lang.Object
Constructor | Description |
---|---|
Motor3D(G2DCanvas canvas,
java.awt.Graphics2D g2d,
java.awt.Dimension dim) |
Default constructor
|
Modifier and Type | Method | Description |
---|---|---|
void |
clearDepth() |
Clear the depth buffer
|
void |
draw() |
Draw the scene in the Graphics2D
|
void |
draw(DrawingTools drawingTools,
Geometry geometry,
Appearance appearance) |
Add the geometry to the scene
|
void |
draw(DrawingTools drawingTools,
Texture texture,
AnchorPosition anchor,
ElementsBuffer positions,
double rotationAngle) |
|
void |
draw(DrawingTools drawingTools,
Texture texture,
AnchorPosition anchor,
Vector3d position,
double rotationAngle) |
|
void |
drawTexture(DrawingTools drawingTools,
java.awt.image.BufferedImage image,
Texture texture) |
|
Transformation |
getCurrentSingleTransformation() |
|
Transformation |
getCurrentTransformation() |
|
boolean |
is2DView() |
|
void |
reset(java.awt.Color color) |
Reset this motor
|
void |
setAntialiased(boolean aa) |
|
void |
setClippingPlanes(java.util.List<ClippingPlane> clippingPlanes) |
|
void |
setFaceCullingMode(Geometry.FaceCullingMode mode) |
Set the face culling mode
|
void |
setGraphics(java.awt.Graphics2D g2d) |
|
void |
setTransformation(Transformation transf,
Transformation single) |
Set the current transformation
|
public Motor3D(G2DCanvas canvas, java.awt.Graphics2D g2d, java.awt.Dimension dim)
g2d
- a Graphics2D object where to drawdim
- the graphic dimensionspublic void setGraphics(java.awt.Graphics2D g2d)
public void setAntialiased(boolean aa)
public boolean is2DView()
public void setClippingPlanes(java.util.List<ClippingPlane> clippingPlanes)
public void setFaceCullingMode(Geometry.FaceCullingMode mode)
mode
- the mode to setpublic void setTransformation(Transformation transf, Transformation single)
transf
- the transformation to setpublic Transformation getCurrentTransformation()
public Transformation getCurrentSingleTransformation()
public void reset(java.awt.Color color)
color
- the filling colorpublic void clearDepth()
public void draw()
public void drawTexture(DrawingTools drawingTools, java.awt.image.BufferedImage image, Texture texture)
public void draw(DrawingTools drawingTools, Geometry geometry, Appearance appearance)
drawingTools
- the DrawingToolsgeometry
- the geometry to drawappearance
- the appearance to usepublic void draw(DrawingTools drawingTools, Texture texture, AnchorPosition anchor, ElementsBuffer positions, double rotationAngle)
public void draw(DrawingTools drawingTools, Texture texture, AnchorPosition anchor, Vector3d position, double rotationAngle)