Either the minimalGridAABB needs to use float or 1 should be substracted in all directions