Expand description
OpenRocket’s .orc parts catalogs: nose cones, tubes, rings, transitions, parachutes and
streamers as their makers sell them, by maker and part number.
A .orc file is XML: an <OpenRocketComponent> root holding a <Version>, a <Materials>
list (each a name, a density, the density’s units and its kind: BULK, SURFACE or LINE)
and a <Components> list of parts. A part names its maker, part number and description, its
dimensions each with its own Unit attribute, and its material by name and kind; the material
must be defined in the same file. The format has no published schema; its field list and units
are the ones the openrocket-database project documents (docs/TechnicalInfo.md at the pinned
commit), and what each field means is what OpenRocket 24.12’s preset loader makes of it,
measured by running that loader on the same files as an oracle
(validation/oracles/openrocket/orc_presets.py).
read reads one file into a Catalog. bundled is the catalog OpenRocket 24.12
ships: the 16 files of openrocket-database (Apache-2.0) at the commit
validation/refs.lock.toml pins, compiled into this crate unchanged, 3,449 parts.
Catalog::find looks a part up by maker and part number.
What is read, and how far it agrees with OpenRocket. Every value is converted to SI as the
file states it: lengths in meters, masses in kilograms, densities in kg/m³, kg/m² or kg/m. On
the bundled files, every part OpenRocket reads is read here, in the same order, and every
value equals OpenRocket’s bit for bit (17,911 of 18,306 numbers), with four exceptions that the
test crates/hpr-io/tests/orc_openrocket.rs counts:
- Ounces. OpenRocket’s ounce is 0.0283495231 kg; the avoirdupois ounce is exactly
0.028349523125 kg (NIST Handbook 44, Appendix C), and that is the one used here. The
difference is 9e-10 of the value, on the 185 masses stated in ounces. OpenRocket rounds a
few other imperial factors the same way (
lb/ft³,oz/in²,oz/ft²,lb/ft²,oz/ft); no bundled file uses them. - Makers’ names. OpenRocket shows two makers under names of its own: “LOC Precision” as “LOC/Precision” and “Public Missiles” as “Public Missiles, Ltd.” The name here is the file’s.
- A stated mass. When a solid part states its mass, OpenRocket replaces its material’s
density with the one that gives the part that mass. Here the material keeps the file’s
density and the part keeps its mass (
Part::mass_kg), which a design built from the part by hand can set as its mass. This is 207 parts; with the masses taken out of the files, OpenRocket’s density is the one read here on every one of them. A parachute’s or streamer’s stated mass leaves its fabric’s density alone, here and in OpenRocket. - Undefined materials. A material the file names but doesn’t define has no density here
(
MaterialRef::densityisNone); OpenRocket gives it zero. This is 3 parts.
What the file leaves unsaid. No .orc field gives a nose or transition shape’s parameter
(an ogive’s radius, a Haack series’ C), a shoulder’s wall, or a parachute’s drag coefficient;
OpenRocket uses its own defaults for these when a part is put in a design. A part’s material
is only as good as the file’s density, and the database’s own README warns to weigh real parts.
Warnings. A part or material that can’t be read is left out with a Warning saying why,
rather than failing the file; so are fields ignored or repeated, and values read as written but
implausible (an inside diameter not less than the outside, a solid lighter than air, a fabric
under 1 g/m²). The bundled files give 55.
Structs§
- Bulkhead
- A bulkhead: a solid disc.
- Catalog
- Parts, from one catalog file or several.
- Catalog
File - A catalog file read, with what was left out of it.
- Catalog
Material - A material a catalog file defines.
- Material
Ref - The material a part names, with the density its file defines for it.
- Nose
Cone - A nose cone.
- Parachute
- A parachute.
- Part
- One part as its catalog lists it.
- Streamer
- A streamer.
- Transition
- A transition.
- Tube
- A tube-like part: a body tube, coupler, engine block, centering ring or launch lug.
- Warning
- Something read differently from what the file says, or left out. Reading goes on.
Enums§
- Material
Kind - The kind of density a material has.
- OrcError
- A
.orcfile that can’t be read at all. - Part
Kind - A part’s kind and dimensions.
- Shape
- A nose cone’s or transition’s profile, as the file names it.
- Warning
Kind - What a
Warningis about.
Constants§
- BUNDLED_
FILES - The
openrocket-databaseproject’s catalog files (Apache-2.0; the license isdata/openrocket-database/LICENSEbeside them), unchanged, at the commitvalidation/refs.lock.tomlpins (1512874a, 2025-07-27), which OpenRocket 24.12 ships byte for byte: each name with its text, in byte order of the names.generic_materials.orcdefines materials and no parts. - MAX_
DEPTH - The deepest nesting read. A
.orcnests four deep (the root, the parts list, a part, its field); the parser below has been seen to exhaust a 2 MiB stack at 130 levels (the.orkreader’s measurement,crate::ork::MAX_DEPTH). - MAX_
WARNINGS - The most warnings one file gives; past it, one last warning says how many more there were.
Functions§
- bundled
- Every part of
BUNDLED_FILES, file by file in their order: 3,449 parts. Read once, on the first call. The files’ 55 warnings are dropped here;readeach ofBUNDLED_FILESto see them. - read
- Reads one
.orcfile’s text;filenames it in eachPart::file.