Merge quad tree implementations