Commit 147260ac authored by Jan Möbius's avatar Jan Möbius
Browse files

Conveniance plugin function

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@11531 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 45a9c2fd
......@@ -133,6 +133,15 @@ PolyMesh* polyMesh( BaseObjectData* _object ) {
return NULL;
}
PolyMesh* polyMesh( int _identifier ) {
PolyMeshObject* object = polyMeshObject(_identifier);
if ( object == 0)
return 0;
else
return object->mesh();
}
PolyMeshObject* polyMeshObject( BaseObjectData* _object ) {
if ( _object == 0 )
......
......@@ -131,6 +131,14 @@ bool getMesh( int _identifier , PolyMesh*& _mesh );
DLLEXPORT
PolyMesh* polyMesh( BaseObjectData* _object );
/** \brief Get a poly mesh from an object id.
*
* @param _identifier Identifier of the object. If its a poly mesh, the function will return the pointer to the mesh
* otherwise 0
*/
DLLEXPORT
TriMesh* polyMesh( int _identifier );
/** \brief Cast an BaseObject to a PolyMeshObject if possible
*
* @param _object The object should be of type BaseDataObject. If the content is a poly Mesh, a
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment