39#ifndef H_OGF_MESH_COMMANDS_MESH_GROB_ATTRIBUTES_COMMANDS_H
40#define H_OGF_MESH_COMMANDS_MESH_GROB_ATTRIBUTES_COMMANDS_H
79 gom_arg_attribute(where, handler,
"combo_box")
80 gom_arg_attribute(where, values,
"vertices;edges;facets;cells")
81 gom_arg_attribute(type, handler,
"combo_box")
82 gom_arg_attribute(type, values,
"bool;uint32;int32;float64")
83 void create_attribute(
84 const std::
string& name,
85 const std::
string& where =
"points",
86 const std::
string& type =
"float64",
95 gom_arg_attribute(name, handler,
"combo_box")
96 gom_arg_attribute(name, values,
"$grob.attributes")
97 void delete_attribute(const std::
string& name);
143 const std::
string& attribute=
"distance"
155 const std::
string& attribute=
"lfs"
168 bool copy_tex_coords=false
182 const std::
string& attribute=
"AO",
183 index_t nb_rays_per_vertex = 100,
184 index_t nb_smoothing_iterations = 2
193 const std::
string& attribute =
"normal"
200 void compute_sub_elements_id(
201 MeshElementsFlags what, const std::
string& attribute
void compute_local_feature_size(const MeshGrobName &surface, const std::string &attribute="lfs")
Computes the distance to an approximation of the medial axis of a surface.
void compute_distance_to_surface(const MeshGrobName &surface, const std::string &attribute="distance")
Computes the distance between each vertex and a surface.
void compute_vertices_normals(const std::string &attribute="normal")
Computes per-vertex surface normals..
void compute_vertices_id(const std::string &attribute="id")
Stores the vertices ids in an attribute.
void copy_texture_colors(const MeshGrobName &surface, const ImageFileName &texture, bool copy_tex_coords=false)
Copies colors from a textured surface.
void compute_cells_id(const std::string &attribute="id")
Stores the cells ids in an attribute.
MeshGrobAttributesCommands()
MeshGrobAttributesCommands constructor.
void compute_chart_id(const std::string &attribute="chart")
Stores the chart (connected component) id in an attribute.
~MeshGrobAttributesCommands() override
MeshGrobAttributesCommands destructor.
void compute_facets_id(const std::string &attribute="id")
Stores the facets ids in an attribute.
void compute_edges_id(const std::string &attribute="id")
Stores the edges ids in an attribute.
void compute_ambient_occlusion(const std::string &attribute="AO", index_t nb_rays_per_vertex=100, index_t nb_smoothing_iterations=2)
Computes per-vertex ambient occlusion.
MeshGrobCommands()
MeshGrobCommands constructor.
Base class for Commands related with a MeshGrob object.
geo_index_t index_t
The type for storing and manipulating indices.
Global Graphite namespace.
Name< MeshGrob * > MeshGrobName
The name of an existing MeshGrob in the SceneGraph.
Name< File< Image * > > ImageFileName
The name of an existing file that contains an Image.
Definitions common to all include files in the mesh library.