平面方程的多面体
我有几个 3d 平面(其中 3-10 个),由它们的方程(三个系数和偏移量)定义。这些平面是凸多面体的边缘。我需要画那个多面体。我怎样才能做到这一点?我可以使用哪些软件/库/算法?我在 Linux 中工作,通常使用 C 或 C++。
I have a few planes (3-10 of them) in 3d defined by their equations (three coefficients and the offset). These planes are the edges of a convex polyhedron. I need to draw that polyhedron. How can I do that? What software/libraries/algorithms can I use? I work in Linux and I'm usually using C or C++.
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
每个平面对在两个平面上都相交于一条直线。每个平面都包含一组相交于点的线,所有这些都是您必须以凸面方式连接的多面体的边缘点。
有了一些数学/几何技能,你应该能够解决这个问题,但是使用一个库(fe CGAL)当然可以简化它并防止您重新发明轮子。
Every plane pair intersects in a line on both planes. Each plane then contains a set of lines that intersect in points, all of those are the edge points of your polyhedron you'll have to connect in a convex way.
With some math/geometry skills, you should be able to solve this, but using a library (f.e. CGAL) of course simplifies it and prevent you from reinventing the wheel.