mercator  0.4.0
A terrain generation library for the Worldforge system.
Mercator::LeftClip Struct Reference

Helper to clip points to a given range. More...

Collaboration diagram for Mercator::LeftClip:

Public Member Functions

 LeftClip (CoordType t)
 
bool inside (const Point2 &p) const
 Check a point is outside this clip. More...
 
Point2 clip (const Point2 &u, const Point2 &v) const
 Determine the point where a line crosses this clip. More...
 

Public Attributes

CoordType leftX
 Left of x range. More...
 

Detailed Description

Helper to clip points to a given range.

Definition at line 108 of file Area.cpp.

Constructor & Destructor Documentation

◆ LeftClip()

Mercator::LeftClip::LeftClip ( CoordType  t)
inlineexplicit

Constructor

Parameters
tleft of x range.

Definition at line 113 of file Area.cpp.

Member Function Documentation

◆ clip()

Point2 Mercator::LeftClip::clip ( const Point2 &  u,
const Point2 &  v 
) const
inline

Determine the point where a line crosses this clip.

Parameters
uone of of a line that crosses this clip
vone of of a line that crosses this clip
Returns
a point where the line cross this clip.

Definition at line 129 of file Area.cpp.

◆ inside()

bool Mercator::LeftClip::inside ( const Point2 &  p) const
inline

Check a point is outside this clip.

Parameters
ppoint to be checked.
Returns
true if p is outside the clip.

Definition at line 119 of file Area.cpp.

Member Data Documentation

◆ leftX

CoordType Mercator::LeftClip::leftX

Left of x range.

Definition at line 141 of file Area.cpp.


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