natiny_render_line
void natiny_render_line(float x0, float y0, float x1, float y1, float thickness);
Draws a line segment on the currently bound render target, using the current drawing color set by natiny_render_set_color().
Parameters
| Name | Type | Description |
|---|---|---|
x0 |
float |
Start X position |
y0 |
float |
Start Y position |
x1 |
float |
End X position |
y1 |
float |
End Y position |
thickness |
float |
Line thickness in pixels |
Example
natiny_render_line(40.0f, 40.0f, 220.0f, 140.0f, 2.0f);