-
Notifications
You must be signed in to change notification settings - Fork 626
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to create PointPartitioner from data that is read in ? #109
Comments
Hi @nyue, I'm currently working on getting the code samples and documentation ready for submission into OpenVDB, so that should help explain this better. In short, the PointPartitioner is only for use with a PointIndexGrid where the attribute data is stored in a linear external array. Here's a super-simple example for iterating over position data in a PointDataGrid:
Hope that helps. Dan |
Thank you. In your code
How do you know there will be an attribute call "P" ? How does one programmatically find all the other attribute names ? Cheers |
"P" is a mandatory attribute. For simple inspection, you can use some of the convenience methods on the PointDataLeaf:
Otherwise, you'll need to go through the Descriptor:
Although the API doesn't enforce this, by convention we assume that the Descriptor is the same across all LeafNodes. |
Hi,
After reading in an OpenVDB 4 file with point data, how does one create a partitioner ?
I am looking to the partitioner to provide indices to actual points (per bucket?) and query additional information like position, velocity and other attributes.
So far, I don't know what method in PointDataGrid returns object that can be use for the construction of the Partitioner, here is my current attempt, ::create() fails to compile as I am not providing what it needs
I see the example creating a struct call PointList within an anonymous namespace
`
openvdb::io::File fileIn(vdb_file);
fileIn.open();
`
Cheers
The text was updated successfully, but these errors were encountered: