Another way to do it would be to pick all objects of one class and then modify - add surface. this merges the overlapping objects. It's not as precise, though, and I would only recommend it if you're sure that the objects are 100% exactly on top of each other