Skip to content

feat(vdb_print): add VDB Point support (Issue #617)#2203

Open
aveljkovic wants to merge 1 commit into
AcademySoftwareFoundation:masterfrom
aveljkovic:fix-docs
Open

feat(vdb_print): add VDB Point support (Issue #617)#2203
aveljkovic wants to merge 1 commit into
AcademySoftwareFoundation:masterfrom
aveljkovic:fix-docs

Conversation

@aveljkovic
Copy link
Copy Markdown

Description

Addresses issue #617 by adding VDB Point grid support to the vdb_print command-line utility.

Changes Implemented

  • Wrapped point-grid reporting logic inside #if OPENVDB_ABI_VERSION_NUMBER >= 6 as requested in the issue.
  • Implemented printPointDataDetails in openvdb_cmd/vdb_print/main.cc to match verbose tree outputs (using section headers, two-space indentations, and util::formattedInt for counts).
  • Displays total, active, and inactive point counts.
  • Extracts and outputs comprehensive attribute metadata (name, index, type, uniform status, decoded flags, and compression/codec details).
  • Groups details extracted and sorted across leaves with total point count tracking.
  • Identifies whether descriptors are globally shared or lists individual descriptor variations.

Notes for Maintainers

Please note: I do not currently have the full C++ build dependencies (such as Boost) configured locally on my environment. I am submitting this as a Draft PR so that the repository's automated CI/CD build pipelines can run the build verification and automated tests. Please let me know if any formatting or formatting alignments need to be adjusted!

@linux-foundation-easycla
Copy link
Copy Markdown

linux-foundation-easycla Bot commented May 15, 2026

CLA Signed
The committers listed above are authorized under a signed CLA.

  • ✅ login: aveljkovic / name: Aleksandar Veljkovic (e3939cc)

@aveljkovic aveljkovic marked this pull request as ready for review May 15, 2026 16:52
@danrbailey
Copy link
Copy Markdown
Contributor

Thank you for signing the CLA.

We no longer support ABI<=6, so all the conditional branching related to that is not required any more.

There is a fair amount more complexity here than I think is truly necessary. Let's only output detailed attribute and group information for shared descriptors. Let's remove out-of-core output as this is due to be removed soon anyway. Let's remove hex flag output - this output is intended to be human-readable. Let's not include both compression summary and full types and they are the same information.

Can you provide an examples of what the tool output looks like? Preferably using a VDB Points grid with more than one attribute and a group. I think it should be fairly evident how to make the output more readable.

Finally, the CMake build directories shouldn't be included as part of your PR.

…on#617)

Signed-off-by: Aleksandar Veljkovic <veljkovic.tech@gmail.com>
@aveljkovic
Copy link
Copy Markdown
Author

@danrbailey Thanks for the review and the guidance! I completely agree that the output needed to be simplified.

I have pushed an update that addresses all of your points:

  1. Removed all ABI<=6 conditional branching.
  2. Restricted detailed attribute/group output exclusively to globally shared descriptors.
  3. Removed all out-of-core reporting.
  4. Removed the hex flag output in favor of human-readable comma-separated lists.
  5. Consolidated the type and codec info.
  6. Removed the accidental CMake build directories from the PR.

Here is a mock example of what the new output looks like for a Point grid with a shared descriptor, multiple attributes, and a group:

Point data:
Total points: 48,192
Active points: 45,000
Inactive points: 3,192
Descriptor shared by all leaves: yes
Attributes:
Cd: index=1, type vec3s (null), uniform=no, flags none
P: index=0, type vec3f (null), uniform=no, flags constantstride
id: index=2, type int32 (null), uniform=yes, flags none
Groups:
particles: 12,340

And if the descriptor is not shared:

Point data:
Total points: 10,000
Active points: 9,500
Inactive points: 500
Descriptor shared by all leaves: no

Let me know if this formatting aligns better with the project's vision!

@danrbailey
Copy link
Copy Markdown
Contributor

@danrbailey Thanks for the review and the guidance! I completely agree that the output needed to be simplified.

I have pushed an update that addresses all of your points:

  1. Removed all ABI<=6 conditional branching.
  2. Restricted detailed attribute/group output exclusively to globally shared descriptors.
  3. Removed all out-of-core reporting.
  4. Removed the hex flag output in favor of human-readable comma-separated lists.
  5. Consolidated the type and codec info.
  6. Removed the accidental CMake build directories from the PR.

Here is a mock example of what the new output looks like for a Point grid with a shared descriptor, multiple attributes, and a group:

Point data: Total points: 48,192 Active points: 45,000 Inactive points: 3,192 Descriptor shared by all leaves: yes Attributes: Cd: index=1, type vec3s (null), uniform=no, flags none P: index=0, type vec3f (null), uniform=no, flags constantstride id: index=2, type int32 (null), uniform=yes, flags none Groups: particles: 12,340

And if the descriptor is not shared:

Point data: Total points: 10,000 Active points: 9,500 Inactive points: 500 Descriptor shared by all leaves: no

Let me know if this formatting aligns better with the project's vision!

I don't mind that this was implemented using AI coding, but we do need to see the actual output for real world data that gives us full confidence that this actually works, not mock output that the AI is generating. These good first issues are intended to help users get up to speed with the entire process of building the library, signing the CLA as well as doing authentic runtime testing and using human judgement that the quality of the code and results align with the goals outlined in the issue and the coding standards and conventions of the project. Otherwise, my time would be better spent using Claude to implement this myself than going back-and-forth reviewing your PR.

@aveljkovic
Copy link
Copy Markdown
Author

@danrbailey I have successfully resolved the environment configuration hurdles on my end, built the modified executable locally against MSVC, and verified the output against the official Academy Software Foundation real-world boat_points.vdb simulation asset.

As requested, the log formatting now cleanly handles the PointDataGrid information, extracting point counts, attribute indices/types/codecs/flags, and group assignments natively while adhering strictly to standard formatting guidelines (omitting hex structures, out-of-core calculations, and ABI layout blocks).

Here is the true runtime execution output from the compiled binary tracking over 20 million points:

Point data:
  Total points:                    20,278,460
  Active points:                   20,278,460
  Inactive points:                 0
  Descriptor shared by all leaves: yes
  Attributes:
    P: index=0, type vec3s (fxpt16), uniform=no, flags constantstride
    Cd: index=1, type vec3s (ufxpt8), uniform=no, flags constantstride
    v: index=2, type vec3s (null), uniform=no, flags constantstride
  Groups:
    (none)

The updated logic has been pushed cleanly to the PR branch. I really appreciate your patience and strict guidance throughout this refinement workflow!

@aveljkovic
Copy link
Copy Markdown
Author

Any news on this? @danrbailey

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.

2 participants