Send textbox rectangle and textbox type to SDL

This commit is contained in:
Yousef Khadadeh 2026-03-05 23:34:30 +03:00
parent d38156ec26
commit f3671e667d
8 changed files with 179 additions and 32 deletions

View file

@ -6,6 +6,7 @@
#include <iostream>
#include <ostream>
#include <Eigen/Geometry>
#include <SDL3/SDL_rect.h>
using namespace Eigen;
@ -76,6 +77,9 @@ namespace SCollision {
template <class Archive> void serialize(Archive& a) {
a(min, max);
}
SDL_Rect get_sdl_rect() const {
return SDL_Rect{static_cast<int>(min.x()), static_cast<int>(min.y()), static_cast<int>(width()), static_cast<int>(height())};
}
};
template <typename T> class Circle {
public: