From c055eeef6d41269d11b2ddf7f9aba6f8867da65d Mon Sep 17 00:00:00 2001 From: Nikita Kostovsky Date: Tue, 23 Dec 2025 15:28:05 +0100 Subject: initial commit --- core/src/cpp/size2d.h | 15 +++++++++++++++ 1 file changed, 15 insertions(+) create mode 100644 core/src/cpp/size2d.h (limited to 'core/src/cpp/size2d.h') diff --git a/core/src/cpp/size2d.h b/core/src/cpp/size2d.h new file mode 100644 index 0000000..1d12307 --- /dev/null +++ b/core/src/cpp/size2d.h @@ -0,0 +1,15 @@ +#pragma once + +template struct size2d +{ + T w{0}; + T h{0}; + + inline size2d operator/(const size2d& other); +}; + +template +inline size2d size2d::operator/(const size2d& other) +{ + return {w / other.w, h / other.h}; +} -- cgit v1.2.3-70-g09d2