JeremyR
Im trying to figure out how Maya evaluates collisions for its 'old'particle system and an object. I thought it was based on normals but actually collisions happen on the backside of an object also where normals are facing the opposite direction.

Whats the go here?
Reply 0 0
pshipkov
as far as i know it goes something like that:
current frame - is particle on the other side of the surface -yes/no
if no - keep going
if yes - alter velocity and position at collision point to look like both things collide.

how exactly the collider in maya works i dont know, but i know the person who wrote it (he is not at alias anymore). i guess normals are involved, but the solver keeps track of wich side particle is right  before collision occurs.

i may dont forget i may ask that person for a hint or two.
Reply 0 0
JeremyR
mmm, dont worry too much. For some reason I always had it in my mind that surface normals were responsible so I wanted to play around with soup and normals and collisions but this approach wont work. Which lead me to the question as to how collisions actually do work here. Theoretically I would say it has to know the normal in order to find out the angle of reflection/bounce but then I guess it doesnt really care if its from the front or behind, thats a shame.
Reply 0 0
pshipkov
Geometry is converted to triangles internally - that's what the sweep nodes do. Also, think normal direction matters for the solver to keep track of when particles pass through the colliding geo and run "collision" logic on the offenders. But that's internal and you cannot touch there.
Reply 0 0
JeremyR
Okay thanks again. I think I might have a solution, will sure soon.
Reply 0 0
JeremyR
Well it wasn't as hard as I thought it was going to be. I forgot about the geoConnector and the tessellations attribute which would explain the triangulation and I was trying to get the normal of the surface to affect the traceDepthPP which didnt work. But...the easier method was just using a bounding object and attribute transfer to transfer traceDepthPP directly over to particles, now it works check it out when you have a chance.
Reply 0 0
JeremyR
Okay this one needs your help, I kinda have it working but there is a problem with non-persistant attribute transfer values.

This time Im passing color through mesh to affect traceDepthPP but the problem is with the values coming out of the last AT node. These values are changing and dropping to zero which breaks my collisions, I need to to remain at 10 (or above 1). You can see Ive got 3 displayComponents along the graph and its the one coming out of the last AT node that is not playing nicely.
Reply 0 0
pshipkov
If i understand your plan right i think they are passing through because of the solver not keeping them on top of the plane.
Reply 0 0
JeremyR
The ones that shouldnt be passing through are because the outWeightPP appears to be swapping values for some reason. Im pretty sure its not the solver because earlier I tried a playback speed of 0.2 and got the same result.
Reply 0 0
pshipkov
Ok, can you clarify what the end result should be ?

Also, after the AT nodes you use arrayToPointColor. You don't need that. The AT nodes have flag that is turned on by default and assigns colors automatically to the passing through the node geometry. This will save you couple of cycles.
Reply 0 0
JeremyR
pshipkov wrote:
The AT nodes have flag that is turned on by default and assigns colors automatically to the passing through the node geometry.


Nice thanks for that one.

Okay my objective was first to test bounding objects passing outWeightPP into traceDepthPP and this works easily. Then I want to try passing outColor from vertex of mesh into traceDepth - this is where I am coming unstuck.

If you turn on numeric for particles and look at traceDepthPP you can see whats happening. If you compare that with the rgb values on the last componentDisplay there is a little inconsistancy, its almost like every timestep as Maya pulls data from the splitRgbaPP, traceDepthPP zeros out first before it receives the correct value therefore allowing the particles to pass through the collision object.
Reply 0 0
pshipkov
got it let me take a closer look
Reply 0 0
Reply