fixed grid rendering, added z-order to 2d points