【发布时间】:2014-02-13 01:54:53
【问题描述】:
是否有适用于 VS2012 C++ 的 Delaunay Triangulation 代码/库?我希望在不使用第三方二进制文件的情况下得到一些轻量级的东西。
我已经尝试了很多(Triangle、A Delaunay triangulation function in C、poly2tri、Geom Fade 2D)。很多只是不好用,不然不兼容vs2012;
有人有什么建议吗?非常感谢
编辑:三角形问题:
有一个三角形网格生成器(Shewchuk,CMU),“Triangle”,因其轻量级而被人们推荐。它是用 C 编写的。但是我不能在我的 VS2012 C++ 项目中使用它。我正在使用 x64 平台编译它。我在 Windows 7 64 位上。
基本上,我将 triangle.c 编译为所描述的 makefile。因此,生成了一个 triangle.o。我那时 1.在我的解决方案中添加了 triangle.o 作为附加依赖项, 2.在我的项目中添加了 triangle.c 和 triangle.h 。 3.将C/C++预编译头选项中的triangle.c更改为“不使用预编译头”
然后我遇到了很多这样的错误:
1>C:\Program Files (x86)\Windows Kits\8.0\Include\um\winnt.h(430): error C2143: syntax error : missing ';' before '*'
1>C:\Program Files (x86)\Windows Kits\8.0\Include\um\winnt.h(430): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\8.0\Include\um\winnt.h(497): error C2143: syntax error : missing ';' before '*'
1>C:\Program Files (x86)\Windows Kits\8.0\Include\um\winnt.h(497): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\8.0\Include\um\winnt.h(498): error C2143: syntax error : missing ';' before '*'
1>C:\Program Files (x86)\Windows Kits\8.0\Include\um\winnt.h(498): error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
1>C:\Program Files (x86)\Windows Kits\8.0\Include\um\winnt.h(2517): warning C4391: 'SHORT _InterlockedIncrement16(volatile SHORT *)' : incorrect return type for intrinsic function, expected 'short'
【问题讨论】:
标签: c++ visual-studio visual-studio-2012 graphics computer-vision