Action:
|
Unites two or more bodies.
|
|
Filename:
|
bool/bool_scm/bool_scm.cxx
|
|
APIs:
|
api_boolean
|
|
Syntax:
|
(bool:unite body1 ... bodyn [keep-opt]
|
|
|
[acis-opts])
|
|
Arg Types:
|
body1
|
body
|
|
bodyn
|
body
|
|
keep-opt
|
string
|
|
acis-opts
|
acis-options
|
|
Returns:
|
body
|
|
Description:
|
This extension unites two or more bodies,. By default, the result of the unite is returned as
body1 and the remaining bodies are deleted.
|
|
|
The optional
keep-opt specifies whether some or all input bodies should be preserved. Value "keep_blank" preserves
body1 and returns the result of the unite as a new body. "keep_tool" preserves
body2 ... bodyn. "keep_both" preserves all input bodies and returns the result of the unite as a new body.
|
|
|
This extension checks for overlapping bodies. If it is known that the bodies do not overlap, use
body:combine, because it does not perform intersection checks. If it is known that the bodies overlap, or if there is some uncertainty as to whether the bodies overlap, use
body:unite.
|
|
|
This extension performs a regularized unite. Any faces, edges, and/or vertices not needed to support the topology are removed before returning the resulting body.
|
|
|
body1 is the first body of unite.
|
|
|
bodyn is the nth body of unite.
|
|
|
keep-opt specifies whether some or all input bodies should be preserved.
|
|
|
acis-opts contains parameters for versioning and journaling.
|
|
Example:
|
; bool:unite
|
|
; Create a solid block.
|
|
(define block1
|
|
|
(solid:block
|
|
|
(position 30 10 20) (position -30 -10 -20)))
|
|
;; block1
|
|
; Set color for block1.
|
|
(entity:set-color block1 2)
|
|
;; ()
|
|
; Create a solid cylinder.
|
|
(define cyl2
|
|
|
(solid:cylinder
|
|
|
(position 20 0 -20) (position 20 0 20) 20))
|
|
;; cyl2
|
|
; Set color for cyl2.
|
|
(entity:set-color cyl2 3)
|
|
;; ()
|
|
; OUTPUT Original
|
|
|
; Unite the block and cylinder
|
|
(define unite (bool:unite block1 cyl2))
|
|
;; unite
|
|
; #[entity 2 1]
|
|
; OUTPUT Result
|
|
|
|
|
Figure 2-17. bool:unite
|