G-NFF(1)
β¨ G-NFF(1) β the BRL-CAD to Neutral File Format glow-up β¨
okay so bestie, quick vibe check: this is a page from the BRL-CAD manual set, and it's about a lil tool called g-nff π
πΈ NAME πΈ
g-nff β the BRL-CAD β Neutral File Format (NFF) translator, aka your geometry's passport to renderer-land πβ¨
π SYNOPSIS π
g-nff [-v] [-i] [-x rt_debug] [-X nmg_debug] [-e error_file] [-D dist_tol] [-a abs_tol] [-r rel_tol] [-n norm_tol] -o output.nff database.g object ...
like, that's the whole shape of it. flags first, then -o output.nff, then your database.g, then however many objects you feel like naming π
π¦ DESCRIPTION π¦
g-nff takes the geometry object(s) you point at inside a BRL-CAD database.g file and converts them over to Neutral File Format (NFF). it's giving translator era π«Ά
here's the tea on how it does it: each region gets evaluated with the NMG boolean routines, then triangulated, then written out as a set of NFF polygons β each one tagged with the region's color so your renderer knows what's what π¨
and because it's an absolute icon, g-nff also computes a bounding box for the geometry and drops a default 45-degree view, a light, and 512x512 resolution into the output file β so the result can go straight to rendering with no extra setup. main character energy fr fr π
π OPTIONS π
-ooutput.nff β names the output NFF file. this one is required, no cap, you literally cannot skip it π-iβ treat the output as being in inches. the default is millimeters, iykyk π-aabs_tol β sets the absolute tessellation tolerance, in millimeters. heads up: setting this disables the relative tolerance β οΈ-rrel_tol β sets the relative tessellation tolerance as a fraction of the bounding box diagonal. the default is0.01π«-nnorm_tol β sets the surface normal tessellation tolerance, in degrees. setting this disables the relative tolerance too β οΈ-Ddist_tol β sets the calculational distance tolerance in millimeters, used when deciding whether two points are coincident π―-eerror_file β redirects error messages into error_file instead of standard error. very demure, very tidy π-vβ turns on verbose progress reporting. she'll narrate her whole journey to you π£οΈβ¨-xrt_debug β sets the librt debug flags, given as a hexadecimal value π§-Xnmg_debug β sets the libnmg debug flags, given as a hexadecimal value π§-h,-?β prints the usage message and dips π
π EXAMPLES π
Example 1. Convert selected regions to a renderable NFF file
g-nff -a 0.5 -o engine.nff engine.g block piston
so what's happening here: it tessellates the block and piston regions from engine.g using a 0.5 mm absolute tolerance, then writes the triangulated geometry β plus a default view and light β into engine.nff, all ready to be handed to an NFF-capable renderer. literally plug and play π₯
π SEE ALSO π
go read those too, bestie, they're the whole friend group π«Ά
β AUTHOR β
the BRL-CAD Team π
π COPYRIGHT π
This software is Copyright (c) 1989-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 π¬ β they're genuinely lovely about it, promise.
and that's the page! courtesy of BRL-CAD, same G-NFF(1) energy as always β mwah, go convert something cute ππβ¨
π¦ 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