From 9d4976640507d6db071961fdd18cc6c94cf23df8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Se=CC=81rgio=20Agostinho?= Date: Wed, 18 Nov 2015 02:30:11 +0100 Subject: [PATCH] Fix to #1390 --- visualization/src/pcl_visualizer.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/visualization/src/pcl_visualizer.cpp b/visualization/src/pcl_visualizer.cpp index 3a00251f982..30c26bca297 100644 --- a/visualization/src/pcl_visualizer.cpp +++ b/visualization/src/pcl_visualizer.cpp @@ -467,6 +467,14 @@ void pcl::visualization::PCLVisualizer::spinOnce (int time, bool force_redraw) { resetStoppedFlag (); + #if (defined (__APPLE__)\ + && ( (VTK_MAJOR_VERSION > 6) || ( (VTK_MAJOR_VERSION == 6) && (VTK_MINOR_VERSION >= 1)))) + if (!win_->IsDrawable ()) + { + close (); + return; + } + #endif if (time <= 0) time = 1;