Editing BRL-CAD Primitives

From BRL-CAD

Warning: You are not logged in. Your IP address will be publicly visible if you make any edits. If you log in or create an account, your edits will be attributed to your username, along with other benefits.

The edit can be undone. Please check the comparison below to verify that this is what you want to do, and then save the changes below to finish undoing the edit.
Latest revision Your text
Line 16: Line 16:
 
An '''arbitrary convex polyhedron''' ('''arb''') is a geometric volume that is completely enclosed by a set of 3-dimensional planes. Each has a set of straight-edged, flat '''faces''' outlined by the intersections of those planes. The intersection of each pair of planes is a line whose intersections with other planes defines a pair of '''vertices'''. The line segment between those two vertices is an '''edge''' of the polyhedron that is shared by two faces. Each vertex is common to an equal number (at least three) of faces and edges.
 
An '''arbitrary convex polyhedron''' ('''arb''') is a geometric volume that is completely enclosed by a set of 3-dimensional planes. Each has a set of straight-edged, flat '''faces''' outlined by the intersections of those planes. The intersection of each pair of planes is a line whose intersections with other planes defines a pair of '''vertices'''. The line segment between those two vertices is an '''edge''' of the polyhedron that is shared by two faces. Each vertex is common to an equal number (at least three) of faces and edges.
  
For example, a rectangular parallelepiped is enclosed by three orthogonal pairs of parallel planes. Their intersections define six faces, each with four edges and four vertices. There are a total of 12 edges (each shared by two faces) and 8 vertices (each shared by three faces and three edges).
+
For example, a rectangular parallelepiped is enclosed by three orthagonal pairs of parallel planes. Their intersections define six faces, each with four edges and four vertices. There are a total of 12 edges (each shared by two faces) and 8 vertices (each shared by three faces and three edges).
  
 
The BRL-CAD geometry file format defines two types of records for such polyhedra:
 
The BRL-CAD geometry file format defines two types of records for such polyhedra:
Line 26: Line 26:
 
== ARB8 Records ==
 
== ARB8 Records ==
  
An '''arb8''' record is specified by a set of eight {X, Y, Z} vertices designated V1 through V8, which need not all be unique. BRL-CAD uses such records to represent polyhedra having four, five or six faces:
+
An '''arb8''' record is specified by a set of eight {X, Y, Z} vertices designated V1 through V8, which need not all be unique. As discussed in the [[Creating and editing arb8 primitives]] article, BRL-CAD uses such records to represent polyhedra having four, five or six faces:
  
* '''arb8''' shapes have eight unique vertices. They represent '''hexahedra''' that have six quadrilateral faces sharing eight edges. In addition to simply specifying the {X, Y, Z} coordinates of those vertices, MGED provides easier ways to create the following specific types of hexahedra:
+
* '''arb8''' shapes represent '''hexahedra''' (six-sided polyhedra) whose sides are all quadrilaterals. They thus have eight edges and eight unique vertices. In addition to simply specifying the {X, Y, Z} coordinates of those vertices, MGED provides easier ways to create the following specific types of hexahedra:
 
** '''3ptarb''' shapes represent '''right quadrilateral prisms''', which are extruded quadrilaterals having parallel ends connected by four rectangular sides.
 
** '''3ptarb''' shapes represent '''right quadrilateral prisms''', which are extruded quadrilaterals having parallel ends connected by four rectangular sides.
 
** '''box''' shapes represent '''parallelepipeds''', whose faces comprise three pairs of equal parallelograms. Unlike a common box, those faces need not be rectangular—if they are, the enclosed volume is a rectangular parallelepiped.
 
** '''box''' shapes represent '''parallelepipeds''', whose faces comprise three pairs of equal parallelograms. Unlike a common box, those faces need not be rectangular—if they are, the enclosed volume is a rectangular parallelepiped.
 
** '''rpp''' shapes represent '''rectangular parallelepipeds''' (also known as '''cuboids''' and '''rectangular prisms'''), whose faces comprise three pairs of equal rectangles. If one pair of faces are squares, the volume is a '''square prism'''. If all of them are squares, the volume is a '''cube''' (geometrically, there cannot be just two pairs of square faces).
 
** '''rpp''' shapes represent '''rectangular parallelepipeds''' (also known as '''cuboids''' and '''rectangular prisms'''), whose faces comprise three pairs of equal rectangles. If one pair of faces are squares, the volume is a '''square prism'''. If all of them are squares, the volume is a '''cube''' (geometrically, there cannot be just two pairs of square faces).
  
