//
// Created by Martin Gargalovič on 18. 8. 2021.
//

#ifndef ARC_SUPPORT_MEANSHIFT_H
#define ARC_SUPPORT_MEANSHIFT_H

#include <opencv2/core.hpp>
#include <set>
#include "utility.h"


/**
 * calculates mean shift for ellipse centeres
 * @param ellipses an array of ellipse equations
 * @returns ellipse equations with their centeres, centered around their centroids
 */
std::vector<std::vector<ellipseParameters>> clusterCenter(std::vector<ellipseParameters> &ellipses);

/**
 * calculates mean shift for ellipse angles
 * @param ellipses an array of ellipse equations
 * @returns ellipse equations with their rotation, centered around their rotation centroids
 */
std::vector<std::vector<ellipseParameters>> clusterAngle(std::vector<ellipseParameters> &ellipses);

/**
 * calculates mean shift for ellipse angles
 * @param ellipses an array of ellipse equations
 * @returns ellipse equations with the size of their axis, centered around their centroids
 */
std::vector<ellipseParameters> clusterAxis(std::vector<ellipseParameters> &ellipses);

#endif //ARC_SUPPORT_MEANSHIFT_H
