# Changelog ## [1.0.2] - 2026-11-18 ### Added - The kernel (SMLib, SM_API) and its C++ tests build for Android arm64 with the Android NDK, using the existing premake build; see `BUILDING.md`. There is no USD, OCCT or Python support on Android. - The wheel installs a `usd-brep-heal` command, the same healer as `tools/scripts/usd_brep_heal.py` in the binary package (`usd.heal_file` on a file). - The wheel includes a short `brep_usdschema_validator` README: what the schema rules check, the `[validation]` extra, and how to run them. - `usd.validate_geometry_file` (`SmApiUsdValidateGeometryFile`): run `SmBrep::AssertValid` on every BrepArray prim in a USD file. The wheel installs it as the `usd-brep-validate-geometry` command. It finds prims the same way as `brep_geometry_validator` (`SmApiUsdFindGeometryPrims`): active BrepArray prims and active prims with a `brep:regionCount` attribute, including those inside nested instances. ### Changed - `BrepUsdSchemaValidator` runs in the validation engine's worker processes (`nvidia_usd_validate --process N`, `ValidationEngine(processes=N)`). It was not marked safe for them, so the engine ran it in the main process, and it could not have run in a worker: the rule could not be pickled, and a spawned worker did not have the omniSolid schema. `register_omnisolid_schema` now also adds the schema to `PXR_PLUGINPATH_NAME` for child processes. - The BrepArray USD schema validator is renamed so it cannot be mistaken for the Brep geometry validator (`usd.validate_geometry_file`, `brep_geometry_validator`): the package `brep_validator` is now `brep_usdschema_validator`, `BrepValidator` is `BrepUsdSchemaValidator`, `BrepValidatorPlugin` is `BrepUsdSchemaValidatorPlugin`, `BrepValidationResult` is `UsdSchemaValidationResult` and `validate_file` is `usdschema_validate_file`. `import brep_validator` no longer works. The directories `brep_validator_cli` and `brep_validator_test` are now `brep_usdschema_validator_cli` and `brep_usdschema_validator_test`. `nvidia_usd_validate` reports the rules as `BrepUsdSchemaValidator`, so a configuration that names the old class must change. - `SmBSplineCurve::AssertValid` no longer searches each curve for its smallest radius of curvature, so it is faster: about 6 times on the curves of a sample of production parts, with the same results. The search's result was never used, so assertions 13 and 14 (small radius of curvature) were never reported, and a small radius is valid geometry. ([GitHub #27](https://github.com/NVIDIA-Omniverse/usd-brep/issues/27)) - `SmBrep::AssertValid`, and so `usd.validate_geometry_file` and the developer `assert_valid` binding, no longer modifies curves. When the control points of an edge or trim curve folded back at an end, the check moved the control point next to that end (and set its weight to 1 on a rational curve) as well as warning; it now only warns. Its result is the same. `remove_fillet` (`SmApiRemoveFillet`) validates the Brep it builds, so it no longer straightens such curve ends as a side effect. - macOS builds no longer fuse multiply-adds (`-ffp-contract=off`), as Linux aarch64 builds already did, so Apple silicon gives the same results as x86-64 and Windows. With fused multiply-adds, marginal geometry could take a different branch, for example a different tessellation triangle count. ([GitHub #31](https://github.com/NVIDIA-Omniverse/usd-brep/issues/31)) - The wheel's `PACKAGE-LICENSES` holds only the license texts for what it ships: OpenUSD (with the code it embeds), oneTBB, pybind11 and, on Windows, hwloc. It used to copy every text in the OpenUSD package, including Alembic, MaterialX, OpenSubdiv, OpenSSL and Python, none of which the wheel ships. The binary package is unchanged. - The release packages bundle the CPython 3.12.16 runtime library (was 3.12.15), for its security fixes. ### Fixed - `THIRD_PARTY_NOTICES.md` now lists libaom and libavif, which OpenUSD's `hioAvif` image plugin in the release packages contains, with libaom's Alliance for Open Media Patent License 1.0. - Windows wheels include the oneTBB and hwloc license texts when their DLLs are staged beside first-party libraries. - Copying cached face properties with nonempty seam-touch lists no longer overruns those arrays and corrupts memory. - `create_cylindrical_box` (`SmApiCreateCylindricalBox`) now constructs full hollow cylinders for 360-degree sweeps, including sweeps within 0.0001 degrees of a full turn from either side. Full turns use circular boundaries and annular caps instead of degenerate three-point arcs and coincident radial end faces. ([GitHub #22](https://github.com/NVIDIA-Omniverse/usd-brep/issues/22)) - Deleting the last owner of an attribute skipped the attribute's virtual `SmAttribute::RemoveUser`, so a derived attribute that tracks its owners kept a pointer to the deleted object. ([GitHub #45](https://github.com/NVIDIA-Omniverse/usd-brep/issues/45)) - Sheets merged into a closed shell by `merge_breps` (`SmApiMergeBreps`), such as an open tube and two caps, read as a manifold solid with zero volume, and `stitch_into_solid` did not change that: the merge marks the enclosed region as a void. `stitch_into_solid` (`SmApiStitchIntoSolid`) now makes that region solid, also when the merge includes a solid (a cavity stays void), and `is_manifold_solid()` (`SmApiBrepIsManifoldSolid`) returns False for a Brep with no solid region. ([GitHub #39](https://github.com/NVIDIA-Omniverse/usd-brep/issues/39)) - Transforming a Brep (`SmBrep::Transform`, as used for a reflection, a rotation or a scale) set its tolerances from the box of its vertices alone. A torus has a single vertex, so every tolerance became 0 and the Brep then failed validation and export with a tolerance error. A very flat cylinder, whose two vertices are far closer together than the body is wide, got a tolerance that was too tight, or 0. The size now comes from the whole body, and a transform that does not change distances (a rotation, a translation, a reflection, including a scale of 1 or -1 on each axis as from `SmApiScale`) leaves the tolerances as they are. ([GitHub #37](https://github.com/NVIDIA-Omniverse/usd-brep/issues/37)) - `boolean_2d` (`SmApiBoolean2d`) crashed when an operand was NULL (`None`), and given the same Brep as both operands it reported success but returned a Brep it had deleted. Both now fail with `SM_ERR_INVALID_INPUT`. - Debug builds: four debug messages in `SmTess.cpp` and `SmProtoTopology.cpp` were formatted into 256-character buffers (`SM_MAXSIZE`, the file line length) while the formatting calls allowed 1024 characters. Two `SmTess.cpp` messages could write past their buffers: a trim-curve warning for UV values around 1e30 or larger, and an assertion message for a distance around 1e142 or larger, as from corrupt geometry. The buffers are now `SM_TBLOCK_SIZE` (1024), like the kernel's other message buffers. - Writing a Brep to a native file (`Brep.write_to_file`, `SmApiWriteBrepToFile`) and writing or reading a part file (`SmBrepData::WritePartToFile`, `read_part_from_file`, `SmApiReadPartFromFile`) leaked memory for each edge, loopuse and mate edgeuse that carried attributes, also when the read failed. - `SM_SPRINTF` (`SmTypes.h`) passed 1024 as the size of every destination, so a longer string could write past a smaller array. It now passes the array's own length and truncates, with a terminating null on Windows too. Release kernel code was not affected: it writes only into 1024-character buffers. In debug builds, one warning in `SmTess.cpp` could overflow its 256-character buffer, but only for trim-curve UV values around 1e30 or larger, as from a corrupt file. - Reading a native Brep file (`read_brep_from_file`, `SmApiReadBrepFromFile`) now fails with `SM_ERR_INVALID_INPUT` when the data ends early (in an ASCII file, unless it ends inside a number) or a value cannot be read. - On Windows, the NURBS library's memory functions (`N_Malloc`, `N_Calloc`, `N_Realloc`, `N_MemSet`) took sizes as a 32-bit `long`, so a size over 2 GB was cut short and a curve or surface with that many control points or knots could be allocated too small and then written past its end. They now take `size_t`. Linux and macOS, where `long` is 64-bit, are unaffected. `SmTArray::SetSize` and `SmAllocator` (used by the kernel's hash maps) also refuse a size whose byte count would overflow, instead of allocating a wrapped-around size. - Reading a native Brep or part file (`read_brep_from_file`, `read_part_from_file`, `SmApiReadBrepFromFile`, `SmApiReadPartFromFile`) could crash on an attribute count or attribute index of 99999999 or more, or on a part file's Boolean tree node or Brep count of that size; it now fails with `SM_ERR_INVALID_INPUT`. - BrepArray import no longer crashes when a Brep's topology counts disagree with its array sizes or indices (for example, `face:loopCount` asking for more loops than the loop arrays hold, or a `faceuse:faceIndex` or `edge:vertexIndices` value past the Brep's faces or vertices), when a face has no loops, when counts are large enough to wrap when summed, or when a per-element array such as `edge:range` or `vertex:pointType` is shorter than its count. The import then fails with `SM_ERR_INVALID_INPUT`. ([GitHub #31](https://github.com/NVIDIA-Omniverse/usd-brep/issues/31)) - `trim_surface_with_3d_curves` (`SmApiTrimSurfaceWith3dCurves`) distorted a rational UV trim curve when it mirrored the curve across a seam of a closed surface: the control points were divided by their weights a second time. - `create_canonical_curve` (`SmApiCreateCanonicalCurve`) read past its inputs when given fewer knot multiplicities than knots, or fewer knots than the control points and degree need; it now fails with `SM_ERR_INVALID_INPUT`. - Deforming a B-spline trim curve to new end points while building or healing a face (`SmBrep::MakeFaceWithCurvesUVHeal`) read a freed knot array after inserting a knot, so it could insert a different knot and change the shape of the curve. - `SmBSplineCurve::ScaleKnotVector` now heals knots that the scaling brings within tolerance of each other, as the constructors do. Before, a later copy of the curve (including `Copy()`) merged them, so a curve scaled to a short interval changed on copy. Spans shorter than the tolerance are still merged, which can change the shape of the curve. ([GitHub #26](https://github.com/NVIDIA-Omniverse/usd-brep/issues/26)) - `SmSurface::SimpleCoincidenceChecker` could return a range endpoint whose curve parameter, surface UV and distance came from different samples. A stale distance or UV at an endpoint could make `SmBrep::ContainsCoincidentTopology` miss an edge lying on a face. ([GitHub #28](https://github.com/NVIDIA-Omniverse/usd-brep/issues/28)) - `create_box` (`SmApiCreateBox`) reported success when a face of the box could not be built, for example for a box of size 1e-6 or a small box far from the origin, and returned a Brep with missing faces. It now fails. - `turn_to_nurbs` (`SmApiTurnToNurbs`) leaked two surfaces for each offset surface it converted, for example on a Brep from `offset_brep`. ([GitHub #24](https://github.com/NVIDIA-Omniverse/usd-brep/issues/24)) - `SmTArray::FindElementInMaskedArray` tested `1 < ii` instead of bit `ii` of the mask, so it searched the wrong elements. - Mesh export (`tessellate_file`, `export_mesh`, `export_meshes`, `append_meshes`) wrote `points` and `extent` as `vector3f[]`. They are now `point3f[]` and `float3[]`, the types `UsdGeomMesh` declares, which USD validators check. ([GitHub #14](https://github.com/NVIDIA-Omniverse/usd-brep/issues/14)) - Intersecting a cone whose frame was built from a near-zero axis vector, for example in a Boolean with another cone or a cylinder, could crash converting parameters on the cone's missing base circle. - Booleans could keep a redundant intersection vertex lying on an intersection edge: when the first edge checked did not pass through the vertex, the remaining edges were skipped. - Booleans could return an invalid solid, with edges ending up to 0.01 away from their vertex, when an edge of one solid crossed a face of the other twice within 0.01 model units (with default tolerances), for example a union of three equal-radius cylinders meeting at one point. Both crossings were given the vertex of the first one. - `SmFace::GetPointsInFace` sampled a rectangularly trimmed face from UV (0, 0) instead of from the face's domain, and over only part of its width, so it could return points outside the face. The inner-shell tests that cast rays from these points (`SmShell::IsInnerShellOf`, used by `SmBrep::AssertValid`, and the inner-shell tests used when gluing edges, splitting a region or ordering its shells) could then classify a shell wrongly. - Surface intersection (booleans, `intersect_surfaces` (`SmApiIntersectSurfaces`)) built the wrong Dupin indicatrix for a saddle point whose two principal curvatures differ in size: the fourth hyperbola used one curvature for both axes. Intersection curves through such a tangent singular point could leave it in the wrong directions. - BrepArray import crashed, or imported the Brep without that edge's curve, when an edge or wire edge had an unknown `curveType`. It now fails with `SM_ERR_INVALID_INPUT`. An internal per-vertex table in the importer was sized from the edge count instead of the vertex count, so a Brep with more vertices than twice its edges could write past it. - Fillets (`fillet_edges`, `SmApiFilletEdges`) could build a blending rail that was not tangent to the rail it continues. When the rail had to be made as a cubic Hermite curve, it was built as a quadratic from three of its four control points, so it left its start in the wrong direction. - Fillet corners and vertex blends in `offset_brep` and `shell_brep` could fill a three-sided corner with a sphere even when its three boundary arcs had different centres, because the centre check compared each arc's centre with itself. Such corners now use the general corner fillet, or the offset fails. - `edge_length` and `Edge.length` (`SmApiEdgeComputeLength`) reported success with too short a length when the arc-length integration failed, for example with `desired_accuracy=0`: each curve span whose integration failed counted as zero length. They now return an error (Python: `RuntimeError`). - `SmSrfPtGapFunction`, `SmSrfCrvGapFunction` and `SmSrfSrfGapFunction` on a surface that is not a B-spline sampled its interior `v` values outside the surface domain when more than two `v` samples were set, so they reported gaps at the wrong points. No library operation uses them outside debug drawing, so this affects only C++ code that calls them directly. - BrepArray import read `loop:vertexIndex` as an index into the Brep's own vertices, but it is global to the BrepArray. A vertex loop in any Brep after the first read past an internal table, and an index past the BrepArray's vertices could crash. The index is now mapped to the Brep, and one outside it fails with `SM_ERR_INVALID_INPUT`. - Swapping the parameters of an offset surface that had been extended past its base surface (`SmOffsetSurface::SwapUV`, also reached through `SmFace::SwapUV`) left the offset distance unchanged, so the surface moved to the other side of its base surface. - Reading a native Brep file (`read_brep_from_file`, `SmApiReadBrepFromFile`) now checks the table counts and fails with `SM_ERR_INVALID_INPUT` when one is not valid. - Reading a part file (`read_part_from_file`, `SmBrepData::ReadPartFromFile`) now checks the counts of attribute values and the total number of attributes, and fails with `SM_ERR_INVALID_INPUT` when one is not valid. - Building a Brep from native file data (`read_brep_from_file`, `read_part_from_file`, `SmApiReadBrepFromFile`, `SmApiReadPartFromFile`, `SmBrep::MakeTopologyFromData`) now checks that the indices between its entities are in range, that edgeuse types and faceuse orientations are known, that each faceuse is used once and that loops hold only loop edgeuses, and fails with `SM_ERR_INVALID_INPUT` when they are not. Reading a part file also checks its attribute table indexes and missing entries, and no longer leaks the file data when it fails. - `read_brep_from_file` and `read_part_from_file` (`SmApiReadBrepFromFile`, `SmApiReadPartFromFile`) read the labels of an ASCII Brep file's version header and object types into fixed-size buffers without a length limit, so a long label could overrun the stack and crash; a version header that could not be read also crashed. Such a file now fails to read with `SM_ERR_INVALID_INPUT`. - On Windows, reading a binary native Brep file (`read_brep_from_file`, `read_part_from_file`, `SmApiReadBrepFromFile`, `SmApiReadPartFromFile`) accepted a topology value too big for a 32-bit `ULONG` and went on with the value unset. It now fails with `SM_ERR_INVALID_INPUT`. - Reading an older native Brep file, which the reader heals (`read_brep_from_file`, `SmApiReadBrepFromFile`), and `heal_brep` (`SmApiHealBrep`) could leave vertices within tolerance of each other, even exact duplicates, unmerged. Each merge replaced the healer's record of the surviving vertex, and the later pairs at that vertex were skipped unless the new record reused the old one's memory, so the result also depended on what the process had allocated before: a test file with 15 distinct vertex positions read as 17 to 21 vertices. It now reads as 15. - A failed Boolean left its contexts marked as inside a Boolean, so later operations on the same context ran in that mode (for example with delayed surface cache construction). This happened after any failing Boolean and after operations built on one, such as `sweep_along_planar_path` (`SmApiCreateSweepAlongPlanarPath`) when it fails. - Booleans of equal-radius cylinders whose axes cross could return an invalid solid, with a zero-area face and edges off their faces, or fail with `SM_ERR`, when the intersection ellipse only touched the end of a face, as in the union of two cylinders cut to meet on a mitre face. Rounding decided the result, so moving both solids could change it. This was a regression in 1.0.1 from the fix for crossing cylinders. ([GitHub #34](https://github.com/NVIDIA-Omniverse/usd-brep/issues/34)) - An AssertValid report kept a pointer to the message it was given instead of a copy. The report of a loop whose edges do not meet within tolerance ("Edgeuses out of tolerance") was given a message in a buffer that was gone once `AssertValid` returned, so `brep_geometry_validator`, `usd.validate_geometry_file` and `_smlib_dev.assert_valid_reports` printed garbage for it. `SmAssertReport` now keeps its own copy of the message, so that report prints its message with the gap and the tolerance, as does any other report built from a local buffer. - Booleans of equal-radius cylinders whose axes cross could leave out one of the cylinders, with no AssertValid report, return an invalid solid, or fail with `SM_ERR`, when a cylinder's seam passed within 0.01 model units (with default tolerances) of a point where the two cylinders touch. A branch that ends on another cylinder's axis touches it there too. An operand that is a solid of revolution, such as a primitive cylinder or cone, is now turned about its axis before the Boolean so its seams clear those points. Its shape does not change, but its seam edges move, so a result can have its faces split at different places. - `shell_brep` (`SmApiShellBrepFull`) and `offset_brep` (`SmApiOffsetBrepFull`) could report success for a solid whose result was not a solid, as for an inward shell of the union of two perpendicular cylinders. They now fail with `SM_ERR` (the offset only with `self_intersection` on, since it otherwise keeps overlapping faces). ([GitHub #36](https://github.com/NVIDIA-Omniverse/usd-brep/issues/36)) - Copying a curve on a surface (`SmCrvOnSurf`) that owned its UV curve but not its surface leaked the copy of the surface, for example one surface per edge when copying a Brep built by `SmBrep::MakeFaceWithCurvesFast`. The copy now owns its surface. - `brep_copy` (`SmApiBrepCopy`) returned an incomplete Brep as success when the copy stopped partway, for example on a Brep read from a file with a face or edge whose geometry type cannot be copied. It now fails with the copy's error status and returns no Brep. - Booleans of equal-radius cylinders no longer return an invalid solid (a piece of one cylinder left inside another) or fail with `SM_ERR` when several intersection curves meet within 0.01 model units (with default tolerances) of a point where two cylinders touch. This happened when three cylinders' axes were nearly coplanar, or when a seam of a cylinder already in an earlier union passed that point. - An intersection of three oblique cylinders of radius 0.42 no longer has a volume 0.6% too large. - Unions, intersections and differences now collect intersection points and curves no farther apart than the smaller of the previous distance and 0.2% of the largest side of the operands' bounding box, and at least 100 times the intersector's tolerance (5e-4 with default tolerances). With default tolerances this is under the previous 0.01 for solids under about 5 units across. `shell_brep`, `taper_extrude` and sweeps of Breps with wire edges run these Booleans at the Brep's tolerance, where that size is about 10 units. Merges inside fillets keep the previous distance. - `create_skin_primitive`, `create_skin_from_faces` and `create_skin_surface` (`SmApiCreateSkinPrimitive`, `SmApiCreateSkinFromFaces`, `SmApiCreateSkin`) now pass through profiles whose knots are close but not equal. They used to merge knots up to 0.001 apart, which moved the profiles by 1.4e-3 on 10-unit profiles, so two skins built from shared profiles had side faces that only nearly coincided. Only knots within 1e-8 are merged now, and the side faces can have more knots. ([GitHub #35](https://github.com/NVIDIA-Omniverse/usd-brep/issues/35)) - Curve/curve intersection (`intersect_curves`, `SmApiIntersectCurves`, and the Booleans, hidden-curve removal and silhouettes that use it) no longer misses one of two crossings close together where the curves run nearly parallel. An intersection of a torus of minor radius 0.01 with a cone whose base rim ran 0.0001 inside the torus failed with `SM_ERR`. ## [1.0.1] - 2026-10-21 ### Added - `SmApiUsdGeometryValidate.h`: run `SmBrep::AssertValid` on one BrepArray prim without changing the stage; `brep_geometry_validator` uses it. - `SmApiUsdHeal.h`: find, heal and write BrepArray prims on an open USD stage (`SmApiUsdFindBrepArraySites`, `SmApiUsdHealBrepArray`, `SmApiUsdWriteHealedBrepArray`). `usd.heal_file` is built on them. Healing is best effort: a failed heal step or an unfixed problem is not reported. ### Changed - `tessellate()` is faster; its output is unchanged. - `volume`, `mass_properties`, `face_area`, `Face.area` and `Face.centroid` (`SmApiBrepComputeVolume`, `SmApiBrepComputeMassProperties`, `SmApiFaceComputeArea`, `SmApiFaceComputeCentroid`) no longer clamp `relative_accuracy`, which was limited to [1e-8, 1e-1] for `volume` and [1e-4, 1e-1] for the others. A non-finite accuracy fails with `SM_ERR_INVALID_INPUT`. - `usd.heal_file` rejects BRep geometry composed from several prim specs in one layer, such as an internal reference that overrides the geometry it references. It used to keep the override over the healed geometry. - Linux aarch64 builds no longer fuse multiply-adds (`-ffp-contract=off`), which made their results differ from x86-64 and Windows: a boolean on marginal input could give a different result on aarch64, including a result with no solid material. ([GitHub #12](https://github.com/NVIDIA-Omniverse/usd-brep/issues/12)) - `create_cylinder` and `SMU_BrepConvert::CreateSmBrep_FromUsdCylinder` build their side face on an `SmCylinder` instead of a cone with semi-angle 0, so USD export writes `BrepSurfaceCylinderAPI`. The geometry is unchanged. ([GitHub #14](https://github.com/NVIDIA-Omniverse/usd-brep/issues/14)) - `brep_geometry_validator` no longer heals BReps on import, and its `--no-healer` option is removed. Healing could repair the defects being checked for, and the healer can crash on invalid BReps. ### Fixed #### Booleans - A union of a part with its mirrored copy returned the first operand, and their difference failed, because flat NURBS planes were not recognised as planar. Fillets on NURBS boxes are also more accurate. ([GitHub #1](https://github.com/NVIDIA-Omniverse/usd-brep/issues/1)) - Booleans that combined two overlapping intersection edges lost some edge definitions and later read the deleted edge. - Booleans of three or more equal-radius cylinders whose axes cross at one point, such as a tricylinder, failed with `SM_ERR` or returned a solid missing a whole arm. - Booleans wrote to freed memory while cleaning up. - A Boolean union whose edge overlap lay on two coincident face pairs could crash or give different results from run to run. - Booleans that glued coincident vertices freed curves still in use, which crashed fillet removal on an imported part. - A Boolean that deleted a face with a one-vertex loop crashed, for example an intersection removing a sphere cut that touches a flat face. - Booleans that glued coincident vertices kept a deleted vertex in an internal map; no test reaches this. - Booleans between a cone and an `SmCylinder`, such as two crossing cylinders from `linear_sweep`, used general NURBS intersection instead of the exact cone intersector and could lose a whole cylinder. - Booleans and merges could give an edge a tolerance far larger than its real gap. When dropping a curve onto a surface took a second attempt, the drop distance from the abandoned first attempt was reported with the curve the second attempt made, and the edge tolerance was raised to twice that. On a ring cut by a wrapped cutter this gave an edge a tolerance of 2.4 in a DIFFERENCE result, and with slightly different rounding, a merge tolerance of 16 that made the next DIFFERENCE return no solid. ([GitHub #12](https://github.com/NVIDIA-Omniverse/usd-brep/issues/12)) - Booleans could crash after closing a gap in an intersection loop deleted a vertex: the vertex stayed on the list cleaned up at the end of the Boolean. `shell_brep` crashed this way when the wall was as thick as a box with an open top face, for example a 20 x 30 x 5 box at distance -5. - Booleans could leave an edge whose 3D and UV curves ended away from its vertices, for example a thin curved panel cut by an elliptic cylinder across the panel boundary (4.7e-3 off). A split point is now accepted only when it lies within the tolerance of the edge curve. #### Sweeps and extrusions - `linear_sweep` (`SmApiCreateLinearSweep`) could return an open, zero-volume body, or hang, for a non-unit direction, a circle swept just off its axis or a negative distance. The direction is now normalised, a negative distance sweeps against it, and a zero direction fails with `SM_ERR_INVALID_INPUT`. ([GitHub #3](https://github.com/NVIDIA-Omniverse/usd-brep/issues/3)) - `draft_sweep` (`SmApiCreateDraftSweep`) crashed on a profile with a repeated edge. - `taper_extrude` (`SmApiCreateTaperExtrude`) crashed when an open chain of curves ended where a closed curve starts. - `linear_sweep_with_repetitions` (`SmApiCreateLinearSweepWithRepetitions`) failed with `SM_ERR` when `cap_ends=True` (the default) and `repetitions` was more than 1, and swept only the first profile face. - `create_skin_from_faces` (`SmApiCreateSkinFromFaces`) aborted the process with a stack overflow (`*** stack smashing detected ***`) when asked for a loft of degree 18 or more through 19 or more faces. It now raises `RuntimeError` (`SM_ERR_INVALID_INPUT`) for any degree outside 1 to 17, however many faces are given; degree 0 used to fail with `SM_ERR`. #### Fillets - `fillet_edges`, `fillet_edges_per_edge`, `variable_radius_fillet`, `fillet_preview` and `set_bevel_corners` given an edge of another Brep modified that Brep before failing. They now reject foreign, null or stale edges with `SM_ERR_INVALID_INPUT`. ([GitHub #2](https://github.com/NVIDIA-Omniverse/usd-brep/issues/2)) - `SmVertex::GetVertexuseOfFace` and `SmVertex::GetLoopOfFace` ignored their face argument and returned the Vertexuse or Loop of whichever face came first; the face test had been commented out with the composite-face code. As a result `SmBrep::DeleteFilletFace` failed for every fillet, including one filleted edge of a box. - `remove_fillet` (`SmApiRemoveFillet`) returned success when it removed nothing. It now returns an error (Python: `RuntimeError`) when any fillet face could not be removed; removed fillets stay removed. Fillets that meet at a rounded corner ([GitHub #6](https://github.com/NVIDIA-Omniverse/usd-brep/issues/6)) are removed with their corner faces, by extending the faces around them. - `remove_fillet` treated every rectangular face, including the planar faces of a plain box, as a fillet candidate. A fillet face must now meet its neighbours tangentially. - `circular_fillet` (`SmApiCircularFillet`) with a radius below about 2e-4 ran for minutes and used gigabytes of memory, for example with radius 0.0001 on a box of side 0.001. The 1e-5 padding on each patch's bounding box kept the small fillet surfaces' intersection caches from meeting their chord height tolerance, so they subdivided to the smallest allowed patch. ([GitHub #8](https://github.com/NVIDIA-Omniverse/usd-brep/issues/8)) - `circular_fillet`, `chamfer_fillet`, `fillet_edges`, `fillet_edges_per_edge`, `variable_radius_fillet` and `set_bevel_corners` (and their `SmApi` functions) now reject a radius below 8 times the BRep tolerance (8e-5 by default) with `SM_ERR_INVALID_INPUT`, leaving the BRep unchanged. Below that they could hang, crash, fail after modifying the BRep, or, for `set_bevel_corners` and `variable_radius_fillet`, return a non-manifold solid of zero volume. ([GitHub #8](https://github.com/NVIDIA-Omniverse/usd-brep/issues/8)) #### Offsets - `shell_brep` with extended offset read faces it had already deleted, for example when thickening a half-cylinder sheet inward past its radius. - `shell_brep` (`SmApiShellBrepFull`) crashed when an inward shell exactly closed the cavity, for example a 20 x 30 x 10 box with its top face open and distance -10. When the merge failed to insert an intersection edge after the new edge had taken the intersection curve, it deleted the curve anyway. It now returns an error and leaves the input Brep unchanged. ([GitHub #13](https://github.com/NVIDIA-Omniverse/usd-brep/issues/13)) - `shell_brep` with extended offset (the default) could give different results for the same input in different processes, or after other operations in the same process, because it offset the edges in an order set by memory addresses. It now uses an order set by the Brep. Some inputs still give a result that is not a solid, for example the source repository's `problemShell4.smb` test part shelled outward by 5.08 with face 2 open. ([GitHub #10](https://github.com/NVIDIA-Omniverse/usd-brep/issues/10), [#21](https://github.com/NVIDIA-Omniverse/usd-brep/issues/21)) - `shell_brep` left a gap where an open face met a fillet tangentially, such as the open top of a box with filleted top edges, giving the wrong volume or an error. The wall is now closed there. ([GitHub #10](https://github.com/NVIDIA-Omniverse/usd-brep/issues/10), [#21](https://github.com/NVIDIA-Omniverse/usd-brep/issues/21)) #### Healing and topology - `heal_brep` (`SmApiHealBrep`) missed missing seams on some torus faces, and inserting the first seam split an uncut torus in two. A seam that is a curve on the surface (`SmCrvOnSurf`) now keeps the face whole; one given as an independent 3D circle or B-spline can still split it. - The `SmCurveClassification` discontinuity intersectors filed some boundary solutions under the wrong side, and put the W planes at V parameters. - `SmBrep::DeleteFace` on the last face of a shell with a wire attached through a vertex-only loop left an invalid empty shell. The wire is now kept. - `SmProjectedCurve::MakeOrthoNormal` failed for every non-zero axis, and for a rotation did not make the aux vector perpendicular to the axis. - `heal_brep` now splits a boundary edge where it crosses a surface pole without a vertex. A crossing near the edge's endpoint can still be skipped. - `SmVertexuse::ComputeUVSector` counted a face and loop that are both reversed as one reversal, not two, because `?:` binds less tightly than `+`. - Healing missed some coincident vertex pairs and left them unmerged. - The healer's edge-length histogram (`SM_HISTOGRAM_EDGELEN_INDEX`) converted a negative number to `ULONG` for edges shorter than 1, which is undefined behaviour; on aarch64 all those edges landed in one bucket. - Healing read freed memory once its vertex search grew past its initial capacity. - `heal_brep` could leave a cylindrical face with a pocket with two outer loops, and could merge a hollow solid's cavity into the solid. Spheres and tori bounded only by vertex loops are now repaired in place. A face with edge loops and a missing seam can still be skipped by seam insertion. - `heal_brep` on a Brep with two regions could leave the wrong one as the exterior and still report success, for example on inward-facing STEP box shells. - `SmBrep::RefreshGaps` and `SmBrep::RefreshTols` could report success when a gap refresh failed: `RefreshGaps` returned only the status of the last edgeuse and the last vertexuse it refreshed, and `RefreshTols` ignored it. Both now return `SM_ERR` if any refresh fails. No library operation calls them, so this affects only C++ code that calls them directly. #### Geometry - The `SmBSplineSurface` component constructor lost V knots when a surface had more V knots than U knots. - `SmBSplineCurve::ReverseParameterization` and `SmBSplineSurface::Reverse` gave a different curve or surface when the knot vector was not clamped at both ends. Clamped knot vectors are unaffected. - `SmBSplineSurface::TrimWithDomain` never checked that snapping the upper V trim boundary to a knot left the surface at least as large as before. - `SmBSplineCurve::RemoveOneKnot` failed and discarded a valid result on parameter ranges over about 1e5, so `SmBSplineCurve::CreateExtendedCurve` with `SM_CT_CINFINITY` returned `SM_ERR`. - `sm_TotalCoincidenceChecker`, used by cone and cylinder intersection, never found two equal lines running in opposite directions coincident. - Reading a B-spline surface or curve of degree 18 or more from a native SMLib file now fails with `SM_ERR_INVALID_INPUT`. The read used to succeed, and evaluating the surface, or a surface extruded or swept from the curve, then aborted the process with a stack overflow (`*** stack smashing detected ***`). Degrees below 1 are rejected too; a negative degree used to crash the reader. - `SmCone::IsNurbSurfaceCone` reported a NURBS surface as a cone when it failed to make one of its iso-parametric curves. - Reading a B-spline surface or curve from a native SMLib file now fails with `SM_ERR_INVALID_INPUT` when a control point count is negative, below degree + 1 or too large to allocate, when the rational flag is neither 0 nor 1, or when the file ends, or holds text that is not a number, inside the B-spline data. Negative and huge counts used to crash or hang the reader or throw `std::bad_alloc`; a count below degree + 1 read, and every evaluation of the result failed; and the reader carried on past the end of a truncated file, which hung on ASCII files and crashed on binary ones. A failed read also leaked its NURB and the new curve or surface: 37 MB per read for a 1101 x 1101 surface with a bad rational flag. #### Measurement - `mass_properties`, `volume` and `Face.centroid` (`SmApiBrepComputeMassProperties`, `SmApiBrepComputeVolume`, `SmApiFaceComputeCentroid`) controlled only the area's integration error, so volume, centroid and inertia could miss the requested accuracy by far more: at the default 1e-3, a thin half shell's volume was 4.5e-2 off. They now control every property's error, and take longer. `mass_properties` about an `origin` far from the solid is also accurate now. ([GitHub #19](https://github.com/NVIDIA-Omniverse/usd-brep/issues/19)) - Face area, volume and mass properties could miss the requested accuracy on faces trimmed by curves with interior knots, such as circles: a half-disk's area was 20% off at `relative_accuracy=1e-1`. Each trim-curve knot span is now integrated separately. ([GitHub #11](https://github.com/NVIDIA-Omniverse/usd-brep/issues/11)) - `brep_relationship` (`SmApiBrepRelationship`) and `brep_distance` gave wrong results for cylinders and cones. `create_cone` returned its Brep in edit mode, in which distances were measured to a cap's whole plane, so cones 0.025 apart were reported touching at distance 0. Overlaps were also missed when no vertex or face sample lay inside the other body, and a shared boundary could count as an overlap. Edge points are now sampled too, and boundary points count as neither inside nor outside. An overlap that contains no sampled point is still reported as touching, for example a radius-1 sphere sunk 0.2 into some side faces of a box. ([GitHub #16](https://github.com/NVIDIA-Omniverse/usd-brep/issues/16)) #### Tessellation - In the 1.0.0 wheel, `tessellate()` failures raised `ModuleNotFoundError` instead of `TessellationError`. #### USD import and validation - The BrepArray validator (`brep_validator`, rule BA.515) rejected cone semi-angles of 0 or below, although the schema allows (-pi/2, pi/2). Every exported `create_cylinder` (a cone with semi-angle 0) and every cone narrowing along its axis failed validation. It now accepts that range and rejects NaN. ([GitHub #14](https://github.com/NVIDIA-Omniverse/usd-brep/issues/14)) - Importing a USD BrepArray now fails with an error naming the array when a NURBS edge, wire edge or face surface needs more control vertices or knots than its packed array holds from its start index, or has fewer control vertices than its order. The import used to read past the end of the array: a short control vertex array imported values from beyond it (a box's volume came out 18 instead of 24), and a vertex count of 4,000,000,000, or 65536 x 65536 surface control vertices (a product that wrapped to 0), crashed it. UV trim curves already had this check. - Importing a USD BrepArray with a NURBS surface or curve of order 19 or more now fails with an error naming the order. The import used to succeed, and evaluating the surface, or a surface extruded or swept from the curve, then aborted the process with a stack overflow (`*** stack smashing detected ***`); `brep_geometry_validator` aborted the same way. Orders 0 and 1 are rejected too, and a very large order no longer reads past the end of the knot arrays. A UV trim curve of an unsupported order is discarded and rebuilt from its 3D edge. A malformed UV trim record, such as order 0 with control vertices, no longer shifts the trims after it; they used to be read from the wrong place, which could give the imported solid the wrong shape. - `SmBrep::AssertValid` at `SM_LEVEL_2` leaked memory on every call for a brep with faces on periodic surfaces: about 3.5 KB for a cylinder and 12.5 KB for a torus. `SmFace::HasSeamProblem` copied each seam curve into its output instead of handing it over, and abandoned the original. ([GitHub #9](https://github.com/NVIDIA-Omniverse/usd-brep/issues/9)) #### USD export - USD export wrote analytic faces whose UV parameterisation had been swapped, such as a hole wall after a fillet, with loops that did not match their USD surface, giving an invalid BrepArray. A swapped face that shares its surface with another face is still exported the old way, with a warning. ([GitHub #4](https://github.com/NVIDIA-Omniverse/usd-brep/issues/4)) #### OCCT `.brep` conversion - `occt_to_usd`: a planar face's `face:range` now contains the full extent of its B-spline edges. It was taken from 24 samples per edge and could miss an edge's furthest point, which made the face's area wrong after import. ([GitHub #11](https://github.com/NVIDIA-Omniverse/usd-brep/issues/11)) - `occt_to_usd` wrote a face on a periodic B-spline surface or curve partly outside the surface's domain when the face's trims crossed OCCT's seam. SMLib then read the face with its edges a quarter turn or more out of place, and volume and mass properties were wrong. Each periodic direction is now unrolled over the period the face or edge uses. #### Build - Windows builds failed when the checkout path contained a parenthesis. Without administrator rights or Developer Mode, they also failed with Visual Studio in its default `C:\Program Files (x86)`. ## [1.0.0] - 2026-10-08 ### Added - Initial public release of USD BRep: NURBS boundary-representation (BRep) solid modeling libraries, with C++ and Python APIs and OpenUSD import and export.