* '''arb7''' shapes have seven unique vertices. They represent hexahedra that have four quadrilateral and two triangular faces sharing eleven edges. They can only be created by specifying the {X, Y, Z} coordinates of those vertices.
+
* '''arb7''' shapes represent hexahedra with four quadrilateral and two triangular faces. They have a total of eleven edges with seven unique vertices, one of which is shared by the two triangular faces. They can only be created by specifying the {X, Y, Z} coordinates of those vertices.
  
* '''arb6''' shapes have six unique vertices. They represent '''triangular prisms''' and '''truncated tetrahedra''', which are '''pentahedra''' that have two triangular ends connected by three quadrilateral sides sharing nine edges. In addition to simply specifying the {X, Y, Z} coordinates of their vertices, MGED provides an easier way to create one specific type of hexahedron:
+
* '''arb6''' shapes represent '''triangular prisms''' and '''truncated tetrahedra''', both of which have two triangular ends connected by three quadrilateral sides (its seems they should be called quintahedra but that term seems to be rarely used). Either has a total of nine edges with six unique vertices. In addition to simply specifying the {X, Y, Z} coordinates of their vertices, MGED provides an easier way to create one specific type of hexahedron:
 
** '''raw''' ('''right angle wedge''') shapes are '''triangular prisms''' whose ends are parallel to each other. Interestingly enough, they don't seem to require any right angles. If the ends are perpendicular to the connecting edges, the shape is a '''right triangular prism''' and has rectangular sides. Presumably two of the rectangular sides of an actual right-angle wedge would also be perpendicular to each other.
 
** '''raw''' ('''right angle wedge''') shapes are '''triangular prisms''' whose ends are parallel to each other. Interestingly enough, they don't seem to require any right angles. If the ends are perpendicular to the connecting edges, the shape is a '''right triangular prism''' and has rectangular sides. Presumably two of the rectangular sides of an actual right-angle wedge would also be perpendicular to each other.
  
* '''arb5''' shapes have five unique vertices. They represent '''quadrahedra''', which are pentahedra that have a quadrilateral base and four triangular sides sharing eight edges. If such a volume has a rectangular base it is a '''rectangular pyramid''', one with a square base is a '''square pyramid'''.
+
* '''arb5''' shapes represent '''quadrahedra''', which are polyhedra with five faces—a quadrilateral base and the three triangular sides. Each has a total of eight edges and five vertices. If such a volume has a rectangular base it is a '''rectangular pyramid''', one with a square base is a '''square pyramid'''.
  
* '''arb4''' shapes have four unique vertices. They represent '''tetrahedra''', which have four triangular faces sharing six edges. If all four triangles are equilateral, the shape is a '''regular tetrahedron'''.
+
* '''arb4''' shapes represent '''tetrahedra''', which have four triangular faces. If all four of them are equilateral, the shape is a '''regular tetrahedron'''.
  
 
== ARBN Records ==
 
== ARBN Records ==
Line 215: Line 215:
  
  
==brep==
+
==nurb==
[[NURBS|see NURBS]]
+
Non-uniform rational b-spline
 +
;Handled by: none?
  
 
==spline==
 
==spline==
Line 244: Line 245:
 
;Handled by: make form(sketch editor) create
 
;Handled by: make form(sketch editor) create
 
;See also: [[sketch]]
 
;See also: [[sketch]]
 
==annot==
 
2D annotation primitive
 
;Handled by: in command
 
See: [[annot]]
 
  
 
==grip ==
 
==grip ==
Line 267: Line 263:
 
;Handled by: in create (not edit!)
 
;Handled by: in create (not edit!)
 
;Arguments: minor type (fdcsiLCSIL), data file, number of values
 
;Arguments: minor type (fdcsiLCSIL), data file, number of values
 
== submodel ==
 
Instanced Submodel
 
:Handled by: in make form create
 
:Arguments:
 
;file: File holding the referenced geometry. 0-length if geometry is in the same file.
 
;treetop: Single name for the geometry to reference.
 
A submodel is a reference to another geometry, possibly in a separate file.
 

Please note that all contributions to BRL-CAD may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see BRL-CAD:Copyrights for details). Do not submit copyrighted work without permission!

To edit this page, please answer the question that appears below (more info):

Cancel Editing help (opens in new window)