Outline Polygon
All checks were successful
Run ReCI Build Test / Explore-Gitea-Actions (push) Successful in 5m8s

This commit is contained in:
2024-08-22 11:55:56 -04:00
parent c0b65818c8
commit 1d8823b046
3 changed files with 46 additions and 32 deletions

View File

@@ -121,7 +121,7 @@ namespace JGL {
const Color4& color = Colors::White,
Inversion inversion = Inversion::None);
///Draws a piece of a sprite to the screen, similar to DrawSprite.
/// Draws a piece of a sprite to the screen, similar to DrawSprite.
/// @param texture
/// @param position
/// @param sub_texture_position The top left corner of the sub-texture to be drawn.
@@ -215,8 +215,9 @@ namespace JGL {
int subdivisions = 10,
float thickness = 1);
void OutlinePolygon (const Color4& color, std::vector<Vector2> points);
void FillPolygon (const Color4& color, std::vector<Vector2> points, float thickness = 1);
/// Draws a series of lines where the last line will *always* connect to the beginning of the first.
void OutlinePolygon (const Color4& color, const std::vector<Vector2>& points, float thickness = 1);
void FillPolygon (const Color4& color, std::vector<Vector2> points);
void OutlineRoundedRect(const Color4& color, const Vector2& pos, const Vector2& size, float radius = 5, float thickness = 1);
}