mirror of
https://github.com/korenkonder/ReDIVA.git
synced 2026-10-12 17:18:10 +03:00
29 lines
488 B
C++
29 lines
488 B
C++
/*
|
|
by korenkonder
|
|
GitHub/GitLab: korenkonder
|
|
*/
|
|
|
|
#pragma once
|
|
|
|
#include "default.hpp"
|
|
#include "vec.hpp"
|
|
|
|
struct rectangle {
|
|
vec2 pos;
|
|
vec2 size;
|
|
|
|
inline rectangle() : pos(), size() {
|
|
|
|
}
|
|
|
|
inline rectangle(vec2 pos, vec2 size) {
|
|
this->pos = pos;
|
|
this->size = size;
|
|
}
|
|
|
|
inline rectangle(float_t pos_x, float_t pos_y, float_t size_x, float_t size_y) {
|
|
this->pos = { pos_x, pos_y };
|
|
this->size = { size_x, size_y };
|
|
}
|
|
};
|