← Back to team overview

yade-users team mailing list archive

Re: [Question #682290]: the correct use of collider.avoidSelfInteractionMask ?

 

Question #682290 on Yade changed:
https://answers.launchpad.net/yade/+question/682290

Jérôme Duriez proposed the following answer:
It again turns out that both #1 and #2 are somewhat incorrect... (thank
you Jan Stransky !)

I overlooked the fact that interaction possibility depends on mask
compatibility in the first place, before any avoidSelfInteractionMask
consideration..

So, in an example with 3 mask values assigned to particles (0b10 =
"blue", or 0b01 = "green", or 0b11 = "red"), and a with
collider.avoidSelfInteractionMask = 0b01:

green particles would not interact with blue particles because they are not mask-compatible (do not share any "1" bit in common)
green particles would not interact with other green particles because of avoidSelfInteractionMask,
red particles would not interact with themselves either, for the same reason
blue particles would interact with themselves, on the contrary

For the complete list of possibilities, see https://gitlab.com/yade-dev/trunk/blob/master/pkg/common/Collider.cpp#L15.
It can anyway not be more confusing than my comments here...

-- 
You received this question notification because your team yade-users is
an answer contact for Yade.