Automatic objects intersection and triangulation - how to ?

Hi there,

I am a developer and I am currently using Blender to design a 3D level for my game prototype.
What I need is a scene composed by some objects that are 100% triangulated with no polys inside each others.

I can obviously create a new scene from scratch that would have these properties, but I was wondering whether it was possible or not to get to that result from an existing scene, by applying transforms and/or scripts.

Here is a small explanation of what I want to do:

The first screenshot (screenshot1) shows two objects (rectangles), one of each having a part of it inside the other (the pole is inside the plane).



The second screenshot shows the difference between the two objects. Now the pole’s base is on the plane and no longer inside.

The third screenshot (screenshot3) shows the result that I need, which is the pole being cut at the intersection of the plane, the two objects joined and triangulated.

Is there a way to get from screenshot1 to screenshot3, automatically and with any scene ? I mean, is there any way to automatically get the intersections between all the objects of a scene, remove the polygons that are inside and get the triangulated result ?
The idea is to have the full representation of a scene (or level) using only adjacent triangles…

Thank you in advance for your help.
Best regards.

Boolean modifier followed by Triangulate modifier