Aleph-w 3.0
A C++ Library for Data Structures and Algorithms
Loading...
Searching...
No Matches
Ellipse Class Reference

#include <point.H>

Inheritance diagram for Ellipse:
[legend]
Collaboration diagram for Ellipse:
[legend]

Public Member Functions

 Ellipse (Point __center, const Geom_Number &__hr, const Geom_Number &__vr)
 
 Ellipse (const Ellipse &e)=default
 
 Ellipse ()=default
 
const Pointget_center () const
 
const Geom_Numberget_hradius () const
 
const Geom_Numberget_vradius () const
 
Point highest_point () const
 
Point lowest_point () const
 
Point leftmost_point () const
 
Point rightmost_point () const
 
void compute_tangents (Segment &s1, Segment &s2, const Geom_Number &m) const
 
bool intersects_with (const Segment &s) const
 
bool contains_to (const Point &p) const
 
bool intersects_with (const Point &p) const
 
Segment intersection_with (const Segment &sg) const
 
- Public Member Functions inherited from Geom_Object
 Geom_Object ()=default
 
virtual ~Geom_Object ()=default
 

Static Public Member Functions

static bool is_clockwise ()
 

Private Member Functions

Geom_Number compute_radius (const Point &p) const
 

Private Attributes

Point center
 
Geom_Number hr
 
Geom_Number vr
 

Friends

class Point
 

Detailed Description

Definition at line 1145 of file point.H.

Constructor & Destructor Documentation

◆ Ellipse() [1/3]

Ellipse::Ellipse ( Point  __center,
const Geom_Number __hr,
const Geom_Number __vr 
)
inline

Definition at line 1165 of file point.H.

◆ Ellipse() [2/3]

Ellipse::Ellipse ( const Ellipse e)
default

◆ Ellipse() [3/3]

Ellipse::Ellipse ( )
default

Member Function Documentation

◆ compute_radius()

Geom_Number Ellipse::compute_radius ( const Point p) const
inlineprivate

Definition at line 1309 of file point.H.

References center, Point::get_x(), Point::get_y(), hr, and vr.

Referenced by contains_to(), and intersects_with().

◆ compute_tangents()

void Ellipse::compute_tangents ( Segment s1,
Segment s2,
const Geom_Number m 
) const
inline

◆ contains_to()

bool Ellipse::contains_to ( const Point p) const
inline

Definition at line 1322 of file point.H.

References compute_radius().

Referenced by Point::is_inside().

◆ get_center()

const Point & Ellipse::get_center ( ) const
inline

Definition at line 1178 of file point.H.

References center.

Referenced by Eepic_Plane::draw_ellipse().

◆ get_hradius()

const Geom_Number & Ellipse::get_hradius ( ) const
inline

Definition at line 1180 of file point.H.

References hr.

Referenced by Eepic_Plane::draw_ellipse().

◆ get_vradius()

const Geom_Number & Ellipse::get_vradius ( ) const
inline

Definition at line 1182 of file point.H.

References vr.

Referenced by Eepic_Plane::draw_ellipse().

◆ highest_point()

Point Ellipse::highest_point ( ) const
inline

Definition at line 1186 of file point.H.

References center, Point::get_x(), Point::get_y(), and vr.

◆ intersection_with()

Segment Ellipse::intersection_with ( const Segment sg) const
inline

◆ intersects_with() [1/2]

bool Ellipse::intersects_with ( const Point p) const
inline

Definition at line 1328 of file point.H.

References compute_radius().

◆ intersects_with() [2/2]

bool Ellipse::intersects_with ( const Segment s) const
inline

◆ is_clockwise()

static bool Ellipse::is_clockwise ( )
inlinestatic

Definition at line 1184 of file point.H.

Referenced by TEST_F().

◆ leftmost_point()

Point Ellipse::leftmost_point ( ) const
inline

Definition at line 1196 of file point.H.

References center, Point::get_x(), Point::get_y(), and hr.

◆ lowest_point()

Point Ellipse::lowest_point ( ) const
inline

Definition at line 1191 of file point.H.

References center, Point::get_x(), Point::get_y(), and vr.

◆ rightmost_point()

Point Ellipse::rightmost_point ( ) const
inline

Definition at line 1201 of file point.H.

References center, Point::get_x(), Point::get_y(), and hr.

Friends And Related Symbol Documentation

◆ Point

friend class Point
friend

Definition at line 1147 of file point.H.

Referenced by compute_tangents(), and intersection_with().

Member Data Documentation

◆ center

◆ hr

Geom_Number Ellipse::hr
private

◆ vr

Geom_Number Ellipse::vr
private

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