📄 acis_tutorials_(geometry).htm
字号:
<li class="toclevel-1"><a href="#Other_Geometry-related_Topics"><span class="tocnumber">7</span> <span class="toctext">Other Geometry-related Topics</span></a><ul><li class="toclevel-2"><a href="#Continuity_Requirements"><span class="tocnumber">7.1</span> <span class="toctext">Continuity Requirements</span></a></li><li class="toclevel-2"><a href="#Senses"><span class="tocnumber">7.2</span> <span class="toctext">Senses</span></a></li><li class="toclevel-2"><a href="#Faces_on_Periodic_Surfaces"><span class="tocnumber">7.3</span> <span class="toctext">Faces on Periodic Surfaces</span></a></li><li class="toclevel-2"><a href="#Using_a_Subset_of_a_Curve_or_Surface"><span class="tocnumber">7.4</span> <span class="toctext">Using a Subset of a Curve or Surface</span></a></li><li class="toclevel-2"><a href="#Using_Transformations"><span class="tocnumber">7.5</span> <span class="toctext">Using Transformations</span></a></li><li class="toclevel-2"><a href="#Converting_Analytic_Geometry_into_B-Spline_Geometry"><span class="tocnumber">7.6</span> <span class="toctext">Converting Analytic Geometry into B-Spline Geometry</span></a></li><li class="toclevel-2"><a href="#Validity_Checking"><span class="tocnumber">7.7</span> <span class="toctext">Validity Checking</span></a></li></ul></li><li class="toclevel-1"><a href="#Two_C.2B.2B_Examples"><span class="tocnumber">8</span> <span class="toctext">Two C++ Examples</span></a></li></ul></li></ul></td></tr></table><script type="text/javascript"> if (window.showTocToggle) { var tocShowText = "show"; var tocHideText = "hide"; showTocToggle(); } </script><p>This tutorial provides a brief overview of ACIS geometry and demonstrates some ways geometry can be constructed and queried.</p><a name="Introduction"></a><h2> <span class="mw-headline"> Introduction </span></h2><p>ACIS geometry can be categorized using a variety of criteria. Perhaps the first categorization you should be aware of is difference between persistent and non-persistent objects. When we talked about topology in Tutorial 3 every topology class was persistent. All topological classes are derived from ENTITY and, therefore, all topological changes are recorded by the ACIS history mechanism. This is not true with geometry classes. Some geometry classes are derived fom ENTITY and some are not. To help you distinguish between persistent and non-persistent geometry classes the names of classes that are derived from ENTITY are in UPPER CASE and the ones which are not are in lower case. (There is an exception to this rule, but in general this is rule will help you understand which is which.) Objects which become part of the model are derived from ENTITY. Classes that are not derived from ENTITY are used as part of the definition of persistent geometry classes and they may be used as construction geometry. Instances of these classes may be created on the stack or on the heap. Before we get too far into this rather abstract discussion let's describe what the classes are that we are talking about.</p><p>ACIS geometry falls into four categories:</p><ul><li> Points which exist in a 3-dimensional space,</li><li> Curves which exist in a 3-dimensional space,</li><li> Surfaces which exist in a 3-dimensional space, and</li><li> Curves which exist in the 2-dimensional space of a parametrically defined surface.</li></ul><p>Classes of these four types of geometry are show in the table below. </p><table class="wikitable"><tr><th> Persistent Class</th><th> Non-Persistent Class</th><th> Description</th></tr><tr><td> APOINT</td><td> SPAposition</td><td> a 3-dimensional point</td></tr><tr><td> CURVE</td><td> curve</td><td> a 3-dimensional curve</td></tr><tr><td> SURFACE</td><td> surface</td><td> a 3-dimensional surface</td></tr><tr><td> PCURVE</td><td> pcurve</td><td> a 2-dimensional curve</td></tr></table><p>We should mention that CURVE, curve, SURFACE, and surface are abstract base classes. You will always create instances of classes derived from these classes. The APOINT, SPAposition, PCURVE, and pcurve classes are not base classes and, therefore, do not have classes derived from them. (The rather unusual names for the APOINT and SPAposition classes were chosen so that they wouldn't conflict with classes in other third party libraries. They were originally called POINT and position, but their names were changed several years ago.)</p><a name="Points"></a><h2> <span class="mw-headline"> Points </span></h2><p>The most basic of geometrical concepts is a point in space. A point in 3-dimensional space is represented in ACIS by a <a href=/r18/qref/ACIS/html/classSPAposition.html class="external text">SPAposition</a>. A SPAposition contains three values representing the x, y, and z coordinates of a point in a 3-dimensional <a href="http://en.wikipedia.org/wiki/Cartesian_coordinate_system" class="external text" title="http://en.wikipedia.org/wiki/Cartesian_coordinate_system" rel="nofollow">Cartesion coordinate system</a>. </p><p>In the persistent ACIS model an <a href=/r18/qref/ACIS/html/classAPOINT.html class="external text">APOINT</a> is the geometry underlying a VERTEX. Each VERTEX contains a pointer to an APOINT. The geometric definition of an APOINT is stored in a SPAposition. </p><p>For completeness we should mention that ACIS also represents points in 1 and 2-dimensional spaces. The classes corresponding to 1 and 2-dimensional points are SPAparameter and SPApar_pos. (Yes. These were originally called parameter and par_pos.) There are no persistent classes that represent 1 and 2-dimensional points because they are not needed by the persistent ACIS model structure. The SPAparameter and SPApar_pos classes will be presented again in <a href="/r18/index.php/Tutorial:ACIS_Tutorials_%28Math_Classes%29" title="Tutorial:ACIS Tutorials (Math Classes)">Tutorials (Math Classes)</a>.</p><a name="Curves"></a><h2> <span class="mw-headline"> Curves </span></h2><dl><dd><span class="boilerplate seealso"><i>Main article: <a href="/r18/index.php?title=Curves&action=edit" class="new" title="Curves">Curves</a></i></span></dd></dl><p><br />The concept of a curve is implemented in ACIS in the curve and CURVE classes. Classes derived from curve are not persistent: those derived from CURVE are persistent. The geometry underlying EDGES must be persistent so CURVES are used in the model structure. Each EDGE contains a pointer to a CURVE. There are several types of CURVES - and for each CURVE type there is an associated (lower case) curve type - so let's briefly describe curves conceptually before we get into the class distinctions. </p><p>Each curve maps a single parameter value into a 3-dimensional point. Each curve has a parameter range which restricts the values the parameter may be, although in some cases a parameter range may be infinite which means the parameter may take on any value. Curves may be open, closed, or periodic. Periodic means two things in ACIS: </p><ol><li> If a curve is periodic with a period, <i>p</i>, then the position corresponding to a parameter value, <i>t</i>, is the same position that corresponds to the parameter <i>t + n*p</i>, where <i>n</i> is any integer. In other words, if you evaluate a periodic curve at <i>t + n*p</i> you will get the same position for any integer value of n.</li><li> The curve is at least G1 continuous across the seam. The seam for a periodic curve is the point corresponding to the start and end of the principle parameter range. The principle parameter range for a periodic curve is the range into which inverse evaluations are mapped. (An evaluation maps a parameter value into a 3-dimensional point. An inverse evaluation maps a 3-dimensional point into a parameter value.) For example, the principle parameter range of an ellipse is [-pi, pi], so at the point corresponding to a parameter value of pi (or -pi) the curve must be at least G1 continuous. </li></ol><p>ACIS defines three types of analytic curves: straight lines, ellipses, and helices. It defines a non-uniform rational b-spline curve. It defines many types of procedurally defined curves (for example, a surface-surface intersection curve.) And it defines a composite curve, which is an aggregation of other curves. The following table describes the specific classes used to create these types of curves.</p><table class="wikitable"><tr><th> Persistent Class</th><th> Non-Persistent Class</th><th> Description</th></tr><tr><td> STRAIGHT</td><td> straight</td><td> a straight line</td></tr><tr><td> ELLIPSE</td><td> ellipse</td><td> an elliptical curve</td></tr><tr><td> HELIX</td><td> helix</td><td> a helical curve</td></tr><tr><td> INTCURVE</td><td> intcurve</td><td> a NURBS curve,<p>a procedural curve, or </p><p>a composite curve</p></td></tr></table><a name="curves_.28lower_case_classes.29"></a><h3> <span class="mw-headline"> curves (lower case classes) </span></h3><p>The curve class defines many virtual functions including the following: </p><ul><li> determining the parameter range of a curve, </li><li> determining if a curve is open, closed, or periodic,</li><li> determining the position, tangent, or curvature at a specific parameter value,</li><li> determining the parameter value corresponding to a position on the curve,</li><li> determining the foot of the perpendicular line from a given point to the curve,</li><li> determining the closest point on a curve to a given point,</li><li> determining if a given point is within a given tolerance of the curve,</li><li> determining the length of the curve between two parameter values.</li></ul><p>The specific curve types are described below.</p><p>A <i>straight</i> represents a straight line. The form of a <a href="/r18/index.php?title=Straight&action=edit" class="new" title="Straight">straight</a> is always <i>open</i>. The parameter range of a straight may be (and is generally) limited to a subset of the real number line.</p><p>An <i>ellipse</i> represents a full or partial elliptical curve. An <a href="/r18/index.php?title=Ellipse&action=edit" class="new" title="Ellipse">ellipse</a> may represent a full or partial circle. The period of a full ellipse is 2*pi. The parameter range of an ellipse depends on whether or not it is a full ellipse. If it is a full ellipse, the parameter range is [-pi, pi]. If it is a partial ellipse, the parameter range is the real interval to which the ellipse has been limited. The form of an ellipse may be open, closed, or periodic. (If an ellipse is limited to a parameter range whose length is 2*pi, the ellipse is closed, but it is not periodic.) </p><p>A <i>helix</i> represents a general (possibly tapered) helical curve. Special cases of helices include non-tapered curves and planar curves (spirals.) The parameter range of a <a href="/r18/index.php?title=Helix&action=edit" class="new" title="Helix">helix</a> is part of its definition. The form of a helix is always <i>open</i>. </p><p>An <i>intcurve</i> represents an interpolated curve defined over a given parameter range. The form of an <a href="/r18/index.php?title=Intcurve&action=edit" class="new" title="Intcurve">intcurve</a> may be open, closed, or periodic. An intcurve is really a wrapper around an <i>int_cur</i>. This makes it much more efficient to copy and manipulate intcurves. The int_cur class is an abstract base class. There are many classes derived from the int_cur class which demonstrates the flexibility of this class. Some of these are enumerated below.</p><table class="wikitable"><tr><th> int_cur class</th><th> Description</th></tr><tr><td>exact_int_cur</td><td>a NURBS curve</td></tr><tr><td>par_int_cur</td><td>the 3-dimensional image of a 2-dimensional curve</td></tr><tr><td>int_int_cur</td><td>the intersection of two surfaces</td></tr><tr><td>law_int_cur</td><td>surface defined by a user defined function</td></tr><tr><td>off_int_cur</td><td>the intersection of two surfaces offset from two given surfaces</td></tr><tr><td>offset_int_cur</td><td>the offset of another curve</td></tr><tr><td>off_surf_int_cur</td><td>the offset of a curve lying on a surface along the surface normal</td></tr><tr><td>proj_int_cur</td><td>the perpendicular projection of a curve onto a surface</td></tr><tr><td>surf_int_cur</td><td>the perpendicular projection of a curve onto a surface where the curve lies within a fit tolerance of the surface
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -