https://brlcad.org/w/api.php?action=feedcontributions&user=UncleNed24&feedformat=atomBRL-CAD - User contributions [en]2021-10-27T20:12:40ZUser contributionsMediaWiki 1.32.2https://brlcad.org/w/index.php?title=MGED_CMD_Z&diff=4972MGED CMD Z2013-04-09T15:29:43Z<p>UncleNed24: /* Description */</p>
<hr />
<div>[[Category:MGED|Z]]<br />
[[Category:MGED view manipulation|Z]]<br />
=Z=<br />
__TOC__<br />
<br />
==Syntax==<br />
:Z <br />
<br />
<br />
==Argument(s)==<br />
: No Arguments for this command.<br />
<br />
<br />
==Return Value(s)==<br />
: No Return Values for this command.<br />
<br />
<br />
==Description==<br />
<br />
The Z command zaps (clears) all wireframes from the graphics display window. Graphical raytraces are not cleared by this command.<br />
<br />
Note that this only affects the display of wireframes and does not delete any objects from the database.<br />
<br />
To clear the graphical raytraces, use the Raytrace Control Panel: Graphics Window > File > Raytrace > fbclear button.<br />
<br />
==Example(s)==<br />
: '''mged&gt;''' Z<br />
:: Clears the mged display of wireframes.<br />
<br />
==See Also==<br />
: [[MGED_CMD_d|d]]<br />
<br />
----<br />
<br />
Page Generated by David Loman on: 10/11/2007 at: 2:07:43 PM</div>UncleNed24https://brlcad.org/w/index.php?title=BRL-CAD_Primitives&diff=4971BRL-CAD Primitives2013-04-07T23:39:20Z<p>UncleNed24: /* spline */</p>
<hr />
<div>[[category:MGED| Primitives]]<br />
<br />
These are primitive objects that can be created in mged.<br />
<br />
Objects can be created in any of the following ways: (note: are there more? get? load from file?)<br />
;make : the mged make command creates the object with default dimensions<br />
;in : the mged in command interactively prompts for dimensions not already supplied as arguments<br />
;form :the graphical primitive editor form (* some objects not fully supported)<br />
;create : the graphical create menu<br />
<br />
When an object is selected from the create menu, you are prompted for a name, and then dropped into the primitive editor form; however, if the objec type has no form, create will do about the same as make. Some derivative objects do not have their own form, and the primitive editor will use the base object's form. Most parameters (including ones not editable from a form) have special items on the edit menu.<br />
<br />
See also [[A Survey of Implicit Constraints in Primitives]]<br />
<br />
=Arbs=<br />
Objects with an arbitrary number of points and flat faces...<br />
==arb8==<br />
Arbitrary straight-edged shape with 8 vertices. <br />
<br />
;Handled by: make in form create<br />
;Arguments: 8 Vertices in the following order: 1234 vertices for the front face, starting at bottom left, counterclockwise; then 5678 vertices for the rear face, starting at bottom left, counterclockwise.<br />
;Example: <br />
in unitcube.s arb8 0 0 0 1 0 0 1 0 1 0 0 1 0 1 0 1 1 0 1 1 1 0 1 1<br />
creates the unit cube (first vertex at the origin, extends for 1 unit in x, y and z direction).<br />
<br />
== arb7 ==<br />
Special case of arb8, except with point 8 merged into point 5, making the left face triangular<br />
;Handled by: make in form(arb8) create<br />
== arb6 ==<br />
Arbitrary straight-edged shape with 6 vertices, special case of arb8.<br />
;Handled by: make in form(arb8) create<br />
;Arguments: 6 Vertices in the following order: 1234 vertices for the front face, starting at bottom left, counterclockwise; then back edge is 5 on bottom, 6 on top. Top and bottom faces are triangles.<br />
;Example:<br />
<br />
in arb6.s arb6 1 -1 -1 1 1 -1 1 1 1 1 -1 1 -1 0 -1 -1 0 1<br />
<br />
== arb5 ==<br />
special case of arb8.<br />
;Handled by: make in form(arb8) create<br />
== arb4 ==<br />
special case of arb8.<br />
;Handled by: make in form(arb8) create<br />
== arbn ==<br />
Arbitrary solid bounded by N planes. <br />
;The solid is constructed by N sets of plane coefficients and distance magnitudes, that define space which is ~outside~ the solid. The coefficients define a vector whose normal is a plane parallel to the face of the solid. The surface of the solid is at the perscribed distance along this vector. <br />
<br />
The distances may be negative and are used when a face lies on the opposite side of the origin as the tip of its vector. An example is if the left side of a box lies on the positive X axis. In this case, because the left side is being defined, the vector points left (coefficients -1 0 0), but since the point is on the positive X axis its distance is opposite its vector and therefore negative.<br />
<br />
;Handled by: make in create<br />
;Arguments<br />
:Number of planes<br />
:xyz direction vector and distance for each plane<br />
<br />
;Example<br />
:in arbn.s arbn 8 1 0 1 1 -1 0 0 1 0 1 0 1 0 -1 0 1 0 0 1 1 0 0 -1 1 0.5 0.5 0.5 1 -0.5 -0.5 -0.5 1<br />
<br />
;Example with negative distance<br />
:in arbn2.s arbn 6 1 0 0 100 -1 0 0 -10 0 1 0 200 0 -1 0 -10 0 0 -1 0 0 0 1 1.5<br />
:...is equivalent to...<br />
:in rpp.s rpp 10 100 10 200 0 1.5<br />
<br />
==box==<br />
Special case of arb8<br />
;Handled by: in form(arb8)<br />
;Arguments: Vertex of first corner, direction vectors for height, width, and depth<br />
<br />
==raw==<br />
Right Angle Wedge, special case of arb6<br />
;Handled by: in form(arb8)<br />
;Arguments: Vertex of first corner, direction vectors for height, width, and depth<br />
<br />
==rpp==<br />
Rectangular Parallelpiped, special case of arb8<br />
;Handled by: make in form(arb8) create<br />
;Arguments: xmin xmax ymin ymax zmin zmax<br />
<br />
=Ellipsoids=<br />
== ell ==<br />
Ellipsoid<br />
;Handled by: make in form create<br />
;Arguments:<br />
;;V : vertex point, at the center<br />
;;vectors A B C describing the radii of the ellipses; A points front, B points right, C points up.<br />
<br />
Example:<br />
in ell.s ell 0 0 0 0 -1 0 1 0 0 0 0 1<br />
== sph ==<br />
Sphere, special case of the ellipsoid, with vectors A B and C all the same magnitude (radius).<br />
;Handled by: make in form(ell) create<br />
Arguments:<br />
;V : vertex point, at the center<br />
;radius<br />
== ellg ==<br />
Special case of ellipsoid<br />
;Handled by: in form(ell) <br />
;Arguments: two foci points, and axis length<br />
==ell1==<br />
Special case of ellipsoid<br />
;Handled by: in make form(ell) create<br />
;Arguments: vertex, vector A, radius of revolution<br />
==ehy==<br />
Elliptical hyperboloid<br />
;Handled by: make in form create<br />
;Arguments: vertex, perpendicular vectors Height and (A,r_1) major axis, (r_2) magnitude of vector B, (c) apex to asymptotes distance<br />
<br />
==epa==<br />
Elliptical paraboloid<br />
;Handled by: in make form create<br />
<br />
=Cones and Cylinders=<br />
== tgc ==<br />
Truncated general cone<br />
;Handled by: in make form create<br />
;Arguments: vertex, vectors H A B, magnitudes of vectors C D<br />
<br />
== rcc ==<br />
Right circular cylinder, special case of tgc<br />
;Handled by: in make form(tgc) create<br />
;Arguments: vertex, height vector, radius<br />
Example:<br />
in rcc1.s rcc 0 0 0 1 1 1 0.5<br />
<br />
== rec ==<br />
Right elliptical cylinder, special case of tgc<br />
;Handled by: in make form(tgc) create<br />
;Arguments: vertex, height vector, radius<br />
== rhc ==<br />
Right hyperbolic cylinder<br />
;Handled by: in make form create<br />
;Arguments: vertex, perpendicular vectors for Height and B, (r) rectangular half width, (c) apex to asymptote distance,<br />
== rpc ==<br />
Right parabolic cylinder<br />
;Handled by: in make form create<br />
;Arguments: vertex, perpendicular vectors for Height and B, (r) rectangular half width<br />
== tec ==<br />
Truncated elliptical cone, special case of tgc<br />
;Handled by: in make form(tgc) create<br />
;Arguments: Vertex, vectors Height, A, B<br />
== trc ==<br />
Truncated right circular cone, special case of tgc<br />
;Handled by: in make form(tgc) create<br />
;Arguments: Vertex, Height vector, radius of base and top<br />
<br />
= derived from 2d=<br />
==extrude==<br />
Extrusion of a 2-d sketch<br />
;Handled by: in make form(?) create<br />
;Arguments: vertex, perpendicular vectors Height A B, sketch, K<br />
<br />
==revolve==<br />
Revolution of a 2-d sketch<br />
;Handled by: in<br />
;Arguments: vertex, revolution axis, vector in start plane, angle, sketch<br />
<br />
==dsp==<br />
;Handled by: in create<br />
;Arguments: data type (f|o), datasource, count of length and width, interpolation type, cut direction, cell size, unit elevation<br />
<br />
See also [[DSP]] tutorial.<br />
<br />
==ebm==<br />
extruded bit map<br />
;Handled by: in form create<br />
;Arguments: filename, width and height in cells, extrusion distance, <br />
<br />
See also [[EBM]] tutorial.<br />
<br />
The extruded bitmap (also referred to as EBM) is a solid based on a greyscale bitmap. The bitmap is an array of unsigned char values, see bw(5), and is extruded by some distance. The EBM solid requires the dimensions of the bitmap file (height and width in bytes), an extrusion length, and a transformation matrix to position the EBM. Each byte in the bitmap file is treated as the base of a cell that is extruded by the specified extrusion length. If the value of the byte is nonĀzero, then that cell is considered solid.<br />
<br />
==hf==<br />
Height field<br />
;Handled by: none?<br />
;Status: depreciated, use dsp instead<br />
<br />
<br />
=Other solids=<br />
<br />
== tor ==<br />
Torus<br />
;Handled by: in make form create<br />
;Arguments: vertex, normal vector, radius of revolution, tube radius<br />
== eto ==<br />
Elliptical torus<br />
;Handled by: in make form create<br />
;Arguments: vertex, normal vector, radius of revolution, vector C, (r_d) magnitude of semi-minor axis<br />
<br />
== part ==<br />
Conical particle<br />
;Handled by: in make create<br />
;Arguments: vertex, height vector, radius at v, radius at h<br />
The particle solid is a lozenge-shaped object defined by a vertex, a height vector and radii at both ends. The body of the particle is either a cylinder or a truncated cone, depending on the values of the radii. Each end of the particle is a hemisphere of the specified radius.<br />
<br />
== nmg ==<br />
n-Manifold geometry solid (non-manifold geometry)<br />
;Handled by: make create<br />
<br />
== pipe ==<br />
Hollow and solid pipes and wires<br />
;Handled by: in make create<br />
;Arguments: # points, for each point: location, inner and outer diameters, bend radius<br />
<br />
==ars==<br />
Arbitrary rectangular solid<br />
;Handled by: in make create<br />
<br />
Solids of type 'ars' (Arbitrary Faceted Solids) are defined using "waterlines". The following figure consists of a start point, some number of intermediate polygons, and an ending point. Each of the intermediate polygons have the same number of vertices and the vertices are numbered 1 thru N. In addition to the intermediate polygons a line will be created that begins at the start point, goes through each polygon at its vertex numbered 1, and terminates at the end point. This is repeated for each polygon vertex 2 thru N. The start point, polygons, and end point are each a "waterline".<br />
<br><br><br />
<need an image here to illustrate the concept><br />
<br><br><br />
the ars shape takes the following values as input:<br />
*The number of points per waterline (the number of vertices on each intermediate polygon)<br />
*The number of waterlines (the number of intermediate polygons plus 2)<br />
*X, Y, and Z for a starting point (the first waterline)<br />
*for each interior polygon (an intermediate waterline)<br />
**for each point on the polygon<br />
***X, Y, and Z for the point on the polygon<br />
*X, Y, and Z for an ending point (the last waterline)<br />
<br />
For example, the command:<br />
<br><br><br />
in x.1 ars 4 6 0 0 3 1 1 3 1 -1 3 -1 -1 3 -1 1 3 1 1 1 1 -1 1 -1 -1 1 -1 1 1 1 0 -1 0 -1 -1 -1 0 -1 0 1 -1 1 0 -3 0 -1 -3 -1 0 -3 0 1 -3 0 0 -3 <br />
<br><br><br />
Will produce a square bar with a tapered 1/8 turn twist in the middle. Of course, more waterlines in the twist and more points per waterline would make the twist smoother.<br />
<br><br><br />
[[Image:Example_ars.png|thumb|center|600px|Example ARS]]<br />
<br><br><br />
The parameters to the above ars command can be dissected as:<br />
<br />
4 : number of points per waterline (i.e. intermediate polygons have 4 vertices)<br><br />
6 : number of waterlines (four intermediate polygons plus the two endpoints)<br><br />
0 0 3 - the center of the top end of the bar<br><br />
1 1 3 1 -1 3 -1 -1 3 -1 1 3 : a 2x2 square in the xy plane at z offset 3<br><br />
1 1 1 1 -1 1 -1 -1 1 -1 1 1 : a 2x2 square oriented the same as the first but at z offset 1<br><br />
1 0 -1 0 -1 -1 -1 0 -1 0 1 -1 : a 2x2 square at a 45 degree rotation from the first squares at z offset -1<br><br />
1 0 -3 0 -1 -3 -1 0 -3 0 1 -3 : a 2x2 square at a 45 degree rotation from the first squares at z offset -3<br><br />
0 0 -3 : the center of the bottom end of the bar<br />
<br />
==metaball==<br />
;Handled by: in make form(*) create<br />
;Arguments: render method, threshold, number of points, location and field strength for each point (and blobbiness/goo factor)<br />
<br />
<br />
==nurb==<br />
Non-uniform rational b-spline<br />
;Handled by: none?<br />
<br />
==spline==<br />
surface splines<br />
;Handled by: ?<br />
<br />
==vol==<br />
volume / voxel<br />
; Handled by: in <br />
; Arguments: filename, xyz dimensions of file (in voxels), lower and upper threasholds, xyz dimensions of a cell<br />
The vol solid is defined by a 3-dimensional array of unsigned char values. The solid requires a file of these values, the extent of the file (in bytes) in each dimension, the size of each cell, and high and low thresholds. Any value in the file that is between the thresholds (inclusive) represents a solid cell.<br />
<br />
==bot==<br />
Bag of triangles<br />
;Handled by: in make create (not edit!)<br />
;Arguments: number of verticies, number of triangles, mode (1=surface 2=solid 3=plate), triangle orientation mode (1=unoriented 2=counter-clockwise 3=clockwise), each vertex, vertex index of each triangle<br />
;See also: [[BoT]]<br />
<br />
==poly==<br />
polysolid<br />
; Handled by: none?<br />
; Status: depreciated, use bot instead<br />
<br />
=Other=<br />
==Sketch==<br />
2d outline<br />
;Handled by: make form(sketch editor) create<br />
;See also: [[sketch]]<br />
<br />
==grip ==<br />
Grip -- support for joints, non-geometric (does not show in rt)<br />
;Handled by: in make form create<br />
Arguments:<br />
;C : Center<br />
;N : normal vector<br />
;L : magnitude<br />
<br />
== half ==<br />
halfspace<br />
;Handled by: in make form create<br />
;Arguments: Normal, distance from origin<br />
A half space is the portion of space on one side of a plane. It is represented by its boundary (the plane) and its outward-pointing normal vector. <br />
==binunif==<br />
Uniform-array binary object<br />
;Handled by: in create (not edit!)<br />
;Arguments: minor type (fdcsiLCSIL), data file, number of values<br />
<br />
[[Determining the properties of primitives]]</div>UncleNed24