|
Action:
|
Creates a variable radius object from a set of parameter values along the blend and radius values at each parameter.
|
|
|
Filename:
|
abl/abl_scm/abl_scm.cxx
|
|
|
APIs:
|
api_make_radius_param_rads_tan
|
|
|
Syntax:
|
(abl:make-radius-param-rads-tan param-list
|
|
|
radii-list [slope-keyword slope]
|
|
|
[slope-keyword slope] [acis-opts])
|
|
|
Arg Types:
|
param-list
|
real | (real ...)
|
|
radii-list
|
real | (real ...)
|
|
slope-keyword
|
string
|
|
slope
|
real
|
|
acis-opts
|
acis-options
|
|
|
Returns:
|
vradius
|
|
|
Errors:
|
Input lists must have equal lengths.
|
|
|
Description:
|
Creates a vradius object which corresponds to class
var_rad_functional. It uses
parameter-radius pairs plus start and end slope information to create a
var_rad_functional object. This allows the radius function to be specified at various positions along the blend.
|
|
|
This extension allows specification of the slope of the calibration curve at the start and end. The radius object created can be used as an input to the blend functions
api_set_aph_blends or
api_set_ee_vr_blend.
|
|
|
param-list is a list of parameter values.
|
|
|
radii-list should contain the same number of arguments as
param-list. It represents the intended blend radius at those parameter values.
|
|
|
slope-keyword must be "start-slope" or "end-slope" string followed by
slope.
|
|
|
slope is interpreted as the slope (dy/dx) in 2D coordinates, where 0 is horizontal, and 1 is 45 degrees. Pass in
NULL for unspecified.
|
|
|
acis-opts contains journaling and versioning information.
|
|
|
Example:
|
; abl:make-radius-param-rads-tan
|
|
; Create geometry to illustrate extension.
|
|
; Create a solid block, a cylinder, and unite them.
|
|
(define block (solid:block (position -20 -20 -20)
|
|
|
(position 20 20 20)))
|
|
;; block
|
|
(define cylinder (solid:cylinder (position 20 0 -20)
|
|
|
(position 20 0 20) 20))
|
|
;; cylinder
|
|
(define my-part (solid:unite block cylinder))
|
|
;; my-part
|
|
; Pick an edge on the body.
|
|
(define def-edge( pick:edge (ray
|
|
|
(position 10 -20 100) (gvector 0 0 -1))))
|
|
;; def-edge
|
|
; Display the edge in red.
|
|
(define set-color (entity:set-color def-edge RED))
|
|
;; set-color
|
|
; Define a list of parameter values.
|
|
(define param-list (list 0.0 40.0 102.8318 142.8318))
|
|
;; param-list
|
|
; Define a list of radius values.
|
|
(define radii-list (list 10 4 6 8))
|
|
;; radii-list
|
|
; Create the v-radius object.
|
|
(define v-radius (abl:make-radius-param-rads-tan
|
|
|
param-list radii-list))
|
|
;; v-radius
|
|
; OUTPUT Original
|
|
|
; Complete the blend.
|
|
(define blend1 (abl:edge-blend def-edge v-radius))
|
|
;; blend1
|
|
(define blend2 (blend:network
|
|
|
(blend:get-network def-edge)))
|
|
;; blend2
|
|
; OUTPUT Result
|
|
|
(render)
|
|
;; ()
|
|
; OUTPUT Rendered
|
|
|
|
|
|
Figure 3-13. abl:make-radius-param-rads-tan
|