Direct-BT v3.3.0-1-gc2d430c
Direct-BT - Direct Bluetooth Programming.
Public Member Functions | Public Attributes | List of all members
jau::math::geom::Disk2f Class Reference

#include <geom2f.hpp>

Inheritance diagram for jau::math::geom::Disk2f:
Collaboration diagram for jau::math::geom::Disk2f:

Public Member Functions

 Disk2f (const Point2f &c_, const float r_)
 
 Disk2f (float x, float y, const float r_)
 
AABBox2f box () const noexcept override
 
bool contains (const Point2f &o) const noexcept override
 
bool intersection (Vec2f &reflect_out, Vec2f &cross_normal, Point2f &cross_point, const LineSeg2f &in) const noexcept override
 Return whether this object intersects with the given line segment and if intersecting, the crossing point (intersection), the normalized normal of the crossing surface and the reflection out vector. More...
 
bool intersects (const AABBox2f &o) const noexcept override
 
bool intersects (const Geom2f &o) const noexcept override
 
bool intersects (const LineSeg2f &o) const noexcept override
 
void move (const float dx, const float dy) noexcept override
 
void move (const Point2f &d) noexcept override
 
void move_dir (const float d) noexcept override
 
void rotate (const float rad) noexcept override
 
void set_center (const Point2f &p)
 
std::string toString () const noexcept override
 
- Public Member Functions inherited from jau::math::geom::AGeom2f
virtual void move (const float dx, const float dy) noexcept=0
 
virtual void move (const Point2f &d) noexcept=0
 
virtual void move_dir (const float d) noexcept=0
 
virtual void rotate (const float rad) noexcept=0
 
virtual bool tick (const float dt) noexcept
 
- Public Member Functions inherited from jau::math::geom::Geom2f
virtual ~Geom2f ()=default
 
virtual AABBox2f box () const noexcept=0
 
virtual bool contains (const Point2f &o) const noexcept=0
 
virtual bool intersection (Vec2f &reflect_out, Vec2f &cross_normal, Point2f &cross_point, const LineSeg2f &in) const noexcept=0
 Return whether this object intersects with the given line segment and if intersecting, the crossing point (intersection), the normalized normal of the crossing surface and the reflection out vector. More...
 
virtual bool intersects (const AABBox2f &box) const noexcept=0
 
virtual bool intersects (const Geom2f &o) const noexcept=0
 
virtual bool intersects (const LineSeg2f &o) const noexcept=0
 
virtual std::string toString () const noexcept=0
 

Public Attributes

Point2f center
 Imagine a circle ;-) More...
 
float dir_angle
 direction angle in radians More...
 
float radius
 

Detailed Description

Definition at line 466 of file geom2f.hpp.

Constructor & Destructor Documentation

◆ Disk2f() [1/2]

jau::math::geom::Disk2f::Disk2f ( const Point2f c_,
const float  r_ 
)
inline

Definition at line 484 of file geom2f.hpp.

◆ Disk2f() [2/2]

jau::math::geom::Disk2f::Disk2f ( float  x,
float  y,
const float  r_ 
)
inline

Definition at line 487 of file geom2f.hpp.

Member Function Documentation

◆ toString()

std::string jau::math::geom::Disk2f::toString ( ) const
inlineoverridevirtualnoexcept

Implements jau::math::geom::Geom2f.

Definition at line 490 of file geom2f.hpp.

◆ set_center()

void jau::math::geom::Disk2f::set_center ( const Point2f p)
inline

Definition at line 495 of file geom2f.hpp.

◆ box()

AABBox2f jau::math::geom::Disk2f::box ( ) const
inlineoverridevirtualnoexcept

Implements jau::math::geom::Geom2f.

Definition at line 499 of file geom2f.hpp.

◆ contains()

bool jau::math::geom::Disk2f::contains ( const Point2f o) const
inlineoverridevirtualnoexcept

Implements jau::math::geom::Geom2f.

Definition at line 505 of file geom2f.hpp.

◆ intersects() [1/3]

bool jau::math::geom::Disk2f::intersects ( const LineSeg2f o) const
inlineoverridevirtualnoexcept

Implements jau::math::geom::Geom2f.

Definition at line 510 of file geom2f.hpp.

◆ intersects() [2/3]

bool jau::math::geom::Disk2f::intersects ( const AABBox2f o) const
inlineoverridevirtualnoexcept

Implements jau::math::geom::Geom2f.

Definition at line 514 of file geom2f.hpp.

◆ intersects() [3/3]

bool jau::math::geom::Disk2f::intersects ( const Geom2f o) const
inlineoverridevirtualnoexcept

Implements jau::math::geom::Geom2f.

Definition at line 518 of file geom2f.hpp.

◆ intersection()

bool jau::math::geom::Disk2f::intersection ( Vec2f reflect_out,
Vec2f cross_normal,
Point2f cross_point,
const LineSeg2f in 
) const
inlineoverridevirtualnoexcept

Return whether this object intersects with the given line segment and if intersecting, the crossing point (intersection), the normalized normal of the crossing surface and the reflection out vector.

Implements jau::math::geom::Geom2f.

Definition at line 522 of file geom2f.hpp.

◆ rotate()

void jau::math::geom::Disk2f::rotate ( const float  rad)
inlineoverridevirtualnoexcept

Implements jau::math::geom::AGeom2f.

Definition at line 536 of file geom2f.hpp.

◆ move_dir()

void jau::math::geom::Disk2f::move_dir ( const float  d)
inlineoverridevirtualnoexcept

Implements jau::math::geom::AGeom2f.

Definition at line 540 of file geom2f.hpp.

◆ move() [1/2]

void jau::math::geom::Disk2f::move ( const Point2f d)
inlineoverridevirtualnoexcept

Implements jau::math::geom::AGeom2f.

Definition at line 546 of file geom2f.hpp.

◆ move() [2/2]

void jau::math::geom::Disk2f::move ( const float  dx,
const float  dy 
)
inlineoverridevirtualnoexcept

Implements jau::math::geom::AGeom2f.

Definition at line 549 of file geom2f.hpp.

Member Data Documentation

◆ center

Point2f jau::math::geom::Disk2f::center

Imagine a circle ;-)


| |r | | | | | c |

| |

m_center

Definition at line 479 of file geom2f.hpp.

◆ radius

float jau::math::geom::Disk2f::radius

Definition at line 480 of file geom2f.hpp.

◆ dir_angle

float jau::math::geom::Disk2f::dir_angle

direction angle in radians

Definition at line 482 of file geom2f.hpp.


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