Hello, I followed this tutorial http://www.openflipper.org/media/Documentation/OpenFlipper-1.3/ovm_tutorial_... to add properties to edges of a Polyhedral Mesh. The properties are set correctly. I can for example, iterate over all edges and print their property values. However, when I use the Property Visualisation plugin of OpenFlipper, the property I set is shown as zero for all edges.
Does someone know what is wrong?
Here it is my code:
int cur_insert_id = -1;
PolyhedralMesh* cur_volume_obj = 0;
emit addEmptyObject(DATA_POLYHEDRAL_MESH,cur_insert_id);
BaseObjectData *obj;
PluginFunctions::getObject(cur_insert_id, obj);
obj->target(false);
PolyhedralMesh* cur_polyhedral_mesh = PluginFunctions::polyhedralMesh(obj);
OpenVolumeMesh::EdgePropertyT<double> angle = cur_polyhedral_mesh->request_edge_property<double>("Edge Angles");
for(OpenVolumeMesh::EdgeIter e_it = cur_polyhedral_mesh->edges_begin();
e_it != cur_polyhedral_mesh->edges_end(); ++e_it)
{
double ang = 0;
…
angle[*e_it] = std::abs(ang);
}
emit updatedObject(obj->id(),UPDATE_ALL);
Thx very much in advance
Zeige Antworten nach Diskussionsstrang
openflipper@lists.rwth-aachen.de