Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/wolfpld/tracy.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRokas Kupstys <rokups@zoho.com>2018-07-17 15:58:31 +0300
committerRokas Kupstys <rokups@zoho.com>2018-07-17 16:37:45 +0300
commit064385fc628e01ce33676f782e54a40178d48568 (patch)
treeb5afe6f959a439d4f2ad4ae53b7496b581818c03 /server/TracyImGui.hpp
parent3799e0da4326134622b8477b8ffefffb0a849dc9 (diff)
Define ImVec2 math operators only when IMGUI_DEFINE_MATH_OPERATORS is undefined.
Diffstat (limited to 'server/TracyImGui.hpp')
-rw-r--r--server/TracyImGui.hpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/server/TracyImGui.hpp b/server/TracyImGui.hpp
index 02554192..2d486185 100644
--- a/server/TracyImGui.hpp
+++ b/server/TracyImGui.hpp
@@ -4,7 +4,9 @@
#include "../imgui/imgui.h"
#include "../imgui/imgui_internal.h"
+#if !IMGUI_DEFINE_MATH_OPERATORS
static inline ImVec2 operator+( const ImVec2& l, const ImVec2& r ) { return ImVec2( l.x + r.x, l.y + r.y ); }
static inline ImVec2 operator-( const ImVec2& l, const ImVec2& r ) { return ImVec2( l.x - r.x, l.y - r.y ); }
+#endif
#endif