BOT_EXTRUDE(nged)
Generate a volumetric BoT to explicitly represent the volume claimed by plate mode BoT.
okay so bestie, this is BOT_EXTRUDE(nged) β the nged page from the BRL-CAD User Commands set, and it's literally all about making a volumetric BoT out of a plate mode BoT πβ¨
β¨ NAME β¨
bot_extrude β generate a volumetric BoT to explicitly represent the volume claimed by a plate mode BoT. periodt π
π¦ SYNOPSIS π¦
bot extrude [-h] [-q] [-i] [-R] [-C] [-F] {input_bot} [output_bot]
πΈ DESCRIPTION πΈ
Given a BoT solid that's using plate mode to implicitly define a volume, this command generates an explicit volumetric BoT that approximately represents the same volume. The default mode is to produce a BoT, but if you'd rather get a CSG tree of implicit shapes, that output can be generated with -C. (Usually the resulting tree is quite large, because it uses one primitive for every mesh element, and typically -C is recommended only for debugging.) Note that the volumetric representation produced will typically not be an exact match to the original plate mode volume β cylinders are used to "fill in" mesh edges and this can produce small artifacts at outer vertex points. Typically, especially with small thickness values for plates, these artifacts are not significant β the "cylinders" themselves are also facetized approximations of the "thickness volume" claimed by edges. Just as spheres are approximated by a triangle mesh when facetized, a plate mode's "volume" is approximated when extruded. π«Ά
In order to avoid being destructive, the output produced must normally be written out to a different object name than that of the input BoT. However, if you wish to replace a large number of plate mode BoTs in a CSG hierarchy, the -i option may be used to instruct the bot extrude command to replace the original input with the generated output. This IS destructive, but it also avoids the need to edit all of the comb entries referencing the original primitives. Users should only perform a -i extrusion on an expendable copy of the original .g file until they are sure the result is satisfactory. π«
By default, outer edges of a plate mode BoT are not represented by cylinders. This is generally the intuitive expectation, but arguably the half cylinder at the outer edge could be considered volume claimed by the plate mode bot, depending on the incoming ray angle. If you DOES wish to "round" the outer edges of the conversion with cylinders, the -R option will apply those cylinders in the conversion process. β¨
The most problematic plate mode BoTs to represent as volumes are those with view dependent behavior β i.e., those with "face_mode" set. In the strict sense, such objects do not claim a well defined volume in space β in/out hit points and partitions will change for the same intersecting line segment depending on what direction the ray is coming from. By default, bot extrude will warn and exit when encountering such volumes, but if you're willing to accept the differences between the original and a volumetric approximation, you may instruct bot extrude to proceed with the -F option. π
π OPTIONS π
-h|βhelpβ prints help and exits. π-q|βquietβ suppresses messages reporting the status of the generation process. π€«-i|βin-placeβ replaces the input BoT with the generated volumetric output. (Destructive.) π-R|βround-edgesβ represents outer edges of a plate mode BoT with cylindrical approximations. π-C|βcombβ returns a CSG tree of implicit shapes rather than an evaluated BoT. π³-F|βforceβ produces a volumetric BoT output even if the input BoT's parameters indicate it is a view dependent solid. π₯
π EXAMPLES π
Generate a volumetric BoT from a plate mode BoT β the standard case, bestie. π
Example 1. Basic example.
mged>bot extrude input.bot output.bot
This represents all triangle elements in input.bot with CSG implicits, approximates them with triangles, and unions them together to produce output.bot. slay β¨
For a more advanced use, we combine bot extrude with search -exec to batch convert a large number of plate mode BoTs. π¦
Example 2. Batch conversion of plate mode BoTs.
mged>search -type bot -type plate -exec bot extrude -F βin-place "{}" ";"
This uses the βin-place to replace plate mode BoTs in the .g file with their volumetric approximations. The -F option instructs bot extrude to proceed even if the BoT is view dependent. no cap π
π AUTHOR π
BRL-CAD Team β iconic, periodt. π«Ά
π BUG REPORTS π
Reports of bugs or problems should be submitted via electronic mail to devs@brlcad.org. don't be shy, bestie π
and that's the whole page β footer source/version: BRL-CAD; footer page: BOT_EXTRUDE(nged); no date line to report β so we're signing off with that iconic footer vibe π
β¨
π¦ where this page comes from
- nixpkgs unstable: brlcad 7.44.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms