Hello All,
I am using VDBs to combine geometry and I am interested in a way of maintaining specific attributes from the two input geometries. Currently I have two poly objects which are being converted to VDBs and then combined using VDB combine and then converted back to polys using VDB convert. What I want is to be able to identify which polygons on the resulting combined/converted object comes from which input object.
I attempted using the ‘Surface Attributes’ parameter on the VDBfromPolygons which I used to convert the input geometry, however I could not get it to work correctly or it just isn't meant for that use.
I had an idea of using a ray SOP to ray an attribute from the original input geometries back to the final combined geometry however I have not tested this yet but it doesn't seem ideal. I am new to VDBs so I was hoping someone might have some alternative methods or could point me in the right direction.
If I am being unclear I can post an example file.
Thank you all in advance!
Cheers,
-Mat
VDB - maintaining attributes?
7853 3 2-
- Mat Suarez
- Member
- 16 posts
- Joined: Dec. 2014
- Offline
-
- Mat Suarez
- Member
- 16 posts
- Joined: Dec. 2014
- Offline
-
- Doudini
- Member
- 333 posts
- Joined: Oct. 2012
- Offline
-
- Mat Suarez
- Member
- 16 posts
- Joined: Dec. 2014
- Offline
Follow up:
I have had some success with using the second input of the convertVDB node to transfer attributes. Using this method however, I am only able to maintain some of the objects attributes, not all. I've attached some images and a file to demonstrate my current issue.
In the attached file I have three objects; Base, Add Sphere and Sub Sphere. All objects contain UVs and an ID attribute (tmp1), they are all converted to VDBs then combined using VDBcombine nodes. Finally the resulting VDB is converted to polys using convertVDB. When both original sphere are input into the second input, the UVs and ID attributes are transferred correctly for the spheres however the Base object is not. When all three objects are input into the second input of the convertVDB, only the Base and one sphere's attributes are transferred correctly. I have tried several different combinations and methods of making this work to no avail, but it feels like I'm so close if I can get all three objects to transfer the attributes correctly, just not all at the same time. It is possible to use two convertVDB nodes, one with the two spheres in the second input and the second with all three objects in the second input, then deleting the problem polys from either (using the ID attribute) and then merging the two together, but this is not very ideal.
In the image on the left you can see the results of the convertVDB using only the two spheres as the second input, the middle image is when using all three objects (base, add_sphere and sub_sphere), and the right is an image of all three input objects showing their UVs.
I have had some success with using the second input of the convertVDB node to transfer attributes. Using this method however, I am only able to maintain some of the objects attributes, not all. I've attached some images and a file to demonstrate my current issue.
In the attached file I have three objects; Base, Add Sphere and Sub Sphere. All objects contain UVs and an ID attribute (tmp1), they are all converted to VDBs then combined using VDBcombine nodes. Finally the resulting VDB is converted to polys using convertVDB. When both original sphere are input into the second input, the UVs and ID attributes are transferred correctly for the spheres however the Base object is not. When all three objects are input into the second input of the convertVDB, only the Base and one sphere's attributes are transferred correctly. I have tried several different combinations and methods of making this work to no avail, but it feels like I'm so close if I can get all three objects to transfer the attributes correctly, just not all at the same time. It is possible to use two convertVDB nodes, one with the two spheres in the second input and the second with all three objects in the second input, then deleting the problem polys from either (using the ID attribute) and then merging the two together, but this is not very ideal.
In the image on the left you can see the results of the convertVDB using only the two spheres as the second input, the middle image is when using all three objects (base, add_sphere and sub_sphere), and the right is an image of all three input objects showing their UVs.
-
- Quick Links

