From d6e916319a050070c53eb283470a3fd4833392a0 Mon Sep 17 00:00:00 2001 From: Fox Caminiti Date: Fri, 27 Jan 2023 18:36:05 -0500 Subject: corner scaling --- src/include/all.h | 2 ++ src/include/my_math.h | 6 ++++++ 2 files changed, 8 insertions(+) (limited to 'src/include') diff --git a/src/include/all.h b/src/include/all.h index 9d7fe77..e2a2a2f 100644 --- a/src/include/all.h +++ b/src/include/all.h @@ -507,6 +507,8 @@ Transform_Recurse(project_state *State, memory *Memory, block_composition *MainC sorted_comp_array *SortedCompArray, sorted_layer_array *SortedLayerArray, real32 *MinX, real32 *MinY, real32 *MaxX, real32 *MaxY); +static bool32 +Layer_TestForPoint(memory *Memory, project_state *State, ui *UI, sorted_comp_array *SortedCompArray, sorted_layer_array *SortedLayerArray, uint16 PrincipalIndex, v2 CompUV); static v2 TransformPoint(layer_transforms T, real32 Width, real32 Height, v2 Point); diff --git a/src/include/my_math.h b/src/include/my_math.h index 938ed3c..ed26bc8 100644 --- a/src/include/my_math.h +++ b/src/include/my_math.h @@ -576,6 +576,12 @@ Length(v2 A) return sqrt(Inner(A, A)); } +inline real32 +Length(ImVec2 A) +{ + return sqrt(Inner(A, A)); +} + inline uint32 Floor(uint32 A, uint32 B) { -- cgit v1.2.3