[PATCH v2 1/3] d2d1: Add some helpers for geometry figure manipulation.