Module libif:gfxprim - Graphics windowing system primitives library
Graphics windowing system primitives library. This provides a variety of drawing primitives that can be used to draw on rasters. To use:
#INCLUDE "gfxproto.inc"
For static modules:
#USE "libif/gfxprim"
For dynamic modules:
#INCLUDE "gfxwin_if.inc"
Index
-
Process
gfxprim.circle.fill- Draws a solid circle -
Process
gfxprim.ellipse.fill- Draws a solid ellipse -
Process
gfxprim.flood.fill- Performs a flood-fill within an area -
Process
gfxprim.line- Draws a line -
Process
gfxprim.line.noclip- Draws a line -
Process
gfxprim.rectangle- Draws a rectangle outline (unfilled) -
Process
gfxprim.rectangle.fill- Draws a solid rectangle -
Process
gfxprim.rectangle.noclip- Draws a rectangle outline (unfilled) -
Process
gfxprim.square.fill- Draws a solid square
Declarations
gfxprim.occ:65Process gfxprim.rectangle.fill
PROC gfxprim.rectangle.fill (VAL INT x0, y0, width, height, VAL INT32 colour, [][]INT32 raster)
Draws a solid rectangle. Clips as necessary.
Parameters:
VAL INT |
x0, y0
|
Top left corner. |
VAL INT |
width |
Width. |
VAL INT |
height |
Height. |
VAL INT32 |
colour |
Colour. |
[][]INT32 |
raster |
Raster to draw on. |
gfxprim.occ:82Process gfxprim.rectangle
PROC gfxprim.rectangle (VAL INT x0, y0, width, height, VAL INT32 colour, [][]INT32 raster)
Draws a rectangle outline (unfilled). Clips as necessary.
Parameters:
VAL INT |
x0, y0
|
Top left corner. |
VAL INT |
width |
Width. |
VAL INT |
height |
Height. |
VAL INT32 |
colour |
Colour. |
[][]INT32 |
raster |
Raster to draw on. |
gfxprim.occ:104Process gfxprim.rectangle.noclip
PROC gfxprim.rectangle.noclip (VAL INT x0, y0, width, height, VAL INT32 colour, [][]INT32 raster)
Draws a rectangle outline (unfilled). Doesn't do any clipping.
Parameters:
VAL INT |
x0, y0
|
Top left corner. |
VAL INT |
width |
Width. |
VAL INT |
height |
Height. |
VAL INT32 |
colour |
Colour. |
[][]INT32 |
raster |
Raster to draw on. |
gfxprim.occ:124Process gfxprim.square.fill
PROC gfxprim.square.fill (VAL INT x0, y0, size, VAL INT32 colour, [][]INT32 raster)
Draws a solid square. Clips as necessary.
Parameters:
VAL INT |
x0, y0
|
Top left corner. |
VAL INT |
size |
Size of square. |
VAL INT32 |
colour |
Colour. |
[][]INT32 |
raster |
Raster to draw on. |
gfxprim.occ:137Process gfxprim.circle.fill
PROC gfxprim.circle.fill (VAL INT x, y, r, VAL INT32 colour, [][]INT32 raster)
Draws a solid circle. Clips as necessary.
Parameters:
VAL INT |
x, y
|
Coordinates of centre. |
VAL INT |
r |
Radius. |
VAL INT32 |
colour |
Colour. |
[][]INT32 |
raster |
Raster. |
gfxprim.occ:154Process gfxprim.ellipse.fill
PROC gfxprim.ellipse.fill (VAL INT x, y, xrad, yrad, VAL INT32 colour, [][]INT32 raster)
Draws a solid ellipse. Clips as necessary.
Parameters:
VAL INT |
x, y
|
Centre of ellipse. |
VAL INT |
xrad |
X radius. |
VAL INT |
yrad |
Y radius. |
VAL INT32 |
colour |
Fill colour. |
[][]INT32 |
raster |
Raster to draw on. |
gfxprim.occ:171Process gfxprim.line
PROC gfxprim.line (VAL INT x0, y0, x1, y1, VAL INT32 colour, [][]INT32 raster)
Draws a line. Clips as necessary.
Parameters:
VAL INT |
x0, y0
|
Start point of line. |
VAL INT |
x1, y1
|
End point of line. |
VAL INT32 |
colour |
Line colour. |
[][]INT32 |
raster |
Raster to draw on. |
gfxprim.occ:188Process gfxprim.line.noclip
PROC gfxprim.line.noclip (VAL INT x0, y0, x1, y1, VAL INT32 colour, [][]INT32 raster)
Draws a line. Doesn't do any clipping.
Parameters:
VAL INT |
x0, y0
|
Start point of line. |
VAL INT |
x1, y1
|
End point of line. |
VAL INT32 |
colour |
Line colour. |
[][]INT32 |
raster |
Raster to draw on. |
gfxprim.occ:203Process gfxprim.flood.fill
PROC gfxprim.flood.fill (VAL INT x0, y0, VAL INT32 colour, [][]INT32 raster)
Performs a flood-fill within an area.
Parameters:
VAL INT |
x0, y0
|
Start position of fill. |
VAL INT32 |
colour |
Fill colour. |
[][]INT32 |
raster |
Raster to draw on. |