From 0ace3d1568dcbbfc722e601439deaa0aba8ff279 Mon Sep 17 00:00:00 2001
From: Stephane Dallongeville <stephane.dallongeville@pasteur.fr>
Date: Thu, 28 Jan 2021 16:06:08 +0100
Subject: [PATCH] Added better error report on convexification error.

---
 pom.xml                                          | 3 +--
 src/main/java/plugins/adufour/roi/Convexify.java | 2 ++
 2 files changed, 3 insertions(+), 2 deletions(-)

diff --git a/pom.xml b/pom.xml
index f8d00a0..2f97b18 100644
--- a/pom.xml
+++ b/pom.xml
@@ -11,7 +11,7 @@
     </parent>
 
     <artifactId>convexify</artifactId>
-    <version>2.0.5</version>
+    <version>2.0.6</version>
 
     <packaging>jar</packaging>
 
@@ -24,7 +24,6 @@
         <dependency>
             <groupId>org.bioimageanalysis.icy</groupId>
             <artifactId>protocols</artifactId>
-            <version>${protocols.version}</version>
         </dependency>
         <dependency>
             <groupId>org.bioimageanalysis.icy</groupId>
diff --git a/src/main/java/plugins/adufour/roi/Convexify.java b/src/main/java/plugins/adufour/roi/Convexify.java
index 96d8452..b6f4536 100644
--- a/src/main/java/plugins/adufour/roi/Convexify.java
+++ b/src/main/java/plugins/adufour/roi/Convexify.java
@@ -149,6 +149,8 @@ public class Convexify extends EzPlug implements ROIBlock
         catch (Throwable t)
         {
             // can happen with QuickHull3D / ROI3DPolygonalMesh...
+            throw new IllegalArgumentException(
+                    "Cannot compute convex hull for ROI " + roi.getName() + " of type " + roi.getClassName() + ".", t);
         }
 
         if (output == null)
-- 
GitLab