dpap Posted April 8, 2015 Share Posted April 8, 2015 (edited) How can I drive the voxel size of the VDB from Polygons node from the color of my fragments? Why can't I use the local variable $VSIZE that I created upstream from my color values? My goal is to have more detail to the bright red pieces than the dark ones. Thanks. voxel size based on color.hip Edited April 8, 2015 by dpap Quote Link to comment Share on other sites More sharing options...
xray Posted April 8, 2015 Share Posted April 8, 2015 (edited) The VDBfromPolygon SOP does not use per-point attributes or variables. You need another way to get the value from the point or prim. in the voxelsize parameter of the vdbfrompolygons1 SOP, put this expression: point("../each1",0,'vsize',0) That will get the vsize atttribute of point #0 of each incoming piece. You also want to make you vsize smaller. Your volumes are too course. Edited April 8, 2015 by xray 1 Quote Link to comment Share on other sites More sharing options...
edward Posted April 8, 2015 Share Posted April 8, 2015 VDB volumes (or native volumes for that matter) can only have 1 voxel size per primitive. 1 Quote Link to comment Share on other sites More sharing options...
Guest tar Posted April 8, 2015 Share Posted April 8, 2015 Also more info on the VDB site: http://www.openvdb.org/documentation/doxygen/faq.html#sAdaptiveGrid ' Is OpenVDB an adaptive grid? Let's first stress that the term "adaptive grid" is somewhat ambiguous. Some use it to mean a grid that can store data sampled at adaptive voxel sizes typically derived from a so-called "refinement oracle", whereas others mean multiple grids with different fixed voxel sizes all sampling the same data. An example of the former is an octree and of the latter is a mipmap. Since OpenVDB stores both data values and child nodes at each level of the tree, it is adaptive only in the first sense, not the second. The level of adaptivity or refinement between the tree levels is defined by the branching factors of the nodes, which are fixed at compile time.' Quote Link to comment Share on other sites More sharing options...
dpap Posted April 8, 2015 Author Share Posted April 8, 2015 Thank you all for your input! Maybe I didn't explain my self very well. I meant different voxel size for each fragment assuming that each fragment has only one color value. Anyway, xray's expression did the trick so everything is good now! Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.