|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IDrawing
This interface contains some basic drawing operations
| Nested Class Summary | |
|---|---|
static class |
IDrawing.AxisR
An enumeration used to specify rotation for drw.rotate() |
| Field Summary |
|---|
| Fields inherited from interface com.azalient.apo.enums.Alignment2D_Constants |
|---|
BOTTOM_CENTRE, BOTTOM_LEFT, BOTTOM_RIGHT, CENTRE_CENTRE, CENTRE_LEFT, CENTRE_RIGHT, TOP_CENTRE, TOP_LEFT, TOP_RIGHT |
| Method Summary | |
|---|---|
void |
arrow(double x,
double y,
double z,
IAngle bearing,
double gradientFrac,
double size,
double move)
Draw an arrow at P(x,y,z) with given gradient, bearing and size. |
void |
arrow(IXyz p,
IAngle bearing,
double gradientFrac,
double size,
double move)
Draw an arrow at P(x,y,z) with given gradient, bearing and size. |
void |
baseTranslate(double x,
double y)
Cache the base tile translation |
void |
begin(int object)
Begin a drawing object , using Open GL object types (GL_POINTS, GL_LINES, ... |
void |
blending(boolean v)
Set alpha-blending (transparency) on or off |
void |
blending(int rgb)
Switch on blending if colour is partially transparent (has alpha component less than 255) |
boolean |
blendingOn()
Return true if alpha-blending (transparency) is currently on |
void |
bounds(OpenGLXyz[] bounds)
|
void |
box(int rgb,
double x,
double y,
double z,
double dx,
double dy,
double dz)
Draw a solid box, with faces parallel to the axes, with lower left corner (x,y,z) and size (dx,dy,dz) |
void |
box(int rgb,
double x,
double y,
double z,
double dx,
double dy,
double dz,
IAngle rotX,
IAngle rotZ)
Draw a solid box, with lower left corner (x,y,z) size (dx,dy,dz), rotated around X and Z axes by given angles |
void |
circle(boolean fill,
double x,
double y,
double z,
double r)
Draw a circle with centre (x,y,z) and radius r. |
void |
circle(boolean fill,
IXyz p,
double r)
Draw a circle with centre P(x,y,z) and radius r |
void |
colour(int rgb)
Set the current drawing colour, using an RGB integer |
void |
colour(NamedColour nc)
Set the current drawing colour |
IPosition |
crossHair()
Return the location, rotation and gradient of the cross-hair cursor |
void |
end()
End the current drawing object |
boolean |
is3D()
Returns false if the view mode is currently set to Flat, and true otherwise |
void |
line(double x1,
double y1,
double z1,
double x2,
double y2,
double z2)
Draw a line between points (x1,y1,z1) and (x2,y2,z2) |
void |
line(double lineWidth,
double x1,
double y1,
double z1,
double x2,
double y2,
double z2)
Draw a line of given lineWidth between points (x1,y1,z1) and (x2,y2,z2) |
void |
line(double lineWidth,
IXyz a,
IXyz b)
Draw a line of given lineWidth between points A and B |
void |
line(IXyz a,
IXyz b)
Draw a line between points A and B |
void |
line(OpenGLXyz a,
OpenGLXyz b)
Draw a line between points A and B |
void |
linewidth(double width)
Set the current drawing line width, in pixels |
OpenGL |
openGL()
A handle to an abstraction layer for low-level OpenGL drawing operations |
void |
pixels(double x,
double y,
double z,
int w,
int h,
int[] pixels)
(Advanced) Draw the given raster map of (width x height) pixels at point (x,y,z) |
void |
popMatrix()
Pop the most recent transform matrix from the stack. |
void |
popMatrixBaseTranslate()
Resume use of the cached base tile translation |
void |
pushMatrix()
Create a new transform matrix and push it onto the stack. |
void |
pushMatrixBaseTranslate(double x,
double y,
double z)
Temporarily suspend use of the cached base tile translation |
void |
pushMatrixBaseTranslate(IXyz p)
Temporarily suspend use of the cached base tile translation |
void |
pushMatrixBaseTranslate(IXyz p,
double z)
Temporarily suspend use of the cached base tile translation |
void |
rectangle(boolean fill,
double x1,
double y1,
double z1,
double x2,
double y2,
double z2)
Draw a rectangle aligned with the X-Y axes, with lower-left corner (x1,y1,z1) and upper right corner (x2,y2,z2) |
void |
rectangle(boolean fill,
IXyz p1,
IXyz p2)
Draw a rectangle aligned with the X-Y axes, with lower-left corner P1 and upper right P2 |
void |
registerDrawable(IDrawable d)
Register this drawable with the system, so that it will be drawn as part of the screen update |
void |
rotate(double degrees,
IDrawing.AxisR axis)
Rotate the view around the given axis, by the given angle, in degrees |
void |
rotateX(IAngle a)
Rotate the view around the X axis, by the given angle |
void |
rotateY(IAngle a)
Rotate the view around the Y axis, by the given angle |
void |
rotateZ(IAngle a)
Rotate the view around the Z axis, by the given angle |
void |
scale(double sx,
double sy,
double sz)
Scale the current view by vector (sx, sy, sz) |
void |
scale(IXyz scale)
Scale the current view by vector (x,y,z) |
ISelections |
selections()
A handle to any currently selected objects |
void |
string(String s,
double x,
double y,
double z,
double h)
Draw a ground-parallel string using the current polygon vector font, centred on (x,y,z), with text height h. |
void |
stringBitmap(String s,
double x,
double y,
double z,
Alignment2D a2d)
Draw a ground-parallel string, using a raster bitmap font, with given alignment to point (x,y,z) |
void |
stringBitmap(String s,
IXyz p,
Alignment2D a2d)
Draw a ground-parallel string, using a raster bitmap font, with given alignment to point P |
void |
stringPolygon(String s,
double x,
double y,
double z,
double h,
Alignment2D a2d)
Draw a ground-parallel string, using the current polygon vector font, of height h, with given alignment to point (x,y,z) |
void |
stringPolygon(String s,
IXyz p,
double h,
Alignment2D a2d)
Draw a ground-parallel string, using the current polygon vector font, of height h, with given alignment to point P |
int |
texbind(int w,
int h,
int[] pixels)
(Advanced) Bind the given rectangle of pixel data to a new texture, and return the texture ID. |
void |
texmap(int textureID,
double x,
double y,
double z,
double x2,
double y2)
(Advanced) Map the given texture (by ID) to the XY-plane rectangle specified by (x,y,z) and (x2,y2,z) |
void |
translate(double tx,
double ty,
double tz)
Translate the current view by vector (tx,ty,tz) |
void |
translate(IXyz translation)
Translate the current view by vector (x,y,z) |
void |
translateZ(double z)
Translate the current view along the z-axis |
void |
triangle(boolean fill,
IXyz p1,
IXyz p2,
IXyz p3)
Draw a triangle with corners P1, P2, P3 |
void |
unregisterDrawable(IDrawable d)
Unregister this drawable, removing it from the list of drawables |
void |
vertex(double x,
double y,
double z)
Add a vertex in a drawn object, must be called between begin() and end() |
void |
vertex(IXyz p)
Add a vertex in a drawn object, must be called between begin() and end() |
IPosition |
viewPoint()
Return the location, rotation and gradient of the viewpoint. |
IViewport |
viewport()
A handle to the viewport object, which can be used to query the current viewpoint, zoom height, tilt angle etc. |
int |
windowHeight()
Return the current height (Y-direction) of the drawing pane, in pixels |
int |
windowWidth()
Return the current width (X-direction) of the drawing pane, in pixels |
| Method Detail |
|---|
ISelections selections()
IViewport viewport()
OpenGL openGL()
boolean is3D()
void circle(boolean fill,
double x,
double y,
double z,
double r)
void circle(boolean fill,
IXyz p,
double r)
void rectangle(boolean fill,
double x1,
double y1,
double z1,
double x2,
double y2,
double z2)
void rectangle(boolean fill,
IXyz p1,
IXyz p2)
void triangle(boolean fill,
IXyz p1,
IXyz p2,
IXyz p3)
triangle in interface IDrawingCapture
void line(IXyz a,
IXyz b)
void line(OpenGLXyz a,
OpenGLXyz b)
void line(double x1,
double y1,
double z1,
double x2,
double y2,
double z2)
void line(double lineWidth,
IXyz a,
IXyz b)
void line(double lineWidth,
double x1,
double y1,
double z1,
double x2,
double y2,
double z2)
void arrow(double x,
double y,
double z,
IAngle bearing,
double gradientFrac,
double size,
double move)
void arrow(IXyz p,
IAngle bearing,
double gradientFrac,
double size,
double move)
void box(int rgb,
double x,
double y,
double z,
double dx,
double dy,
double dz)
void box(int rgb,
double x,
double y,
double z,
double dx,
double dy,
double dz,
IAngle rotX,
IAngle rotZ)
void linewidth(double width)
void string(String s,
double x,
double y,
double z,
double h)
void stringPolygon(String s,
double x,
double y,
double z,
double h,
Alignment2D a2d)
void stringPolygon(String s,
IXyz p,
double h,
Alignment2D a2d)
stringPolygon in interface IDrawingCapture
void stringBitmap(String s,
double x,
double y,
double z,
Alignment2D a2d)
void stringBitmap(String s,
IXyz p,
Alignment2D a2d)
int windowWidth()
int windowHeight()
void pixels(double x,
double y,
double z,
int w,
int h,
int[] pixels)
int texbind(int w,
int h,
int[] pixels)
void texmap(int textureID,
double x,
double y,
double z,
double x2,
double y2)
IPosition crossHair()
IPosition viewPoint()
void begin(int object)
begin in interface IDrawingCaptureOpenGL_Constantsvoid end()
end in interface IDrawingCapturevoid vertex(IXyz p)
vertex in interface IDrawingCapture
void vertex(double x,
double y,
double z)
vertex in interface IDrawingCapturevoid colour(NamedColour nc)
colour in interface IDrawingCapturevoid colour(int rgb)
colour in interface IDrawingCapturevoid popMatrix()
popMatrix in interface IDrawingCapturevoid pushMatrix()
pushMatrix in interface IDrawingCapturevoid rotateX(IAngle a)
void rotateY(IAngle a)
void rotateZ(IAngle a)
rotateZ in interface IDrawingCapture
void rotate(double degrees,
IDrawing.AxisR axis)
void scale(IXyz scale)
void translate(IXyz translation)
void translateZ(double z)
void scale(double sx,
double sy,
double sz)
scale in interface IDrawingCapture
void translate(double tx,
double ty,
double tz)
translate in interface IDrawingCapture
void baseTranslate(double x,
double y)
void pushMatrixBaseTranslate(IXyz p)
void pushMatrixBaseTranslate(IXyz p,
double z)
void pushMatrixBaseTranslate(double x,
double y,
double z)
void popMatrixBaseTranslate()
void bounds(OpenGLXyz[] bounds)
void blending(int rgb)
void blending(boolean v)
boolean blendingOn()
void registerDrawable(IDrawable d)
void unregisterDrawable(IDrawable d)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||