'\" t
.\"     Title: BREP
.\"    Author: [see the "AUTHOR" section]
.\" Generator: DocBook XSL-NS Stylesheets v1.76.1 <http://docbook.sf.net/>
.\"      Date: 04/13/2022
.\"    Manual: BRL-CAD MGED User Commands
.\"    Source: BRL-CAD
.\"  Language: English
.\"
.TH "BREP" "nged" "04/13/2022" "BRL\-CAD" "BRL\-CAD MGED User Commands"
.\" -----------------------------------------------------------------
.\" * Define some portability stuff
.\" -----------------------------------------------------------------
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.\" http://bugs.debian.org/507673
.\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
.\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
.ie \n(.g .ds Aq \(aq
.el       .ds Aq '
.\" -----------------------------------------------------------------
.\" * set default formatting
.\" -----------------------------------------------------------------
.\" disable hyphenation
.nh
.\" disable justification (adjust text to left margin only)
.ad l
.\" -----------------------------------------------------------------
.\" * MAIN CONTENT STARTS HERE *
.\" -----------------------------------------------------------------
.SH "NAME"
brep \- This command does a boundary representation which represents the solid geometry by describing the topology and corresponding geometry\&.
.SH "SYNOPSIS"
.HP \w'\fBbrep\fR\ 'u
\fBbrep\fR {\fIobj\fR} [\-\-no\-evaluation] [\fIcommand\fR | \fIbrepname\fR | \fIsuffix\fR]
.SH "DESCRIPTION"
.PP
If
\fIobj\fR
is not a brep object, then
\fBbrep\fR
attempts to convert it to a brep object\&. If
\fIbrepname\fR
is given, then
\fBbrep\fR
defaults to
\fIobj\fR_brep; if \-\-no\-evaluation is given, then
\fBbrep\fR
attempts to convert a combination to an unevaluated BREP named
\fIsuffix\fR
(again defaulting to
\fIobj\fR_brep)\&.
.PP
Otherwise, the behavior of
\fBbrep\fR
is determined by which of these subcommands is specified:
.HP \w'\fBinfo\fR\ 'u
\fBinfo\fR
.PP
.RS 4
Return count information (surfaces, curves, etc\&.) for a BREP\&.
.RE
.HP \w'\fBinfo\ C\fR\ 'u
\fBinfo C\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Return information for a specific BREP \*(Aq3D curve\*(Aq\&.
.RE
.HP \w'\fBinfo\ S\fR\ 'u
\fBinfo S\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Return information for a specific BREP \*(Aqsurface\*(Aq\&.
.RE
.HP \w'\fBinfo\ F\fR\ 'u
\fBinfo F\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Return information for a specific BREP \*(Aqface\*(Aq\&.
.RE
.HP \w'\fBinfo\ T\fR\ 'u
\fBinfo T\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Return information for a specific BREP \*(Aqtrim\*(Aq\&.
.RE
.HP \w'\fBinfo\ E\fR\ 'u
\fBinfo E\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Return information for a specific BREP \*(Aqedge\*(Aq\&.
.RE
.HP \w'\fBinfo\ TB\fR\ 'u
\fBinfo TB\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Return information for a specific BREP \*(Aqpiecewise bezier trim\*(Aq\&.
.RE
.HP \w'\fBinfo\ SB\fR\ 'u
\fBinfo SB\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Return information for a specific BREP \*(Aqpiecewise bezier surface\*(Aq\&.
.RE
.HP \w'\fBplot\ S\fR\ 'u
\fBplot S\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqsurface\*(Aq\&.
.RE
.HP \w'\fBplot\ Suv\fR\ 'u
\fBplot Suv\fR {\fIindex\fR | \fIindex\fR\-\fIindex\fR} {\fIu\fR} {\fIv\fR}
.PP
.RS 4
Plot a specific BREP \*(Aqsurface\*(Aq 3d point at specified uv\&.
.RE
.HP \w'\fBplot\ UV\fR\ 'u
\fBplot UV\fR {\fIindex\fR | \fIindex\fR\-\fIindex\fR} {\fIu1\fR} {\fIu2\fR} {\fIv1\fR} {\fIv2\fR}
.PP
.RS 4
Plot a specific BREP \*(Aqsurface\*(Aq 3d bounds at specified uv bounds\&.
.RE
.HP \w'\fBplot\ F\fR\ 'u
\fBplot F\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqface\*(Aq\&.
.RE
.HP \w'\fBplot\ I\fR\ 'u
\fBplot I\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqisosurface\*(Aq\&.
.RE
.HP \w'\fBplot\ SN\fR\ 'u
\fBplot SN\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqsurface normal\*(Aq\&.
.RE
.HP \w'\fBplot\ KN\fR\ 'u
\fBplot KN\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqsurface knot\*(Aq\&.
.RE
.HP \w'\fBplot\ F2d\fR\ 'u
\fBplot F2d\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqface in 2d\*(Aq\&.
.RE
.HP \w'\fBplot\ SBB\fR\ 'u
\fBplot SBB\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqsurfaceleafs\*(Aq\&.
.RE
.HP \w'\fBplot\ SBB2d\fR\ 'u
\fBplot SBB2d\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqsurfaceleafs in 2d\*(Aq\&.
.RE
.HP \w'\fBplot\ TD\fR\ 'u
\fBplot TD\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqtrim direction\*(Aq\&.
.RE
.HP \w'\fBplot\ T\fR\ 'u
\fBplot T\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqtrim\*(Aq\&.
.RE
.HP \w'\fBplot\ T2d\fR\ 'u
\fBplot T2d\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqtrim in 2d\*(Aq\&.
.RE
.HP \w'\fBplot\ TBB\fR\ 'u
\fBplot TBB\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqtrimleafs\*(Aq\&.
.RE
.HP \w'\fBplot\ TBB2d\fR\ 'u
\fBplot TBB2d\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqtrimleafs in 2d\*(Aq\&.
.RE
.HP \w'\fBplot\ E\fR\ 'u
\fBplot E\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqedge3d\*(Aq\&.
.RE
.HP \w'\fBplot\ SCV\fR\ 'u
\fBplot SCV\fR [\fIindex\fR | \fIindex\fR\-\fIindex\fR]
.PP
.RS 4
Plot a specific BREP \*(Aqnurbs control net\*(Aq\&.
.RE
.HP \w'\fBflip\fR\ 'u
\fBflip\fR
.PP
.RS 4
Flip all faces in the BREP (turns it \*(Aqinside out\*(Aq)\&.
.RE
.HP \w'\fBtranslate\fR\ 'u
\fBtranslate\fR {\fISCV\fR} {\fIindex\fR} {\fIi\fR} {\fIj\fR} {\fIdx\fR} {\fIdy\fR} {\fIdz\fR}
.PP
.RS 4
Translate a surface control vertex
.RE
.HP \w'\fBintersect\fR\ 'u
\fBintersect\fR {\fIobj2\fR} {\fIi\fR} {\fIj\fR} [PP | PC | PS | CC | CS | SS]
.PP
.RS 4
Visualize intersecting two BREP objects\&. The last argument specifies what portions of each to intersect; if it is not specified, it defaults to SS:
.PP
PP
.RS 4
Intersect a point from the first object with a point from the second\&.
.RE
.PP
PC
.RS 4
Intersect a point from the first object with a curve from the second\&.
.RE
.PP
PS
.RS 4
Intersect a point from the first object with a surface from the second\&.
.RE
.PP
CC
.RS 4
Intersect a curve from the first object with a curve from of the second\&.
.RE
.PP
CS
.RS 4
Intersect a curve from the first object with a surface from the second
.RE
.PP
SS
.RS 4
Intersect a surface from the first object with a surface from the second\&.
.RE
.sp
.RE
.HP \w'\fBu\fR\ 'u
\fBu\fR {obj2} {output}
.PP
.RS 4
Take the union of
\fIobj\fR
and
\fIobj2\fR, storing the result in
\fIoutput\fR\&.
.RE
.HP \w'\fBi\fR\ 'u
\fBi\fR {obj2} {output}
.PP
.RS 4
Take the intersection of
\fIobj\fR
and
\fIobj2\fR, storing the result in
\fIoutput\fR\&.
.RE
.HP \w'\fB\-\fR\ 'u
\fB\-\fR {obj2} {output}
.PP
.RS 4
Take the difference of
\fIobj\fR
and
\fIobj2\fR, storing the result in
\fIoutput\fR\&.
.RE
.HP \w'\fBx\fR\ 'u
\fBx\fR {obj2} {output}
.PP
.RS 4
Take the exclusive or of
\fIobj\fR
and
\fIobj2\fR, storing the result in
\fIoutput\fR\&.
.RE
.HP \w'\fBcsg\fR\ 'u
\fBcsg\fR
.PP
.RS 4
Take the specified B\-Rep and attempt to generate a CSG implicit boolean tree that will define the same solid shape\&.
.RE
.SH "EXAMPLES"
.PP
\fBExample\ \&1.\ \&Info\fR
.PP
mged> \fBbrep obj\&.randomobj info\fR
.RS 4
This outputs general information about obj\&.randomobj, including counts of various entity types such as surfaces, curves, vertices, etc\&.
.RE
.PP
mged> \fBbrep obj\&.randomobj info F 2\fR
.RS 4
Output info about the 2nd face of the BREP object obj\&.randomobj\&.
.RE
.PP
\fBExample\ \&2.\ \&Plot\fR
.PP
mged> \fBbrep obj\&.randomobj plot S 1\-3\fR
.RS 4
This plots the 1st through 3rd surfaces of obj\&.randomobj in the graphics display window\&.
.RE
.PP
\fBExample\ \&3.\ \&Intersect\fR
.PP
mged> \fBbrep obj\&.randomobj intersect sph2\&.randomobj 2 4\fR
.RS 4
This displays the intersection of obj\&.randomobj\*(Aqs 2nd surface with sph2\&.randomobj\*(Aqs 4th surface\&.
.RE
.PP
mged> \fBbrep obj\&.randomobj intersect sph2\&.randomobj 3 2 PC\fR
.RS 4
This displays the intersection of obj\&.randomobj\*(Aqs 3rd point with sph2\&.randomobj\*(Aqs 2nd curve\&.
.RE
.SH "AUTHOR"
.PP
BRLCAD\-TEAM
.SH "BUG REPORTS"
.PP
Reports of bugs or problems should be submitted via electronic mail to
devs@brlcad\&.org
