Jpp test-rotations-new
the software that should make you happy
Loading...
Searching...
No Matches
JGEOMETRY2D::JConvexHull2D::JUpperHull Struct Reference

Auxiliary class for sorting elements. More...

#include <JGeometry2DToolkit.hh>

Public Member Functions

template<class T >
bool operator() (const T &first, const T &second) const
 Sort criterion for upper hull.
 

Detailed Description

Auxiliary class for sorting elements.

Definition at line 193 of file JGeometry2DToolkit.hh.

Member Function Documentation

◆ operator()()

template<class T >
bool JGEOMETRY2D::JConvexHull2D::JUpperHull::operator() ( const T & first,
const T & second ) const
inline

Sort criterion for upper hull.

Parameters
firstfirst point
secondsecond point
Returns
true if first before second; else false

Definition at line 202 of file JGeometry2DToolkit.hh.

203 {
204 if (first.getX() == second.getX())
205 return second.getY() < first.getY();
206 else
207 return first.getX() < second.getX();
208 }

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