Add rect2d class