Remove multiple meshes based on a radius


I would like to delete several meshes according to a given radius.

For the moment in this PG, we can paint several mesh and with CTRL this removes a single mesh. The function is line 159.

Does anyone know how to do it please.

Thank you in advance.

you can use mesh.getBoundingInfo().intersects()

This function accept anopther boundingInfo that you can create from two vectors (that defines a box): BoundingInfo - Babylon.js Documentation

1 Like

I’m trying but I don’t understand how to use this getBoundingInfo().intersects() function

Using distance :slight_smile:


- if(pickInfo.pickedMesh != this.ground) {
+ if(pickInfo.pickedPoint) {

and recoded removePaintFolliage function


It works well. This is exactly what I was looking for.
Thank you so much aWeirdo

I did some retouching :