Solid modeling for OpenUSD. USD BRep creates and edits
boundary-representation (BRep) solids and reads and writes them in USD as
BrepArray prims.
BRep faces and edges can be NURBS or analytic geometry. Plane, cylinder, cone, sphere and torus faces are written to USD as analytic surfaces. Edge curves are written as NURBS; analytic line, circle and ellipse edges in USD from other tools are read as analytic curves. Other SMLib types, such as parabolas and surfaces of revolution, are written as NURBS. See supported geometry for the SMLib class names.
Libraries and tools that work on BReps stored in USD files:
- USD BRep schema (omniSolid): defines the
BrepArrayprim, which stores BReps in USD with their full topology and NURBS or analytic geometry; see the proposal and its problem statement. - Import/export: reads
BrepArrayprims into SMLib BReps and writes SMLib BReps back to USD. - USD Validator: checks that the BReps in a USD file comply with the BRep schema.
- Healer: heals the BReps across a whole USD scene, preserving layers, references, instancing, transforms and materials.
- Geometry validator: runs AssertValid (see Kernel) on every
BrepArrayprim in a USD file. - Tessellator: writes a
UsdGeomMeshfor each BRep in theBrepArrayprims of a USD file. - Viewers:
- Converters:
- OpenCASCADE: occt_to_usd and usd_to_occt convert between OpenCASCADE and USD BReps.
- Utility libraries: BREP_USD_DATA, BREP_STAGING and USD_BREP_UTILS support writing USD converters to and from other formats.
- APIs: C++ and Python (USD).
The SMLib kernel, and tools that work on BReps in memory:
- Kernel (SMLib): creates and edits BRep solids, with booleans, fillets, sweeps and offsets.
- Healer: fixes common geometric and topological defects in BReps.
- Tessellator: meshes BReps into triangles. The Hydra plugin uses it to draw BReps in usdview.
- Geometry validator (AssertValid): checks the geometric quality and topological consistency of BReps in memory.
- APIs: C++ and Python (SMLib).
- Examples: runnable Python and C++ examples for each API layer.
Guidance for coding agents, starting from AGENTS.md:
- Docs: the library's layers and key concepts, what each error code means and how to fix it.
- Operations: a guide for each API area, such as booleans, fillets, tessellation, healing and USD import/export.
- Skills: workflows for debugging kernel operations, using and maintaining the C++ and Python APIs, working with the USD schema and converters, choosing tests and writing bug reports.
nvidia-omniverse.github.io/usd-brep, including the Python and C++ API reference.
The Python package is on PyPI for CPython 3.12 on Linux (x86_64, aarch64) and Windows:
pip install usd-brepimport usd_brep
sphere = usd_brep.primitives.create_sphere((0.0, 0.0, 0.0), 1.0)
box = usd_brep.primitives.create_box((0.0, 0.0, 0.0), 1.0, 1.0, 1.0)
cut = usd_brep.booleans.boolean_difference(sphere, box) # a sphere missing one octant
usd_brep.usd.export_brep(cut, "cut.usda")
(brep,) = usd_brep.usd.import_breps("cut.usda")To repair the BReps in an existing USD scene, usd.heal_file heals the BrepArray
geometry in the layers the scene uses and writes the scene with its layers,
references, instancing, transforms and materials kept:
usd_brep.usd.heal_file("input.usdc", "input_healed.usdc")See the package README for the API's submodules and Examples for runnable examples in Python and C++.
- Known issues: KNOWN_ISSUES.md, and the open issues on GitHub.
- Fixed issues: the "Fixed" sections of the CHANGELOG, and the closed issues on GitHub.
To build the libraries, tests and tools yourself, see BUILDING.md. It covers requirements for Linux, Windows and macOS, building, testing, viewing BReps in usdview and the Python GUI.
This project is currently not accepting contributions.
Issues and bug reports are welcome through the issue tracker, and security
issues should be reported as described in SECURITY.md. See CONTRIBUTING.md for
details.
USD BRep is licensed under the Apache License, Version 2.0. See LICENSE for the terms governing use, reproduction, and distribution.
Copyright (c) 2020-2026, NVIDIA CORPORATION & AFFILIATES. All rights reserved.
repo.sh, repo.bat, and tools/repoman/repoman_bootstrapper.py are licensed
under the MIT License instead; see THIRD_PARTY_NOTICES.md for the full text.
For third-party notices and bundled components, see THIRD_PARTY_NOTICES.md.