Group By Range, "dynamic Group Filter values ?"

   1133   4   1
User Avatar
Member
5 posts
Joined: Nov. 2016
Offline
Newbee question, sorry …
So i have this piece of geometry and i want to randomly select
some of its points, i m using a “Group By Range”…very easy.
_But what if i need to have a lot of ponts selected at the top of my geometry
and almost none at the bottom ?
I think this could mean having a “ramp” driving the group filter values along
the y axis.Or maybe having a “gradient” on my geometry, from white at the top to black at the bottom,
gradually decreasing the amount of points randomly selected….(255,255,255)=100% (128,128,128)=50% (0,0,0)=0%
I hope someone can get what i am asking for, i will take any hints leading me toward a potential solution.
Edited by michelm - March 24, 2019 05:02:09
User Avatar
Member
5 posts
Joined: Nov. 2016
Offline




here is a screenshot…

Attachments:
point_group.jpg (920.3 KB)

User Avatar
Member
474 posts
Joined: July 2005
Offline
Hi,

here is an example using a ramp.

Attachments:
random_select.hipnc (76.6 KB)

User Avatar
Member
5 posts
Joined: Nov. 2016
Offline
Thank you so mush Aizatulin !!
I was able to figure it out from the file you sent me.

I replaced “100” with the total points amount in my geometry
Added @sel=1 in Base Group of my group SOP
Edited by michelm - March 24, 2019 09:00:09
User Avatar
Member
474 posts
Joined: July 2005
Offline
michelm
Thank you so mush Aizatulin !!
I was able to figure it out from the file you sent me.

I replaced “100” with the total points amount in my geometry
Added @sel=1 in Base Group of my group SOP

Sure

One little thing. It would be better to replace the line in the random select node.
To avoid symmetric patterns.

//float w = rand(floor(100*V.x + 100*V.y + 100*V.z));
float w = rand(floor(1e4*V.x + 1e5*V.y + 1e6*V.z));
  • Quick Links