From bc5375149c0ecb416848a2d3657ea41ae97177b3 Mon Sep 17 00:00:00 2001 From: Fox Caminiti Date: Wed, 10 Aug 2022 21:24:03 -0400 Subject: path rasterization started with opengl --- my_math.h | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) (limited to 'my_math.h') diff --git a/my_math.h b/my_math.h index b95e71d..cf491f1 100644 --- a/my_math.h +++ b/my_math.h @@ -46,6 +46,16 @@ inline v2 V2(real32 x, real32 y) return(Result); } +inline v2 V2(real32 x) +{ + v2 Result; + + Result.x = x; + Result.y = x; + + return(Result); +} + inline v2 V2(ImVec2 A) { v2 Result; @@ -186,6 +196,18 @@ v2i operator+(v2i A, v2i B) return(Result); } +v2 operator/(v2 A, real32 B) +{ + v2 Result; + + Result.x = A.x / B; + Result.y = A.y / B; + + return Result; +} + + + v4 operator+(v4 A, v4 B) { v4 Result; -- cgit v1.2.3