Commit 6b10110b authored by Jan Möbius's avatar Jan Möbius
Browse files

new Plugin Function

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@7469 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 1ddb6dc5
......@@ -135,4 +135,18 @@ PolyMeshObject* polyMeshObject( BaseObjectData* _object ) {
return dynamic_cast< PolyMeshObject* >( _object );
}
PolyMeshObject* polyMeshObject( int _objectId ) {
if (_objectId == -1)
return 0;
BaseObject* object = objectRoot()->childExists( _objectId );
if ( object == 0 )
return 0;
PolyMeshObject* meshObject = dynamic_cast< PolyMeshObject* >(object);
return meshObject;
}
}
......@@ -139,6 +139,14 @@ PolyMesh* polyMesh( BaseObjectData* _object );
DLLEXPORT
PolyMeshObject* polyMeshObject( BaseObjectData* _object );
/** \brief Get an PolyMeshObject from the given id If possible
*
* @param _objectId Id of the requested Object. If the content is a volume, a
* a PolyMeshObject is returned. Otherwise a NULL pointer is returned.
*/
DLLEXPORT
PolyMeshObject* polyMeshObject( int _objectId );
/** @} */
}
......
Markdown is supported
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