PDA

View Full Version : how can i make the instancer respect the boudary of an object ??



jeromedeverite
07-02-2013, 10:15 AM
hello i've again a problem.
i've make an object ( triangulated polygon), and i want to have grass on it, so i use instancer with surface for instance position.
the issue is that the instances outflanck the boundary of the polygon, how can i fixe it ( with clip map i don't see how to do)??
thanks

RebelHill
07-02-2013, 11:18 AM
You cant really... not that Im aware of anyhow. The problem is one of "resolution"...

Draw a triangle, then try and "fill" it by drawing circles inside... You either have to have "gaps" or overlaps. The only solution is to draw smaller circles such as to minimise the appearance of this. Hence... make your item have a smaller footprint (so only a couple blades of grass) and use more, denser instances.

jeromedeverite
07-02-2013, 12:16 PM
hello RebelHill (thank for the reply).
you're right it's a solution ,but when the model become complicated and heavy it's really to long to set up.
perhaps a future request for fix this ,for the next lightwave, lol

jasonwestmas
07-02-2013, 12:17 PM
Yes, think of your instances as small pixels on a grid. The fewer pixels (or in this case polygons) the finer the instance can adhere to a specific kind of shape. Thus this forces you to use more instances to completely fill the shape that you are after.

jasonwestmas
07-02-2013, 12:20 PM
hello RebelHill (thank for the reply).
you're right it's a solution ,but when the model become complicated and heavy it's really to long to set up.
perhaps a future request for fix this ,for the next lightwave, lol

well there is no way for lightwave to know what shape you are after if you make a big bush and instance it at it's current scale. So the only real solution I think is to make your instances have a smaller radius, as RH explained.

RebelHill
07-02-2013, 12:56 PM
Yeah... theres no real "fix" you can do. I suppose you could get a function that would look for overlap, and then scale instances at the boundary... but then you've got the problem of mis-scaled instances. Its like any graphical integration, you only get a better fit as you decrease the absolute size of the "slices" filling the shape... https://upload.wikimedia.org/wikipedia/commons/2/2a/Riemann_sum_convergence.png

dpont
07-02-2013, 01:15 PM
The Edge node works in the node editor of DP Instancer
for masking unwanted instances on border,
connected in the Enable State (same than weight in native),
Surface Distribution must be relaxed (0% Dispersion, more than 10 passes),
result may vary, not sure with your geometry.

Denis.

jeromedeverite
07-03-2013, 01:42 AM
hello dpont, the result is almost correct, obviously the geometry is the problem, but it's a good point :)