Skip to content

Commit

Permalink
Adding an API to HullUtil to deal with just a list of points.
Browse files Browse the repository at this point in the history
  • Loading branch information
madhephaestus committed Jul 21, 2017
1 parent 147eeb0 commit 2c27238
Showing 1 changed file with 9 additions and 1 deletion.
10 changes: 9 additions & 1 deletion src/main/java/eu/mihosoft/jcsg/ext/quickhull3d/HullUtil.java
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,15 @@ public class HullUtil {
private HullUtil() {
throw new AssertionError("Don't instantiate me!", null);
}

/**
* Hull.
*
* @param points the points
* @return the csg
*/
public static CSG hull(List<eu.mihosoft.vvecmath.Vector3d> points) {
return hull(points, new PropertyStorage());
}
public static CSG hull(List<eu.mihosoft.vvecmath.Vector3d> points, PropertyStorage storage) {

Point3d[] hullPoints = points.stream().map((vec) -> new Point3d(vec.x(), vec.y(), vec.z())).toArray(Point3d[]::new);
Expand Down

0 comments on commit 2c27238

Please sign in to comment.