I see this other post about sort qvector: post_sort_qvector_simple
But I need some method to sort elements of my QVector.
I have something like this:
CartesianPoint point
std::vector<CartesianPoint> vector_points;
Where CartesianPoint is:
class CartesianPoint
{
public:
double x;
double y;
double z;
}
Then I need to sort vector_points only for z element of Cartesian point.
I know this is not possible but I need something like this
std::vector(vector_points.z.begin(), vector_points.z.end());
How I would solve this?