# How to scatter points based on a probability map?

## Recommended Posts

Hi......

I want to scatter some points on a plane, depending on a density map or probability map. The map will be black and white, white is probability 1 and black probability 0. Now I want to know the method or algorithm to do this. I know that, we can use attribute in scatter sop, but the detail depends on the number of points in the source geometry. I want to do it using map.

Another method to do that is using fur sop, and keeping only the root points. But I want to use the method in my own HDK, so if you can provide the algorithm, I can code it.

##### Share on other sites

Hi......

I want to scatter some points on a plane, depending on a density map or probability map. The map will be black and white, white is probability 1 and black probability 0. Now I want to know the method or algorithm to do this. I know that, we can use attribute in scatter sop, but the detail depends on the number of points in the source geometry. I want to do it using map.

Another method to do that is using fur sop, and keeping only the root points. But I want to use the method in my own HDK, so if you can provide the algorithm, I can code it.

http://www.sidefx.com/index.php?option=com...&Itemid=216

Does it help?

##### Share on other sites

HI SYmek...

I have seen the video and it uses a point/primitive attribute to scatter using scatter SOP, and not using map. I want to use the method in my HDK , and it may accept any resolution of geometry, so using map is a must, And knowing the algorithm would be better.

##### Share on other sites

HI SYmek...

I have seen the video and it uses a point/primitive attribute to scatter using scatter SOP, and not using map. I want to use the method in my HDK , and it may accept any resolution of geometry, so using map is a must, And knowing the algorithm would be better.

Sorry, I haven't noticed in which corner you put this post...

##### Share on other sites

There are lots and lots of papers about distributing quality points on a plane (based on some importance criteria, like density, luminance, whatever). The fastest method I'm aware of at the moment is the "median cut" algorithm proposed by Paul Debevec in a Siggraph sketch. There's a more detailed presentation of it here.

It's simple to implement and very fast.

I'm guessing that in your case, since you don't want to be limited by geometric detail, you'll be using some parametric space attached to the geometry to map to the more continuous (2D) distribution... so this might be what you need.

Like I said, there are at least 6 other methods that have been published that come to mind, but this is probably the fastest and easiest to implement.

HTH.

##### Share on other sites

You could try using GU_RandomPoint. However, I don't know much about it so this as far as I can help.

## Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

×   Pasted as rich text.   Paste as plain text instead

Only 75 emoji are allowed.

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×