Refactored GEOObjects::mergeGeometries().