Separated sorting from atlas drawing