assurance-tunnel
assurance-tunnel
assurance-tunnel
assurance-tunnel

​proximty detection of 2 shapes



  • Hi,

    I have 2 shapes that move. Now I want to trigger an action, if the shapes come closer.

    I tried it with the [eye] actor by looking the row/col. next to the XY position of shape 1 and compare this to shape 2. - But this a lot of comparing work. So may be - there is a simpe way to check if, there one shape is close to the other one by cheking the XY position of shape 1 and shape 2.

    thanks for a hint!

    best,
    fränk



  • using Eyes ++ you can make use of the object count function. if your 2 shapes are close enough together, they will become 1 shape. also, there is a blob proximity actor if you need more detailed data on the distance between the 2 shapes.



  • Hi,

    done that. Simply subtract the x and y values of your shapes. With the following 'inside range' you can define the distance when something should happen. With two times 1 the 'logical calculator' will output 1 and trigger whatever you like.

    best

    r



  • @reinhard

    Great thanks for this! I will try it out.