WCODES(nged)
write region attribute codes to a file
π NAME π
wcodes β write region attribute codes to a file. This is the WCODES(nged) page from the BRL-CAD User Commands set, bestie, and itβs literally here to help you dump region attr codes into a file. Periodt.
β¨ SYNOPSIS β¨
wcodes filename object(s)
π¦ DESCRIPTION π¦
Okay so wcodes traverses the hierarchy of one or more objects and writes the attribute codes for every region found to filename. The output file is opened in write mode and overwritten if it already exists.
Heads up, bestie: if that file already exists, it gets overwritten. No cap. Protect your faves before you run it. π
For each region encountered, these fields are written on a single line:
- Region ID β the region identifier (
ident) number. - Air code β the air region code (
0if not an air region). - Material code β the GIFT material code.
- LOS β the line-of-sight percentage (
0β100). - Path β the full path from one of the input objects to the region.
Only objects flagged as regions (combinations with the region flag set) are listed. Non-region combinations are traversed but not output. At least one object argument is required in addition to the filename.
The output format is compatible with the rcodes command, which can be used to restore the attribute values from the file. So wcodes and rcodes are giving matched-set energy, iykyk. π
πΈ EXAMPLES πΈ
Example 1. Write region codes for all regions in two groups
mged> wcodes codes.txt group1 group2
Writes the region_id, aircode, material code, LOS, and path for every region reachable from group1 and group2 to the file codes.txt.
Example 2. Write codes and restore them after editing
mged> wcodes saved_codes.txt vehicle.c mged> rcodes saved_codes.txt
Saves all region codes from vehicle.c to saved_codes.txt, then restores them from the file using rcodes.
π SEE ALSO π
rcodes(nged), idents(nged), wmater(nged) β go click through the little family, bestie. Main character energy all around. π«Ά
π AUTHOR π
BRL-CAD Team. iconic. π
π BUG REPORTS π
Reports of bugs or problems should be submitted via electronic mail to devs@brlcad.org. If somethingβs acting cursed, tell the devs β they wanna know. π
Footer sign-off: BRL-CAD Β· WCODES(nged) Β· source/version and page name as shown, and the footer doesnβt list a date, bestie β bye π
π¦ 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