OpenVDB support
Re: OpenVDB support
We are going in Very professional area ! be sure that we will abuse of the engine if you continue like that don't complaint anymore after
Re: OpenVDB support
Oh, yes...
impatiently waiting as was just playing with multiscattered banded Blender Marble inside the Cube (Heterogeneous Volume) on Tiled PT - Works really well. Next, clouds in a Box
Thank you, thank you very much...
Do you think that one day will be able to render iridescence in volumes?
impatiently waiting as was just playing with multiscattered banded Blender Marble inside the Cube (Heterogeneous Volume) on Tiled PT - Works really well. Next, clouds in a Box
Thank you, thank you very much...
Do you think that one day will be able to render iridescence in volumes?
Re: OpenVDB support
It is but there are so many aspects to work on that sometime it is just hard to keep track of all of them and prioritize what to work on next.
Re: OpenVDB support
I updated the linux procedure to compile with OpenVDB support and it should now work out of the box, just switch to the "openvdb" branch in LuxCore, LinuxCompile and LinuxCompileDeps repositories.
@B.Y.O.B., I tried the .vdb, exported from Blender, you posted some time ago and they seems to work but we need to do some test about the volume transformation. I'm currently ignoring the transformation stored inside .vdb file and remapping the volume in [0, 1] coordinates. This should be what you expect (i.e. it works like densitygrid texture .data field) but we need to try.
This is the new syntax:
where ".data" field can be replaced by ".openvdb.file" and ".openvdb.grid" properties. The ".openvdb.grid" is the name of the grid (i.e. data channel) to read from the file. If you need to check what names are used in a .vdb, just check the log:
@B.Y.O.B., I tried the .vdb, exported from Blender, you posted some time ago and they seems to work but we need to do some test about the volume transformation. I'm currently ignoring the transformation stored inside .vdb file and remapping the volume in [0, 1] coordinates. This should be what you expect (i.e. it works like densitygrid texture .data field) but we need to try.
This is the new syntax:
Code: Select all
scene.textures.tex.type = densitygrid
scene.textures.tex.nx = 256
scene.textures.tex.ny = 256
scene.textures.tex.nz = 256
scene.textures.tex.wrap = black
scene.textures.tex.openvdb.file = scenes/media/blender-blosc.vdb
scene.textures.tex.openvdb.grid = density
scene.textures.tex.mapping.type = globalmapping3d
scene.textures.tex.mapping.transformation = 1. 0 0 0 0 0 -1. 0 0 .8 0 0 0.5 0.5 0.5 1
Code: Select all
[SDL][0.005] Texture definition: tex
[SDL][0.005] OpenVDB file: scenes/media/blender-blosc.vdb
[SDL][0.012] OpenVDB grid names:
[SDL][0.012] [density]
[SDL][0.012] [obstacles]
[SDL][0.012] [shadow]
[SDL][0.012] [velocity]
[SDL][0.025] OpenVDB grid bbox: [(26, 13, 27), (184, 119, 171)]
[SDL][0.025] OpenVDB grid size: (158, 106, 144)
[SDL][0.910] Define ImageMap: LUXCORE_DENSITYGRID_tex
Re: OpenVDB support
I have now both the Linux and Windows versions working with OpenVDB ... the porting to Windows was the usual horrible pain but it is done. Tomorrow, I will merge all the openvdb branches with the main so it will be in the next beta release.
Re: OpenVDB support
Why there is so much difficulties in working with Microsoft software (a company with trillion dollars) ?
Thanks You for This advance !
Re: OpenVDB support
Not to defend MS but, this time, we had to use OpenVDB v3.1 (when the latest version is v5.0 !) because is the version used by Blender and the latest to not require C++11 support (MS fault is here).
Re: OpenVDB support
I have started to work on support in BlendLuxCore however apparently it is non-trivial to find out the path of the cache files...
I can't find the relevant Python attribute in Blender or in the documentation. Have to look further.
Of course the current code already works with OpenVDB (the grid attributes in Blender hide the underlying caching mechanism), but it kinda defeats the point of having OpenVDB support in LuxCore.
By the way can we accelerate the export of the normal point cache with C++?
Have to investigate. I think we would need a C++ function "DefineDensityGridData()" (like DefineMesh etc.) because the main bottleneck seems to be that we currently pass a HUGE array to a property.
I can't find the relevant Python attribute in Blender or in the documentation. Have to look further.
Of course the current code already works with OpenVDB (the grid attributes in Blender hide the underlying caching mechanism), but it kinda defeats the point of having OpenVDB support in LuxCore.
By the way can we accelerate the export of the normal point cache with C++?
Have to investigate. I think we would need a C++ function "DefineDensityGridData()" (like DefineMesh etc.) because the main bottleneck seems to be that we currently pass a HUGE array to a property.