Commit d3bcfa5d authored by Dirk Wilden's avatar Dirk Wilden
Browse files

don't segfault when picking fails

git-svn-id: http://www.openflipper.org/svnrepo/OpenFlipper/branches/Free@6809 383ad7c9-94d9-4d36-a494-682f7c89f535
parent f6db4a14
......@@ -65,6 +65,9 @@ void SelectionPlugin::paintSphereSelection( MeshT* _mesh ,
float sqr_radius = sphere_radius_*sphere_radius_;
typename MeshT::FaceHandle hitface = _mesh->face_handle(_target_idx);
if ( !hitface.is_valid() )
return;
// initialize everything
if (selectionType_ & VERTEX){
......@@ -422,6 +425,9 @@ void SelectionPlugin::toggleMeshSelection(MeshT* _mesh, uint _fh, ACG::Vec3d& _h
typename MeshT::FaceHandle fh = _mesh->face_handle(_fh);
if ( !fh.is_valid() )
return;
//Vertex Selection
if (selectionType_ & VERTEX){
......
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