Jump to content
magneto

How to scatter points in a volume uniformly?

Recommended Posts

Hi,

I am scattering points in a volume but I am always getting this kind of non-uniform distribution. What's the best way to get uniform distribution? I set the density to 1 using a volume wrangle but then I still have to have enough resolution to accurately fill in the volume using points, or it leaks some points over the borders.

m307X1O.png

Is there a better way to do this in Houdini?

 

Thanks :)

Share this post


Link to post
Share on other sites

Points From Volume SOP will fill the volume in a grid or tetrahedral configuration.
Not sure if that is what you are looking for.

-b

  • Like 1

Share this post


Link to post
Share on other sites

You can add a point for each voxel you have by typping in a volumewrangle this:

if (f@density>0)

addpoint(0, @P); 

 

 

  • Like 2

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×