struct mrpt::opengl::CPolyhedron::TPolyhedronEdge

Struct used to store a polyhedron edge.

The struct consists only of two vertex indices, used to access the polyhedron vertex list.

#include <mrpt/opengl/CPolyhedron.h>

struct TPolyhedronEdge
{
    //
fields

    uint32_t v1 = 0;
    uint32_t v2 = 0;

    // construction

    TPolyhedronEdge();

    //
methods

    bool operator == (const TPolyhedronEdge& e) const;
    double length(const std::vector<mrpt::math::TPoint3D>& vs) const;
};

Fields

uint32_t v1 = 0

Vertices.

Construction

TPolyhedronEdge()

Default constructor.

Initializes to garbage.

Methods

bool operator == (const TPolyhedronEdge& e) const

Comparison agains another edge.

Simmetry is taken into account.

double length(const std::vector<mrpt::math::TPoint3D>& vs) const

Given a set of vertices, computes the length of the vertex.