'Camera collision in BabylonJS

I'm trying to make a camera not overlap with meshes. Here I reproduced what is happening https://www.babylonjs-playground.com/#4NHCRD#4 You can see that the small ball with an attached camera can see through the big ball on collide.

I've tried all tricks from here https://doc.babylonjs.com/divingDeeper/cameras/camera_collisions but no success :pensive:



Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source