Commit d2d1640e authored by Dave Cooper's avatar Dave Cooper
Browse files

fixes for sequence cardinality bashing issue and typo fix in center-of-gravity

parent 29f49337
This diff is collapsed.
......@@ -22,6 +22,15 @@
(in-package :surf)
(defun make-triplets (list)
(let ((count 0) triplet triplet-list)
(setq triplet-list
(dolist (item list (nreverse triplet-list))
(if (< count 3)
(progn (push item triplet) (incf count))
(progn (push (nreverse triplet) triplet-list)
(setq count 1) (setq triplet (list item))))))
(setq triplet-list (append triplet-list (list (nreverse triplet))))))
(define-object brep (geometry-kernel-object-mixin ifs-output-mixin base-object)
......@@ -688,7 +697,7 @@ be faster to compute and exhibit more stability.
:&key ((tolerance (the adaptive-tolerance)) \"Controls how precisely the properties are computed\")"
center-of-gravity
(&key (tolerance (the adaptive-tolerance)))
(let ((volume (the volume :tolerance tolerance)))
(let ((volume (the (volume :tolerance tolerance))))
(when (zerop volume) (error "~a is a zero-volume brep. Center-of-gravity cannot be computed.~%"
(cons 'the (reverse (the root-path)))))
(scalar*vector (/ volume)
......
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