#include <ObjectDataAngular.h>
|
| ObjectDataAngular (size_t frame_index, const cv::Point2d &position, double angle) |
|
| ObjectDataAngular (size_t frame_index, const cv::Point2d &position, double angle, double temporal_weight, double spatial_weight, double angular_weight) |
|
void | SetAngularWeight (double weight) |
|
double | GetAngle () const |
|
double | GetAngularWeight () const |
|
virtual double | CompareTo (ObjectDataPtr obj) const override |
|
virtual bool | IsWithinConstraints (ObjectDataPtr obj, std::unordered_map< std::string, double > &constraints) const override |
|
virtual ObjectDataPtr | Interpolate (ObjectDataPtr obj, double fraction) const override |
|
virtual void | Visualize (cv::Mat &image, cv::Scalar &color) const override |
|
virtual std::string | ToString (char delimiter) const override |
|
| ObjectData2D (size_t frame_index, cv::Point2d position) |
|
void | SetTemporalWeight (double weight) |
|
void | SetSpatialWeight (double weight) |
|
cv::Point2d | GetPosition () const |
|
double | GetTemporalWeight () const |
|
double | GetSpatialWeight () const |
|
| ObjectData () |
|
| ObjectData (std::size_t frame_index) |
|
std::size_t | GetFrameIndex () const |
|
void | SetFrameIndex (size_t index) |
|
void | SetDetectionScore (double score) |
|
double | GetDetectionScore () const |
|
bool | IsVirtual () const |
|
Class for storing a detection in two dimensional space with an rotation angle in radians.
core::ObjectDataAngular::ObjectDataAngular |
( |
size_t |
frame_index, |
|
|
const cv::Point2d & |
position, |
|
|
double |
angle |
|
) |
| |
Creates a new object in the given frame, with the given position and the given angle.
- Parameters
-
frame_index | The index of the frame |
position | The position in two dimensional space |
angle | The rotation angle in radians |
core::ObjectDataAngular::ObjectDataAngular |
( |
size_t |
frame_index, |
|
|
const cv::Point2d & |
position, |
|
|
double |
angle, |
|
|
double |
temporal_weight, |
|
|
double |
spatial_weight, |
|
|
double |
angular_weight |
|
) |
| |
Creates a new object in the given frame, with the given position and the given angle. The weights are used in the comparison calculation.
- Parameters
-
frame_index | The index of the frame |
position | The position in two dimensional space |
angle | The rotation angle in radians |
temporal_weight | The temporal weight |
spatial_weight | The spatial weight |
angular_weight | The angular weight |
double core::ObjectDataAngular::CompareTo |
( |
ObjectDataPtr |
obj | ) |
const |
|
overridevirtual |
Compares this object with the given object.
- Parameters
-
obj | A pointer to the object to compare this object to |
- Returns
- A double value indicating the comparison result
Reimplemented from core::ObjectData2D.
double core::ObjectDataAngular::GetAngle |
( |
| ) |
const |
Gets the rotation angle in radians.
- Returns
- The rotation angle in radians
double core::ObjectDataAngular::GetAngularWeight |
( |
| ) |
const |
Gets the angular weight.
- Returns
- The angular weight
ObjectDataPtr core::ObjectDataAngular::Interpolate |
( |
ObjectDataPtr |
obj, |
|
|
double |
fraction |
|
) |
| const |
|
overridevirtual |
Linearly interpolates between this and the given object. Creates a new object to fit between the two objects.
- Parameters
-
obj | A pointer to the target object |
fraction | Describes where the interpolation should be done. A fraction of zero is a clone of this object, a fraction of one is a clone of the target object. |
- Returns
- The interpolated object
Reimplemented from core::ObjectData2D.
bool core::ObjectDataAngular::IsWithinConstraints |
( |
ObjectDataPtr |
obj, |
|
|
std::unordered_map< std::string, double > & |
constraints |
|
) |
| const |
|
overridevirtual |
Checks if the difference between this object and the specified object is within the constraints specified. The difference is calculated for each constraint separately.
- Parameters
-
obj | The object to get the difference to |
constraints | The constraints to assure |
Reimplemented from core::ObjectData2D.
void core::ObjectDataAngular::SetAngularWeight |
( |
double |
weight | ) |
|
Sets the angular weight.
- Parameters
-
std::string core::ObjectDataAngular::ToString |
( |
char |
delimiter | ) |
const |
|
overridevirtual |
Returns a string representing the values of this object data.
- Parameters
-
delimiter | The delimiter used to separate values |
- Returns
- The string containing the values
Reimplemented from core::ObjectData2D.
void core::ObjectDataAngular::Visualize |
( |
cv::Mat & |
image, |
|
|
cv::Scalar & |
color |
|
) |
| const |
|
overridevirtual |
Visualizes the object in the given image with the given color. This method does nothing, it needs to be overwritten to visualize something.
- Parameters
-
image | The image to write into |
color | The color to use |
Reimplemented from core::ObjectData2D.
The documentation for this class was generated from the following files: