50 #ifndef __BASEIMPORTER_HH__
51 #define __BASEIMPORTER_HH__
61 #include <OpenMesh/Core/System/config.h>
62 #include <OpenMesh/Core/Geometry/VectorT.hh>
63 #include <OpenMesh/Core/Mesh/BaseKernel.hh>
90 virtual VertexHandle add_vertex(
const Vec3f& _point) = 0;
93 typedef std::vector<VertexHandle> VHandles;
94 virtual FaceHandle add_face(
const VHandles& _indices) = 0;
97 virtual void add_face_texcoords(
FaceHandle _fh,
VertexHandle _vh,
const std::vector<Vec2f>& _face_texcoords) = 0;
100 virtual void set_face_texindex(
FaceHandle _fh,
int _texId ) = 0;
103 virtual void set_normal(
VertexHandle _vh,
const Vec3f& _normal) = 0;
106 virtual void set_color(
VertexHandle _vh,
const Vec3uc& _color) = 0;
109 virtual void set_color(
VertexHandle _vh,
const Vec4uc& _color) = 0;
112 virtual void set_color(
VertexHandle _vh,
const Vec3f& _color) = 0;
115 virtual void set_color(
VertexHandle _vh,
const Vec4f& _color) = 0;
118 virtual void set_texcoord(
VertexHandle _vh,
const Vec2f& _texcoord) = 0;
121 virtual void set_texcoord(
HalfedgeHandle _heh,
const Vec2f& _texcoord) = 0;
124 virtual void set_color(
EdgeHandle _eh,
const Vec3uc& _color) = 0;
127 virtual void set_color(
EdgeHandle _eh,
const Vec4uc& _color) = 0;
130 virtual void set_color(
EdgeHandle _eh,
const Vec3f& _color) = 0;
133 virtual void set_color(
EdgeHandle _eh,
const Vec4f& _color) = 0;
136 virtual void set_normal(
FaceHandle _fh,
const Vec3f& _normal) = 0;
139 virtual void set_color(
FaceHandle _fh,
const Vec3uc& _color) = 0;
142 virtual void set_color(
FaceHandle _fh,
const Vec4uc& _color) = 0;
145 virtual void set_color(
FaceHandle _fh,
const Vec3f& _color) = 0;
148 virtual void set_color(
FaceHandle _fh,
const Vec4f& _color) = 0;
152 virtual void add_texture_information(
int _id , std::string _name ) = 0;
157 virtual bool is_triangle_mesh()
const {
return false; }
160 virtual void reserve(
unsigned int ,
165 virtual size_t n_vertices()
const = 0;
166 virtual size_t n_faces()
const = 0;
167 virtual size_t n_edges()
const = 0;
171 virtual void prepare() {}
174 virtual void finish() {}
Base class for importer modules.
Definition: BaseImporter.hh:81
Contains all the mesh ingredients like the polygonal mesh, the triangle mesh, different mesh kernels ...
Definition: MeshItems.hh:56
Handle for a halfedge entity.
Definition: Handles.hh:121
Handle for a edge entity.
Definition: Handles.hh:128
Handle for a face entity.
Definition: Handles.hh:135
This class provides the basic property management like adding/removing properties and access to prope...
Definition: BaseKernel.hh:91
Handle for a vertex entity.
Definition: Handles.hh:114