HSVColorCoherence computes coherence between the two points from the color difference between them. More...
#include <pcl/tracking/hsv_color_coherence.h>
Public Types |
|
using | Ptr = shared_ptr< HSVColorCoherence< PointInT > > |
using | ConstPtr = shared_ptr< const HSVColorCoherence< PointInT > > |
Public Types inherited from pcl::tracking::PointCoherence< PointInT > | |
using | Ptr = shared_ptr< PointCoherence< PointInT > > |
using | ConstPtr = shared_ptr< const PointCoherence< PointInT > > |
Public Member Functions |
|
HSVColorCoherence () | |
initialize the weights of the computation. More... |
|
void | setWeight (double weight) |
set the weight of coherence More... |
|
double | getWeight () |
get the weight (w) of coherence More... |
|
void | setHWeight (double weight) |
set the hue weight (w_h) of coherence More... |
|
double | getHWeight () |
get the hue weight (w_h) of coherence More... |
|
void | setSWeight (double weight) |
set the saturation weight (w_s) of coherence More... |
|
double | getSWeight () |
get the saturation weight (w_s) of coherence More... |
|
void | setVWeight (double weight) |
set the value weight (w_v) of coherence More... |
|
double | getVWeight () |
get the value weight (w_v) of coherence More... |
|
Public Member Functions inherited from pcl::tracking::PointCoherence< PointInT > | |
PointCoherence () | |
empty constructor More... |
|
virtual | ~PointCoherence () |
empty distructor More... |
|
double | compute (PointInT &source, PointInT &target) |
compute coherence from the source point to the target point. More... |
|
Protected Member Functions |
|
double | computeCoherence (PointInT &source, PointInT &target) override |
return the color coherence between the two points. More... |
|
Protected Member Functions inherited from pcl::tracking::PointCoherence< PointInT > | |
const std::string & | getClassName () const |
Get a string representation of the name of this class. More... |
|
Protected Attributes |
|
double | weight_ |
the weight of coherence (w) More... |
|
double | h_weight_ |
the hue weight (w_h) More... |
|
double | s_weight_ |
the saturation weight (w_s) More... |
|
double | v_weight_ |
the value weight (w_v) More... |
|
Protected Attributes inherited from pcl::tracking::PointCoherence< PointInT > | |
std::string | coherence_name_ |
The coherence name. More... |
|
Detailed Description
template<typename PointInT>
class pcl::tracking::HSVColorCoherence< PointInT >
HSVColorCoherence computes coherence between the two points from the color difference between them.
the color difference is calculated in HSV color space. the coherence is calculated by 1 / ( 1 + w * (w_h^2 * h_diff^2 + w_s^2 * s_diff^2 + w_v^2
- v_diff^2))
Definition at line 15 of file hsv_color_coherence.h.
Member Typedef Documentation
ConstPtr
using pcl::tracking::HSVColorCoherence< PointInT >::ConstPtr = shared_ptr<const HSVColorCoherence<PointInT> > |
Definition at line 18 of file hsv_color_coherence.h.
Ptr
using pcl::tracking::HSVColorCoherence< PointInT >::Ptr = shared_ptr<HSVColorCoherence<PointInT> > |
Definition at line 17 of file hsv_color_coherence.h.
Constructor & Destructor Documentation
HSVColorCoherence()
|
inline |
initialize the weights of the computation.
weight_, h_weight_, s_weight_ default to 1.0 and v_weight_ defaults to 0.0.
Definition at line 23 of file hsv_color_coherence.h.
Member Function Documentation
computeCoherence()
|
overrideprotectedvirtual |
return the color coherence between the two points.
- Parameters
-
[in] source instance of source point. [in] target instance of target point.
Implements pcl::tracking::PointCoherence< PointInT >.
Definition at line 132 of file hsv_color_coherence.hpp.
References pcl::tracking::RGBValue::Blue, pcl::tracking::RGBValue::Green, pcl::tracking::RGBValue::int_value, pcl::tracking::RGBValue::Red, and pcl::tracking::RGB2HSV().
getHWeight()
|
inline |
get the hue weight (w_h) of coherence
Definition at line 58 of file hsv_color_coherence.h.
References pcl::tracking::HSVColorCoherence< PointInT >::h_weight_.
getSWeight()
|
inline |
get the saturation weight (w_s) of coherence
Definition at line 74 of file hsv_color_coherence.h.
References pcl::tracking::HSVColorCoherence< PointInT >::s_weight_.
getVWeight()
|
inline |
get the value weight (w_v) of coherence
Definition at line 90 of file hsv_color_coherence.h.
References pcl::tracking::HSVColorCoherence< PointInT >::v_weight_.
getWeight()
|
inline |
get the weight (w) of coherence
Definition at line 42 of file hsv_color_coherence.h.
References pcl::tracking::HSVColorCoherence< PointInT >::weight_.
setHWeight()
|
inline |
set the hue weight (w_h) of coherence
- Parameters
-
[in] weight the hue weight (w_h) of coherence.
Definition at line 51 of file hsv_color_coherence.h.
References pcl::tracking::HSVColorCoherence< PointInT >::h_weight_.
setSWeight()
|
inline |
set the saturation weight (w_s) of coherence
- Parameters
-
[in] weight the saturation weight (w_s) of coherence.
Definition at line 67 of file hsv_color_coherence.h.
References pcl::tracking::HSVColorCoherence< PointInT >::s_weight_.
setVWeight()
|
inline |
set the value weight (w_v) of coherence
- Parameters
-
[in] weight the value weight (w_v) of coherence.
Definition at line 83 of file hsv_color_coherence.h.
References pcl::tracking::HSVColorCoherence< PointInT >::v_weight_.
setWeight()
|
inline |
set the weight of coherence
- Parameters
-
[in] weight the weight of coherence.
Definition at line 35 of file hsv_color_coherence.h.
References pcl::tracking::HSVColorCoherence< PointInT >::weight_.
Member Data Documentation
h_weight_
|
protected |
the hue weight (w_h)
Definition at line 107 of file hsv_color_coherence.h.
Referenced by pcl::tracking::HSVColorCoherence< PointInT >::getHWeight(), and pcl::tracking::HSVColorCoherence< PointInT >::setHWeight().
s_weight_
|
protected |
the saturation weight (w_s)
Definition at line 110 of file hsv_color_coherence.h.
Referenced by pcl::tracking::HSVColorCoherence< PointInT >::getSWeight(), and pcl::tracking::HSVColorCoherence< PointInT >::setSWeight().
v_weight_
|
protected |
the value weight (w_v)
Definition at line 113 of file hsv_color_coherence.h.
Referenced by pcl::tracking::HSVColorCoherence< PointInT >::getVWeight(), and pcl::tracking::HSVColorCoherence< PointInT >::setVWeight().
weight_
|
protected |
the weight of coherence (w)
Definition at line 104 of file hsv_color_coherence.h.
Referenced by pcl::tracking::HSVColorCoherence< PointInT >::getWeight(), and pcl::tracking::HSVColorCoherence< PointInT >::setWeight().
The documentation for this class was generated from the following files:
- pcl/tracking/hsv_color_coherence.h
- pcl/tracking/impl/hsv_color_coherence.hpp
© 2009–2012, Willow Garage, Inc.
© 2012–, Open Perception, Inc.
Licensed under the BSD License.
https://pointclouds.org/documentation/classpcl_1_1tracking_1_1_h_s_v_color_coherence.html