0
$\begingroup$

enter image description here

I’m using a combination of techniques within geometry nodes such as Ray casting, geometry proximity, to affect the density of a volume cube node.

I’ve defined my density attribute, and I’d like to blur it to create a softer falloff. Naturally I tried using the blur attribute node, but so far I haven’t got it to work.

I tried placing the blur node directly on the density attribute (just before it goes into the volume cube density socket) and that didn’t work. I also have tried blurring some of the contributing attributes earlier in the node tree, before they were captured.

But none of the options worked.

I’m wondering if it’s just not possible to blur the density attribute of a volume cube?

Could anyone clarify if that should be possible, or if it’s not supported?

Thank you

$\endgroup$
4
  • 4
    $\begingroup$ Would you mind at least showing a screenshot of your node setup? Because it is not always easy to visualize in one's mind what you have actually done there. And if it is a complex setup and we cannot use some simple nodes to try and solve it, it would even be better if you uploaded your file here: blend-exchange.com and edit it into your question by following the instructions there to spare us recreating everything by ourselves. $\endgroup$ Aug 31, 2023 at 7:15
  • $\begingroup$ I think you have the sane issue as this guy blender.stackexchange.com/questions/300209/… . are you using a compare node? that could be why it isn't smooth. (I'll give you a solution for the blur node later 😉 that is something that just doesn't work) $\endgroup$
    – shmuel
    Sep 1, 2023 at 2:31
  • $\begingroup$ Thank you Gordon, I've just amended the post to include a screenshot and uploaded the blend file also $\endgroup$
    – btn_237
    Sep 2, 2023 at 7:19
  • $\begingroup$ Hi shmuel, I'm unsure if that's the same issue I'm having, however I've now updated with a screenshot to show the example more clearly. I've managed to work around the issue by combining the gradient you see in my screenshot with another cylindrical grad created using a gradient node, which does the trick (I'm using the gradients to create smoke and fire in the volume shader). Although if it was possible to simply blur the generated density gradient that would be a lot simpler. Appreciate this may not be possible as it stands. $\endgroup$
    – btn_237
    Sep 2, 2023 at 7:33

1 Answer 1

3
$\begingroup$

so the reason to why the blur node doesn't work for the volume use is because it doesn't have topology, which the blur attribute used for blurring. The volume still has kinda like a point grid, therefor you could transfer attributes to it etc. but it isn't any domain.

There is a solution to this however it's not the most performant and I don't recommend using it. That being said, here is a solution:

  • To solve the problem of there being no topology/geometry on the volume is to just first to it on geometry and then transfer it to the volume.

  • The way you do this is with a Lattice mesh (you will make in GN) preferably with faces to you could make a nice interpolation from the faces.

    • You could do this by duplicating a grid z resolution times with a resolution or x resolution $\times$ y resolution.

    • Then extrude the edges up the height of the distance between the grids $Z \ dimension \over Z \ resolution - 1 $ also don't extrude the top grid.

    • then merge by distance

  • Then sample nearest surface the float density.

  • (also capture the attribute)

Here is a setup:

enter image description here

this is how the node looks:

There might be a way to line up the lattice points exactly on the volume voxels, but I think this is good enuff.


I highly don't recommend this.

$\endgroup$
1
  • $\begingroup$ Thanks for clarifying the reason why the blur node doesn't work. I appreciate you supplying the possible work around, although yes - I need something that will perform decently, so I'll follow your advice about not using that method! $\endgroup$
    – btn_237
    Sep 2, 2023 at 7:09

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .