Ember
A C++ 20 'game engine' built with SDL3 with wide platform support.
Public Member Functions | Public Attributes | List of all members
Rect2 Struct Reference

Float rectangle struct. More...

#include <engine_structs.h>

Public Member Functions

 Rect2 ()
 
 Rect2 (float x, float y, float width, float height)
 
bool is_zero () const
 
glm::vec2 top_left () const
 
glm::vec2 bottom_right () const
 

Public Attributes

float x
 
float y
 
float width
 
float height
 

Detailed Description

Float rectangle struct.

Version
0.0.1

Constructor & Destructor Documentation

◆ Rect2() [1/2]

Rect2::Rect2 ( )
inline

◆ Rect2() [2/2]

Rect2::Rect2 ( float  x,
float  y,
float  width,
float  height 
)
inline

Member Function Documentation

◆ bottom_right()

glm::vec2 Rect2::bottom_right ( ) const

◆ is_zero()

bool Rect2::is_zero ( ) const

◆ top_left()

glm::vec2 Rect2::top_left ( ) const

Member Data Documentation

◆ height

float Rect2::height

◆ width

float Rect2::width

◆ x

float Rect2::x

◆ y

float Rect2::y

The documentation for this struct was generated from the following files: