HikoGUI
A low latency retained GUI
Loading...
Searching...
No Matches
Public Member Functions | Friends
tt::rect Class Reference

#include <ttauri/rect.hpp>

Public Member Functions

 rect (rect const &rhs) noexcept=default
 
rectoperator= (rect const &rhs) noexcept=default
 
 rect (rect &&rhs) noexcept=default
 
rectoperator= (rect &&rhs) noexcept=default
 
 rect (f32x4 corner0, f32x4 corner1, f32x4 corner2, f32x4 corner3) noexcept
 
 rect (aarect rhs) noexcept
 
rectoperator= (aarect rhs) noexcept
 
 rect (f32x4 corner0, f32x4 extent) noexcept
 
f32x4 right_vector () const noexcept
 Get the right vector of a rectangle.
 
f32x4 up_vector () const noexcept
 Get the up vector of a rectangle.
 
float width () const noexcept
 
float height () const noexcept
 
f32x4 extent () const noexcept
 
aarect aabb () const noexcept
 
template<size_t I>
f32x4 corner () const noexcept
 Get coordinate of a corner.
 

Friends

rect expand (rect const &lhs, float rhs) noexcept
 

Detailed Description

Class which represents an rectangle.

Member Function Documentation

◆ corner()

template<size_t I>
f32x4 tt::rect::corner ( ) const
inlinenoexcept

Get coordinate of a corner.

Parameters
ICorner number: 0 = left-bottom, 1 = right-bottom, 2 = left-top, 3 = right-top.
Returns
The homogeneous coordinate of the corner.

◆ right_vector()

f32x4 tt::rect::right_vector ( ) const
inlinenoexcept

Get the right vector of a rectangle.

◆ up_vector()

f32x4 tt::rect::up_vector ( ) const
inlinenoexcept

Get the up vector of a rectangle.


The documentation for this class was generated from the following file: