Skip to content

Conversation

matthewdcong
Copy link
Contributor

This PR adds the latest round of improvements to NanoVDB from the fVDB team, including:

  • Improvements and bugfixes to PNanoVDB
  • Add Mat classes and other math types to NanoVDB
  • Add support for morphology operators in NanoVDB
  • Improvements to mGPU grid building and introduction of a separate test executable for mGPU tests
  • Several fixes for compiler warnings

Copy link
Contributor

@kmuseth kmuseth left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's remove PNanaoVDB2.h and util/Camera.h for now (since they're still under development and not used outside of NVIDIA)

I couldn't find unit-tests for several of the new tools: dilation, morphology, merge etc (or did I just miss them)

Copy link

linux-foundation-easycla bot commented Sep 6, 2025

CLA Signed

The committers listed above are authorized under a signed CLA.

@matthewdcong
Copy link
Contributor Author

Let's remove PNanaoVDB2.h and util/Camera.h for now (since they're still under development and not used outside of NVIDIA)

I couldn't find unit-tests for several of the new tools: dilation, morphology, merge etc (or did I just miss them)

Removed PNanoVDB2.h, util/Camera.h, and util/Convert.h.

You're right, there are examples but not unittests. Let me follow up with Efty.

@Idclip
Copy link
Contributor

Idclip commented Sep 6, 2025

Please allow for #2077 to be merged first

matthewdcong and others added 14 commits September 10, 2025 16:09
* Fix prefix sum buffer overruns

* Add test

* Revise comment

Signed-off-by: Matthew Cong <mcong@nvidia.com>
Signed-off-by: Matthew Cong <mcong@nvidia.com>
Signed-off-by: Matthew Cong <mcong@nvidia.com>
Signed-off-by: Matthew Cong <mcong@nvidia.com>
Signed-off-by: Matthew Cong <mcong@nvidia.com>
Signed-off-by: Matthew Cong <mcong@nvidia.com>
Signed-off-by: Matthew Cong <mcong@nvidia.com>
Signed-off-by: Jonathan Swartz <jonathan@jswartz.info>
Refactor the distributed radix sort code into a separate function so that it is more modular, testable, reusable. Furthermore, it fixes a small rounding error edge case in the merge code.

Signed-off-by: Matthew Cong <mcong@nvidia.com>
---------

Signed-off-by: Jonathan Swartz <jonathan@jswartz.info>
Signed-off-by: Matthew Cong <mcong@nvidia.com>
Signed-off-by: Matthew Cong <mcong@nvidia.com>
The CALL_CUBS macro has a slightly different definition in the two similar code files that use it, namely PointsToGrid.cuh and TopologyBuilder.cuh. This fix restricts the scope of each macro definition to just the code file where it is used.

Signed-off-by: Matthew Cong <mcong@nvidia.com>
This PR fixes a few discrepancies between grid construction via (a) PointsToGrid, and (b) OpenToNanoVDB. The discrepancies are not typically inhibiting functionality of either construction, but result in grids that are not bit-identical, when they would otherwise be expected to be. The changes are:

Removal of the PointsToGridData::flags member. The actual functionality of this flag was to allow control of solely the leaf-level flags (interior node, and GridData flags were already set independently), and in that aspect it was even incorrectly setting the IsBreadthFirst bit (which only makes sense for GridData::mFlags, not the leaf node flags). The method includeBBox was having no effect as it was, it was never called in any of the unittests, and its effect was overwritten later in the code.

PointsToGrid has been corrected to flag HasBBox as active in every node (not just the leaf nodes, as was happening prior; the flags were previously being set to zero).

The world space bounding box in OpenToNanoVDB was incrementing the upper bound of the index-space bounding box, prior to applying the transform ( hence, a grid with a single voxel [0,0,0] would have a WS bounding box of [0,0,0]->[1,1,1]). PointsToGrid was not applying this increment, resulting in a smaller WS bounding box.

Signed-off-by: Matthew Cong <mcong@nvidia.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants