Page 1 of 1
Animated OpenVDB Volumes
Posted: Sat Aug 28, 2021 1:10 pm
by Continuum
I am experimenting with volumes in Luxcore, in Blender, and I have run into an odd problem. Cycles & Renderman seem to handle this automatically. Since OpenVDB is a sparse format the grid size changes for each frame. Since Luxcore treats the grid as a texture, the simulation transforms on every frame. There is a video below highlighting the problems. How do I fix this?
https://www.youtube.com/watch?v=H3WQ_l1gISc
This file also doesn't seem to show, I exported it from Houdini. It works in Cycles & Renderman.
https://www.deepfxworld.com/public_down ... penvdb.zip
Re: Animated OpenVDB Volumes
Posted: Mon Aug 30, 2021 10:20 am
by Dade
I'm looking in a Disney material related problem and I will check this as soon as I have finished there
.
Re: Animated OpenVDB Volumes
Posted: Mon Aug 30, 2021 9:57 pm
by Continuum
Okay, thanks. I currently use v2.4 for continuity reasons, since the feature set ticks all my use cases. If this problem has been fixed for the latest release then I may upgrade to a newer release in the future.
Re: Animated OpenVDB Volumes
Posted: Tue Sep 07, 2021 10:57 am
by Dade
I need a complete scene (.cfg, .scn, etc.), the VDB file alone doesn't tell me very much.
Anyway, the source of your problem is in how the VDB file is read and scaled for the densitygrid.
The OpenVDB file is scaled to match the densitygrid size:
https://github.com/LuxCoreRender/LuxCor ... d.cpp#L114
and traslate to match the position, here:
https://github.com/LuxCoreRender/LuxCor ... d.cpp#L153
This means the position and size information stored in the OpenVDB file are not used, the densitygrid will instead use its own position/scale information. In your case, you would like the opposite: to position/scale the densitygrid according the the VDB file.
It is is something it should be possible to add with a specific flag/option, I will check.
Re: Animated OpenVDB Volumes
Posted: Fri Sep 10, 2021 4:42 pm
by Continuum
Okay thank you for looking into this. I wasn't sure about the scaling. I was implementing a OpenGl raycasting shader and run into a similar issue since the vdb has to be a 3d texture, so went another direction.
I also discovered some older videos and noticed there was an offset bounding box option in Blender, but it is no longer available.
Re: Animated OpenVDB Volumes
Posted: Mon Nov 29, 2021 8:33 pm
by Continuum
I think I am beginning to understand how this works. So I dived into the SDK instead, and I am beginning to get results within my application (I still can't get blender to animate imported vdb's though). But I am also having problems using vdb files generated in other apps. Getting closer though.
https://www.youtube.com/watch?v=SyP1BJJQwWA