Determining ordering of vertices to form a quadrilateral

前端 未结 5 966
离开以前
离开以前 2021-02-10 18:24

Suppose I have 4 vertices in 2D space. Does anything know of an efficient algorithm which will give me an ordering of the vertices which corresponds to a simple quadrilateral?

5条回答
  •  野性不改
    2021-02-10 19:05

    A morton-curve or z-curve will deliver it. But I suggest a hilbert-curve or a moore-curve because of better space filling attributes.

提交回复
热议问题