Message 1 of 5
BoundedVolumes Method
Not applicable
04-23-2021
12:35 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello.
Today i found one very interesting function. And do some research how i can use it in some lisp and i found this method which i think is interesting.
After my research 5-6 hours i cannot find any information how to use it.
I take some info from Here and try everything i can. Also i try This because i think this will be more easy.
I attach .dwg and code where is very wrong i think but..
Other used links:
(defun LM:group-n ( l n / r )
(if l
(cons
(reverse (repeat n (setq r (cons (car l) r) l (cdr l)) r))
(LM:group-n l n)
)
)
)
(defun gc:3dPointListToVariant (lst)
(vlax-make-variant
(vlax-safearray-fill
(vlax-make-safearray
vlax-VbDouble
(cons 0 (1- (* 3 (length lst))))
)
(apply 'append lst)
)
)
)
(defun c:dd2 (/ selL VnamL VnamS coord inv)
(setq selL (car (entsel "\nSelect Poly..")))
(setq VnamL (vlax-ename->vla-object selL))
(setq coord (gc:3dPointListToVariant (LM:group-n (vlax-get VnamL 'coordinates) 3)))
(setq selS (car (entsel "\nSelect volumeSurf..")))
(princ "\n")
(setq VnamS (vlax-ename->vla-object selS))
(setq inv (vl-catch-all-apply 'vlax-invoke-method (list (vlax-get VnamS 'Statistics) 'BoundedVolumes coord)))
(princ inv)
;(princ (vl-catch-all-error-message inv))
(princ)
)