Jpp  master_rocky-37-gf0c5bc59d
the software that should make you happy
Public Member Functions | List of all members
JGEOMETRY2D::JConvexHull2D::JLowerHull 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 lower hull. More...
 

Detailed Description

Auxiliary class for sorting elements.

Definition at line 171 of file JGeometry2DToolkit.hh.

Member Function Documentation

◆ operator()()

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

Sort criterion for lower hull.

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

Definition at line 180 of file JGeometry2DToolkit.hh.

181  {
182  if (first.getX() == second.getX())
183  return second.getY() > first.getY();
184  else
185  return first.getX() > second.getX();
186  }

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