MASH: Scatter

MASH: Scatter

adenne
Advocate Advocate
10,630 Views
7 Replies
Message 1 of 8

MASH: Scatter

adenne
Advocate
Advocate

I'm trying to scatter some bushes on a flat plane. I'm using scatter, with a visibility texture of a white line, so only bushes appear on the white line.

 

My problem is that the scatter always leaves gaps and I want a solid line of them. No matter how much I increase the distribution amount, the gaps remain and instead it just adds more and more on top of each other?

 

Is there anyway to prevent this or have some collision detection so it doesn't place objects on top of each other?

 

thanks

 

 

0 Likes
Accepted solutions (1)
10,631 Views
7 Replies
Replies (7)
Message 2 of 8

adenne
Advocate
Advocate

so does anyone know how to get mash to scatter on anything without leaving patches of gaps even with a really high instance count?

 

There must be something not quite right with it, if you are getting lots of meshes ontop of each other and areas with no mesh?

0 Likes
Message 3 of 8

adenne
Advocate
Advocate

I'm adding a screenshot to show the massive overlapping of geo and still gaps...

 

so frustrated with maya 2017, so many crashes, some real lack of testing by autodesk. (sorry couldnt help myself rant..been one of those days of bugs)

 

 

gaps.jpg

 

 

0 Likes
Message 4 of 8

mspeer
Consultant
Consultant
Accepted solution

Hi!

 

What happens here is the problem with a full random placement. Random means that there always will be a chance to leave some space empty regardless how far you crank up the value for generated objects (the probability will get smaller but never reaches zero). The benefit of this "easy" implementation is that it's very fast and stable even with many thousands of instances, a requirement for real-time usage.

 

Some workarounds for your problem:

In Mash you could start with an even distribution and use MASH_Random or MASH_Transform to add some small amount of offset on the Position of the objects. As alternative you could use other tools like Xgen or a manual approach for the placement of your objects.

 

Based on your first post i recommend to use particles, the attribute "Particle Size" in combination with "Self Collide" should give you the amount of control you want to prevent overlapping. MASH -> Utilities -> Connect nParticles to MASH. You need to run some frames of animation because self-collision is a simulated effect, but after this you can freeze the particle state and skip the simulation.

0 Likes
Message 5 of 8

adenne
Advocate
Advocate

thanks for the reply, much appreciated.

0 Likes
Message 6 of 8

adenne
Advocate
Advocate
also XGen, i find it so buggy, crashes, slow etc
0 Likes
Message 7 of 8

Anonymous
Not applicable

update:

this overlapping can be solved by simply adding a dynamics node... play few frames and let them collide a little.

Message 8 of 8

mspeer
Consultant
Consultant

Hi!

 

Dynamics in MASH are available since Maya 2018.

0 Likes