LArSoft  v07_13_02
Liquid Argon Software toolkit - http://larsoft.org/
tss::bDistToPointLess Struct Reference

#include "SimpleClustering.h"

Inheritance diagram for tss::bDistToPointLess:

Public Member Functions

 bDistToPointLess (const TVector2 &point)
 
bool operator() (const tss::Hit2D *h1, const tss::Hit2D *h2)
 

Private Attributes

TVector2 p0
 

Detailed Description

Definition at line 24 of file SimpleClustering.h.

Constructor & Destructor Documentation

tss::bDistToPointLess::bDistToPointLess ( const TVector2 &  point)
inline

Definition at line 27 of file SimpleClustering.h.

27 : p0(point) { }

Member Function Documentation

bool tss::bDistToPointLess::operator() ( const tss::Hit2D h1,
const tss::Hit2D h2 
)
inline

Definition at line 29 of file SimpleClustering.h.

References pma::Dist2(), p0, and tss::Hit2D::Point2D().

30  {
31  if (h1 && h2) return pma::Dist2(h1->Point2D(), p0) < pma::Dist2(h2->Point2D(), p0);
32  else return false;
33  }
TVector2 const & Point2D(void) const
Definition: TssHit2D.h:37
double Dist2(const TVector2 &v1, const TVector2 &v2)
Definition: Utilities.cxx:19

Member Data Documentation

TVector2 tss::bDistToPointLess::p0
private

Definition at line 35 of file SimpleClustering.h.

Referenced by operator()().


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