diff options
Diffstat (limited to 'debug.h')
-rw-r--r-- | debug.h | 32 |
1 files changed, 18 insertions, 14 deletions
@@ -15,18 +15,18 @@ union debugval { int32 i; }; -struct project_debug +// things that get cleared every frame with the UI +struct debug_temp { - uint32 Markers[8]; - uint32 MarkerIndex = 0; - uint64 CycleCount[8]; - uint64 EndCycleCount[8]; - uint64 ExecutionAmount[8]; - valtype DebugPropertyType[16]; debugval Val[16]; char *String[16]; uint32 WatchedProperties; +}; + +struct project_debug +{ + debug_temp Temp; bool32 ToggleWindow; }; @@ -42,16 +42,16 @@ static project_debug Debug; static void DebugWatchVar(char *Name, void *Address, valtype Type) { - uint32 i = Debug.WatchedProperties; - Debug.String[i] = Name; + uint32 i = Debug.Temp.WatchedProperties; + Debug.Temp.String[i] = Name; if (Type == d_float) - Debug.Val[i].f = *(real32 *)Address; + Debug.Temp.Val[i].f = *(real32 *)Address; if (Type == d_uint) - Debug.Val[i].u = *(uint32 *)Address; + Debug.Temp.Val[i].u = *(uint32 *)Address; if (Type == d_int) - Debug.Val[i].i = *(int32 *)Address; - Debug.DebugPropertyType[i] = Type; - Debug.WatchedProperties++; + Debug.Temp.Val[i].i = *(int32 *)Address; + Debug.Temp.DebugPropertyType[i] = Type; + Debug.Temp.WatchedProperties++; } #else @@ -64,6 +64,10 @@ enum valtype { union debugval { }; +struct debug_temp +{ +}; + struct project_debug { }; |