Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我有一组未排序的线段,彼此之间没有任何绑定。每条线用 2 个点 (x,y) 描述。我可以搜索具有相同点的线,这意味着它们应该连接起来。
每条线都有一个粗细属性。我需要将每条路径偏移这个厚度,并创建 4 个点来描述最终的多边形(每条线)。
截图 1
现在我需要改进它以正确处理角落(连接)。但不知道该怎么做。
期望的结果:截图 2
有关使用多边形骨架偏移多边形的一种方法,请参见此处(这是您在此处尝试执行的操作)。