Loading...
Searching...
No Matches
MeshItems.hh
/* ========================================================================= *
* *
* OpenMesh *
* Copyright (c) 2001-2015, RWTH-Aachen University *
* Department of Computer Graphics and Multimedia *
* All rights reserved. *
* www.openmesh.org *
* *
*---------------------------------------------------------------------------*
* This file is part of OpenMesh. *
*---------------------------------------------------------------------------*
* *
* Redistribution and use in source and binary forms, with or without *
* modification, are permitted provided that the following conditions *
* are met: *
* *
* 1. Redistributions of source code must retain the above copyright notice, *
* this list of conditions and the following disclaimer. *
* *
* 2. Redistributions in binary form must reproduce the above copyright *
* notice, this list of conditions and the following disclaimer in the *
* documentation and/or other materials provided with the distribution. *
* *
* 3. Neither the name of the copyright holder nor the names of its *
* contributors may be used to endorse or promote products derived from *
* this software without specific prior written permission. *
* *
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS *
* "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED *
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A *
* PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER *
* OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, *
* EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, *
* PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR *
* PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF *
* LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING *
* NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS *
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. *
* *
* ========================================================================= */
//=============================================================================
//
// Mesh Items Concept
//
//=============================================================================
#error this file is for documentation purposes only
//== NAMESPACES ===============================================================
namespace OpenMesh {
namespace Concepts {
//== CLASS DEFINITION =========================================================
struct MeshItems {
template <class Refs_> class VertexT
{
public:
typedef Refs_ Refs;
VertexT();
HalfedgeHandle halfedge_handle() const;
void set_halfedge_handle(HalfedgeHandle _eh);
};
template <class Refs_> class HalfedgeT
{
public:
typedef Refs_ Refs;
VertexHandle vertex_handle() const;
void set_vertex_handle(VertexHandle _vh);
FaceHandle face_handle() const;
void set_face_handle(FaceHandle _fh);
HalfedgeHandle next_halfedge_handle() const;
void set_next_halfedge_handle(HalfedgeHandle _eh);
};
template <class Refs_> class EdgeT
{
public:
typedef Refs_ Refs;
Halfedge halfedges[2];
};
template <class Refs_> class FaceT
{
public:
typedef Refs_ Refs;
typedef GenProg::TagTrue IsTriangle;
static bool is_triangle();
unsigned char n_vertices() const;
void set_n_vertices(unsigned char _n);
HalfedgeHandle halfedge_handle() const;
void set_halfedge_handle(HalfedgeHandle _eh);
};
};
//=============================================================================
} // namespace Concepts
} // namespace OpenMesh
//=============================================================================
OpenMesh
Contains all the mesh ingredients like the polygonal mesh, the triangle mesh, different mesh kernels ...
Definition MeshItems.hh:59
OpenMesh::Concepts
Descriptions of the concepts used in OpenMesh.
Definition MeshItems.hh:60
OpenMesh::Concepts::MeshItems
The mesh items class encapsulates the types VertexT, HalfedgeT, EdgeT, and FaceT.
Definition MeshItems.hh:71
OpenMesh::Concepts::MeshItems::VertexT::Refs
Refs_ Refs
Re-export the template argument Refs. This must be done!
Definition MeshItems.hh:86
OpenMesh::Concepts::MeshItems::VertexT::set_halfedge_handle
void set_halfedge_handle(HalfedgeHandle _eh)
Set the outgoing halfedge link.
OpenMesh::Concepts::MeshItems::VertexT::VertexT
VertexT()
Default constructor.
OpenMesh::Concepts::MeshItems::VertexT::halfedge_handle
HalfedgeHandle halfedge_handle() const
Get an outgoing halfedge.
OpenMesh::Concepts::MeshItems::HalfedgeT
Interface for the internal halfedge type.
Definition MeshItems.hh:108
OpenMesh::Concepts::MeshItems::HalfedgeT::set_face_handle
void set_face_handle(FaceHandle _fh)
Set the face this halfedge belongs to.
OpenMesh::Concepts::MeshItems::HalfedgeT::vertex_handle
VertexHandle vertex_handle() const
Get the vertex the halfedge point to.
OpenMesh::Concepts::MeshItems::HalfedgeT::set_next_halfedge_handle
void set_next_halfedge_handle(HalfedgeHandle _eh)
Set the next halfedge inside this face.
OpenMesh::Concepts::MeshItems::HalfedgeT::face_handle
FaceHandle face_handle() const
Get the face this halfedge belongs to.
OpenMesh::Concepts::MeshItems::HalfedgeT::next_halfedge_handle
HalfedgeHandle next_halfedge_handle() const
Get the next halfedge inside this face.
OpenMesh::Concepts::MeshItems::HalfedgeT::Refs
Refs_ Refs
Re-export the template argument Refs. This must be done!
Definition MeshItems.hh:112
OpenMesh::Concepts::MeshItems::HalfedgeT::set_vertex_handle
void set_vertex_handle(VertexHandle _vh)
Set the vertex the halfedge point to.
OpenMesh::Concepts::MeshItems::EdgeT
Interface for the internal edge type.
Definition MeshItems.hh:150
OpenMesh::Concepts::MeshItems::EdgeT::Refs
Refs_ Refs
Re-export the template argument Refs. This must be done!
Definition MeshItems.hh:154
OpenMesh::Concepts::MeshItems::EdgeT::halfedges
Halfedge halfedges[2]
Store two halfedges.
Definition MeshItems.hh:158
OpenMesh::Concepts::MeshItems::FaceT
Interface for the internal face type.
Definition MeshItems.hh:172
OpenMesh::Concepts::MeshItems::FaceT::n_vertices
unsigned char n_vertices() const
Get the number of vertices of this face.
OpenMesh::Concepts::MeshItems::FaceT::halfedge_handle
HalfedgeHandle halfedge_handle() const
Get a halfedge that belongs to this face.
OpenMesh::Concepts::MeshItems::FaceT::IsTriangle
GenProg::TagTrue IsTriangle
Compile-time-tag: is this face a triangle?
Definition MeshItems.hh:180
OpenMesh::Concepts::MeshItems::FaceT::set_n_vertices
void set_n_vertices(unsigned char _n)
Set the number of vertices of this face.
OpenMesh::Concepts::MeshItems::FaceT::Refs
Refs_ Refs
Re-export the template argument Refs. This must be done!
Definition MeshItems.hh:176
OpenMesh::Concepts::MeshItems::FaceT::set_halfedge_handle
void set_halfedge_handle(HalfedgeHandle _eh)
Set a halfedge that belongs this face.
OpenMesh::Concepts::MeshItems::FaceT::is_triangle
static bool is_triangle()
Run-time test: is this face a triangle?
OpenMesh::VertexHandle
Handle for a vertex entity.
Definition Handles.hh:121
OpenMesh::HalfedgeHandle
Handle for a halfedge entity.
Definition Handles.hh:128
OpenMesh::FaceHandle
Handle for a face entity.
Definition Handles.hh:142