| Object: fitted-surface (The :surf Package) |
| Mixins: surface |
| Input Slots (required) | |
| points list of lists of 3d points | |
The points for fitting, with inner lists representing U direction and outer lists V direction. | |
| Input Slots (optional) | |
| brep-tolerance [from surface] number | |
Overall tolerance for the internal brep representation of this surface. Defaults to nil. Note that a value of nil indicates for SMLib a value of 1.0e-05 of the longest diagonal length of the brep. | |
| built-from [from surface] gdl surface | |
Specify this if you want this surface to be a clone of an existing surface (note - this uses a shared underlying surface object, it does not make a copy) | |
| c11? boolean | |
If interpolated, indicates whether to compute a C11 continuous nonrational bicubic NURBS surface. Defaults to nil. | |
| color-decimal [from geometry-kernel-object-mixin] vector of three real numbers | |
The RGB color of this object as imported from an external format (e.g. IGES) or as specified in :display-controls. Defaults to the foreground color specified in *colors-default*. This message should not normally be overridden in user application code. | |
| end-caps-on-brep? [from surface] boolean | |
Indicates whether to attempt automatic endcaps on conversion of this surface to a brep. Note that this might change in future to a keyword value for :min, :max, or :both to provide more control. | |
| hidden? [from vanilla-mixin*] boolean | |
Indicates whether the object should effectively be a hidden-object even if specified in :objects. Default is nil. | |
| iges-level [from geometry-kernel-object-mixin] integer | |
Synonym for the layer. | |
| image-file [from base-object] pathname or string | |
Points to a pre-existing image file to be displayed instead of actual geometry for this object. Defaults to nil | |
| interpolant? boolean | |
Indicates whether the surface will interpolate the points. Defaults to t. | |
| layer [from geometry-kernel-object-mixin] integer | |
The primary IGES-compatible level (layer) on which this object resides. Defaults to the first of the levels. This slot can be overridden in user code to specify a new layer which will be written out when this object is exported with the IGES output-format. | |
| levels [from geometry-kernel-object-mixin] list of integers | |
The IGES-compatible levels (layers) on which this object resides. GDL does not currently support writing out multiple levels (layers) through the IGES writer ; only the first of these will be output if the object is exported with the IGES output-format (please contact Genworks if you need all levels (layers) to be written out). | |
| normals list of 3d vectors of same length as points, or nil | |
If given, these are the surface normals at each point. | |
| obliqueness [from base-object] 3x3 orthonormal matrix of double-float numbers | |
This is synonymous with the orientation. | |
| onclick-function [from base-object] lambda function of zero arguments, or nil | |
If non-nil, this function gets invoked when the user clicks the object in graphics front-ends which may or may not support this functionality (see viewport-html-div). | |
| parameterization keyword symbol, one of :uniform, :chord-length, :centripetal | |
The parameterization to use in the resultant surface if interpolant? is t. Default is :chord-length | |
| rational? [from surface] boolean | |
Returns non-nil iff this surface is rational, i.e. all weights are not 1. | |
| root [from vanilla-mixin*] gdl instance | |
The root-level node in this object's ``tree'' (instance hierarchy). | |
| safe-children [from vanilla-mixin*] list of gdl instances | |
All objects from the :objects specification, including elements of sequences as flat lists. Any children which throw errors come back as a plist with error information | |
| sew-and-orient-brep? [from surface] boolean | |
Indicates whether brep representation should undergo a sew-and-orient operation. Defaults to nil. | |
| strings-for-display [from vanilla-mixin*] string or list of strings | |
Determines how the name of objects of this type will be printed in most places. This defaults to the name-for-display (generally the part's name as specified in its parent), followed by an index number if the part is an element of a sequence. | |
| tangent-method keyword symbol, one of :bessel, :akima | |
The method used to compute tangents. Defaults to :akima. | |
| tessellation-parameters [from surface] plist of keyword symbols and numbers | |
This controls tessellation for the brep of this surface. The keys are as follows:
(list
:min-number-of-segments *tess-min-number-of-segments*
:max-3d-edge-factor *tess-max-3d-edge-factor*
:min-parametric-ratio *tess-min-parametric-ratio*
:max-chord-height *tess-max-chord-height*
:max-angle-degrees *tess-max-angle-degrees*
:min-3d-edge *tess-min-3d-edge*
:min-edge-ratio-uv *tess-min-edge-ratio-uv*
:max-aspect-ratio *tess-max-aspect-ratio*)
| |
| tolerance number | |
Tolerance for fit. Defaults to *3d-approximation-tolerance-default*. | |
| u-degree integer | |
The desired degree of the resultant surface in the U direction. Default is 3. | |
| u-start integer | |
The starting degree for the fit algorithm in the U direction. Default is 1. | |
| v-degree integer | |
The desired degree of the resultant surface in the V direction. Default is 3. | |
| v-start integer | |
The starting degree for the fit algorithm in the V direction. Default is 1. | |
| visible-children [from vanilla-mixin*] list of gdl instances | |
Additional objects to display in Tatu tree. Typically this would be a subset of hidden-children. Defaults to NIL. | |
| Input Slots (optional, defaulting) | |
| center [from base-object] 3d point | |
Indicates in global coordinates where the center of the reference box of this object should be located. | |
| display-controls [from base-object] plist | |
May contain keywords and values indicating display characteristics for this object. The following keywords are recognized currently:
| |
| isos [from surface] plist with keys :n-u and :n-v | |
The number of isoparametric curves to be displayed in each direction. This value comes from the value of :isos on the display-controls if that exists, and defaults to *isos-default* otherwise. | |
| orientation [from base-object] 3x3 matrix of double-float numbers | |
Indicates the absolute Rotation Matrix used to create the coordinate system of this object. This matrix is given in absolute terms (i.e. with respect to the root's orientation), and is generally created with the alignment function. It should be an orthonormal matrix, meaning each row is a vector with a magnitude of one (1.0). | |
| Computed Slots | |
| bounding-box [from base-object] list of two 3d points | |
The left front bottom and right rear top corners, in global coordinates, of the rectangular volume bounding the tree of geometric objects rooted at this object. | |
(in-package :gdl-user)
(define-object c11-test (surface)
:input-slots ()
:computed-slots ()
:objects
((surf-test :type 'fitted-surface
:hidden nil
:c11? t
:points (list (list (make-point -1 0 0)
(make-point 0 0 0)
(make-point 0.001 0.0 0)
(make-point 1 1 0)
(make-point 1.001 1 0)
(make-point 2 1 0)
(make-point 2.001 1 0)
(make-point 3 2 0)
(make-point 3.001 2.001 0)
(make-point 4 3 0)
(make-point 5 4 0))
(list
(make-point -1 0 1)
(make-point 0 0 1)
(make-point 0.001 0.0 1)
(make-point 1 1 1)
(make-point 1.001 1 1)
(make-point 2 1 1)
(make-point 2.001 1 1)
(make-point 3 2 1)
(make-point 3.001 2.001 1)
(make-point 4 3 1)
(make-point 5 4 1))))))
(#+allegro excl:without-package-locks #-allegro progn
(define-object test-fitted-surface (fitted-surface)
:input-slots
((display-controls (list :color :green-spring :isos (list :n-v 19 :n-u 19)))
(grid-width 4 :settable) (grid-length 4 :settable) (grid-height 4 :settable))
:computed-slots
((points (list (list (make-point 0 0 0)
(make-point (/ (the grid-width) 4) 0 0)
(make-point (half (the grid-width)) 0 0)
(make-point (* 3/4 (the grid-width)) 0 0)
(make-point (the grid-width) 0 0))
(list (make-point 0 (/ (the grid-length) 4) 0)
(make-point (/ (the grid-width) 4)
(/ (the grid-length) 4)
(/ (the grid-height) 4))
(make-point (half (the grid-width))
(/ (the grid-length) 4)
(* (/ (the grid-height) 4) 1.6))
(make-point (* 3/4 (the grid-width))
(/ (the grid-length) 4)
(/ (the grid-height) 4))
(make-point (the grid-width)
(/ (the grid-length) 4) 0))
(list (make-point 0 (half (the grid-length)) 0)
(make-point (/ (the grid-width) 4)
(half (the grid-length))
(* (/ (the grid-height) 4) 1.8))
(make-point (half (the grid-width))
(half (the grid-length))
(the grid-height))
(make-point (* 3/4 (the grid-width))
(half (the grid-length))
(* 3/4 (the grid-height)))
(make-point (the grid-width) (half (the grid-length)) 0))
(list (make-point 0 (* 3/4 (the grid-length)) 0)
(make-point (/ (the grid-width) 4)
(* 3/4 (the grid-length))
(min (* (/ (the grid-height) 4)
(* (/ (the grid-height) 4) 1.4))
(the grid-height)))
(make-point (half (the grid-width))
(* 3/4 (the grid-length))
(min (* (/ (the grid-height) 4)
(* (/ (the grid-height) 4) 1.8))
(the grid-height)))
(make-point (* 3/4 (the grid-width))
(* 3/4 (the grid-length))
(/ (the grid-height) 4))
(make-point (the grid-width)
(* 3/4 (the grid-length)) 0))
(list (make-point 0 (the grid-length) 0)
(make-point (/ (the grid-width) 4) (the grid-length) 0)
(make-point (half (the grid-width)) (the grid-length) 0)
(make-point (* 3/4 (the grid-width)) (the grid-length) 0)
(make-point (the grid-width) (the grid-length) 0)))))))
(generate-sample-drawing :objects (make-object 'test-fitted-surface)
:projection-direction :trimetric)
![]() |