Flutter Engine
The Flutter Engine
Public Member Functions | Public Attributes | List of all members
bentleyottmann::Segment Struct Reference

#include <Segment.h>

Public Member Functions

Point upper () const
 
Point lower () const
 
std::tuple< int32_t, int32_t, int32_t, int32_t > bounds () const
 

Public Attributes

Point p0
 
Point p1
 

Detailed Description

Definition at line 15 of file Segment.h.

Member Function Documentation

◆ bounds()

std::tuple< int32_t, int32_t, int32_t, int32_t > bentleyottmann::Segment::bounds ( ) const

Definition at line 25 of file Segment.cpp.

25 {
26 auto [l, r] = std::minmax(p0.x, p1.x);
27 auto [t, b] = std::minmax(p0.y, p1.y);
28 return std::make_tuple(l, t, r, b);
29}
static bool b

◆ lower()

Point bentleyottmann::Segment::lower ( ) const

Definition at line 20 of file Segment.cpp.

20 {
21 return std::max(p0, p1);
22}
static float max(float r, float g, float b)
Definition: hsl.cpp:49

◆ upper()

Point bentleyottmann::Segment::upper ( ) const

Definition at line 16 of file Segment.cpp.

16 {
17 return std::min(p0, p1);
18}
static float min(float r, float g, float b)
Definition: hsl.cpp:48

Member Data Documentation

◆ p0

Point bentleyottmann::Segment::p0

Definition at line 16 of file Segment.h.

◆ p1

Point bentleyottmann::Segment::p1

Definition at line 17 of file Segment.h.


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