What's the simplest way of detecting if a (regular) volume primitive stored in 16-bit representation in memory? (I just need for manual instpection, “Extended Info”-kind of thing, although any script command would also do. )
I believe the question was about regular volume primitive, not VDB but maybe regular volumes don't store/change the precision, it may be just used in Volume Compress to round off the values so they are naturally compressed to smaller files
I think with VDB they are never stored in memory as 16-bit, it is only when they are written to disk and save half precision is enabled.
With regular volumes I'm fairly certain you can work with them in Houdini and in memory as 16-bit. There is an option to create 16-bit volumes in dops however it will slow your sim down.
As far as viewing the precision of a standard Houdini dense volume, I'm not sure how. ops:
Don't know if there is any smartet/simplier way, but you can create floating point attribute (32/64bit) and then sample that volume for non zero values and write them to that attribute.
If volume is in 16bit float then sampled values will have precision up to 5 decimal places. Otherwise it could have more than that (I think 9 decimal places is common standard volumes with 32bit floating point precision).
My question was about regular (non-VDB) volumes, VDBs are (afaik) always stored as floats in memory.
Thanks for the workaround suggestions. The workaround I usually go for (with mixed success, I might add) is to toggle the 16bit switch on a Volume Compress SOP and see how the memory consumption changes. Bit awkward, though.