Tscope5
|
Definitions of primitives drawing functions. More...
Go to the source code of this file.
Functions | |
Primitives drawing functions | |
The drawing functions all take the smallest possible number of parameters to put something on the screen: some coordinates. Drawing parameters are set with the graphics parameter functions. | |
void | ts5_draw_pixel (double x, double y) |
Draw a pixel. More... | |
TS5_COLOR | ts5_get_pixel_color (double x, double y) |
Get the color of a pixel. More... | |
void | ts5_draw_line (double x1, double y1, double x2, double y2) |
Draw a line segment. More... | |
void | ts5_draw_rectangle (double x1, double y1, double x2, double y2) |
Draw a rectangle. More... | |
void | ts5_draw_rounded_rectangle (double x1, double y1, double x2, double y2, double rx, double ry) |
Draw a rounded rectangle. More... | |
void | ts5_draw_triangle (double x1, double y1, double x2, double y2, double x3, double y3) |
Draw a triangle. More... | |
void | ts5_draw_circle (double cx, double cy, double r) |
Draw a circle. More... | |
void | ts5_draw_ellipse (double cx, double cy, double rx, double ry) |
Draw an ellipse. More... | |
void | ts5_draw_arc (double cx, double cy, double r, double start, double delta) |
Draw an arc. More... | |
Definitions of primitives drawing functions.
Definition in file primitives.c.
void ts5_draw_pixel | ( | double | x, |
double | y | ||
) |
Draw a pixel.
x | Horizontal position of the pixel. |
y | Vertical position of the pixel. |
Definition at line 43 of file primitives.c.
TS5_COLOR ts5_get_pixel_color | ( | double | x, |
double | y | ||
) |
Get the color of a pixel.
x | Horizontal position of the pixel. |
y | Vertical position of the pixel. |
Return value: TS5_COLOR structure.
Definition at line 84 of file primitives.c.
void ts5_draw_line | ( | double | x1, |
double | y1, | ||
double | x2, | ||
double | y2 | ||
) |
Draw a line segment.
x1 | Horizontal position of the start point of the line segment. |
y1 | Vertical position of the start point of the line segment. |
x2 | Horizontal position of the end point of the line segment. |
y2 | Vertical position of the end point of the line segment. |
Definition at line 116 of file primitives.c.
void ts5_draw_rectangle | ( | double | x1, |
double | y1, | ||
double | x2, | ||
double | y2 | ||
) |
Draw a rectangle.
x1 | Horizontal position of the first corner of the rectangle. |
y1 | Vertical position of the first corner of the rectangle. |
x2 | Horizontal position of the second corner of the rectangle. |
y2 | Vertical position of the second corner of the rectangle. |
Definition at line 156 of file primitives.c.
void ts5_draw_rounded_rectangle | ( | double | x1, |
double | y1, | ||
double | x2, | ||
double | y2, | ||
double | rx, | ||
double | ry | ||
) |
Draw a rounded rectangle.
x1 | Horizontal position of the first corner of the rectangle. |
y1 | Vertical position of the first corner of the rectangle. |
x2 | Horizontal position of the second corner of the rectangle. |
y2 | Vertical position of the second corner of the rectangle. |
rx | Horizontal radius of the round. |
ry | Vertical radius of the round. |
Definition at line 206 of file primitives.c.
void ts5_draw_triangle | ( | double | x1, |
double | y1, | ||
double | x2, | ||
double | y2, | ||
double | x3, | ||
double | y3 | ||
) |
Draw a triangle.
x1 | Horizontal position of the first corner of the triangle. |
y1 | Vertical position of the first corner of the triangle. |
x2 | Horizontal position of the second corner of the triangle. |
y2 | Vertical position of the second corner of the triangle. |
x3 | Horizontal position of the third corner of the triangle. |
y3 | Vertical position of the third corner of the triangle. |
Definition at line 285 of file primitives.c.
void ts5_draw_circle | ( | double | cx, |
double | cy, | ||
double | r | ||
) |
Draw a circle.
cx | Horizontal position of the center of the circle. |
cy | Vertical position of the center of the circle. |
r | Radius of the circle. |
Definition at line 339 of file primitives.c.
void ts5_draw_ellipse | ( | double | cx, |
double | cy, | ||
double | rx, | ||
double | ry | ||
) |
Draw an ellipse.
cx | Horizontal position of the center of the ellipse. |
cy | Vertical position of the center of the ellipse. |
rx | Horizontal radius of the ellipse. |
ry | Vertical radius of the ellipse. |
Definition at line 381 of file primitives.c.
void ts5_draw_arc | ( | double | cx, |
double | cy, | ||
double | r, | ||
double | start, | ||
double | delta | ||
) |
Draw an arc.
cx | Horizontal position of the center of the arc. |
cy | Vertical position of the center of the arc. |
r | Radius of the arc. |
start | The initial angle of the arc (0.0 = west, 90.0 = north, ...). |
delta | Span of the arc (positive is counter clockwise, negative is clockwise). |
Definition at line 428 of file primitives.c.