Skip to documentation
DocumentationAll documentsEnglish

SHOWSHOT(1)

NAME

showshot - generate MGED commands representing a ray through some geometry

On this page

SYNOPSIS

showshot [-n name] [-r radius] [-?] < input

DESCRIPTION

showshot reads the description of a ray through some geometry on standard input and writes mged(1) commands to standard output that build a database object representing that ray. Each line of input must have the form

object  x_in  y_in  z_in  x_out  y_out  z_out

as produced by nirt(1), where object is the name of a database object along the ray and (x_in, y_in, z_in) and (x_out, y_out, z_out) are the ray’s entry and exit points for that object. The first and last lines of input must correspond to the first and last objects encountered along the ray; the intervening lines may appear in any order.

showshot emits commands to create an RCC whose vertex is the entry point of the first object and which extends to the exit point of the last object (all other coordinates are ignored). It then makes the RCC a member of a region colored yellow (255 255 0) and creates a group containing the ray region along with every object named in the input.

OPTIONS

-n name

Use name as the root for the generated object names: the ray solid is name.s, the ray region is name.r, and the group is name. The default is ray.PID, where PID is the process ID of showshot.

-r radius

Set the radius of the RCC representing the ray, in database units. The default is 1.

-?

Print a usage message and exit.

EXAMPLES

Example 1. Visualize a NIRT shotline in MGED
nirt -b -f entexit.nrt model.g component > shot.txt
showshot -n shotline -r 0.5 < shot.txt > shot.mged
mged model.g < shot.mged

Fire a ray through component with nirt(1) using a format that prints the entry and exit points of each partition, convert that report into a thin (radius 0.5) yellow ray named shotline with showshot, then source the generated commands back into mged(1) to draw the ray alongside the model.

SEE ALSO

brlcad(1), mged(1), nirt(1)

AUTHOR

BRL-CAD Team

This software is Copyright (c) 1991-2026 by the United States Government as represented by U.S. Army Research Laboratory.

BUG REPORTS

Reports of bugs or problems should be submitted via electronic mail to devs@brlcad.org