Commit 1ddb6dc5 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@7468 383ad7c9-94d9-4d36-a494-682f7c89f535
parent 1d57538c
......@@ -142,4 +142,20 @@ TriMeshObject* triMeshObject( BaseObjectData* _object ) {
return dynamic_cast< TriMeshObject* >( _object );
}
TriMeshObject* triMeshObject( int _objectId ) {
if (_objectId == -1)
return 0;
BaseObject* object = objectRoot()->childExists( _objectId );
if ( object == 0 )
return 0;
TriMeshObject* meshObject = dynamic_cast< TriMeshObject* >(object);
return meshObject;
}
}
......@@ -138,6 +138,14 @@ TriMesh* triMesh( BaseObjectData* _object );
DLLEXPORT
TriMeshObject* triMeshObject( BaseObjectData* _object );
/** \brief Get an TriMeshObject from the given id If possible
*
* @param _objectId Id of the requested Object. If the content is a volume, a
* a TriMeshObject is returned. Otherwise a NULL pointer is returned.
*/
DLLEXPORT
TriMeshObject* triMeshObject( 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