在 Windows 7 上设置 opengl 和 glut
我的计算机上安装了 cygwin 和 netbeans,可以兼容地工作。我想设置 opengl 和 glur 并将它们绑定到 Netbeans 中的 c/c++ 项目?但是,我找不到如何在 w7 上设置 opengl 和 glut 的方法。有什么帮助吗?
i have cygwin and netbeans installed on my computer working compatibly. I want to set up opengl and glur and bind those to my c/c++ projects in Netbeans? However, I couldn't find a way how to set up opengl and glut on w7. Any help ?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
www.opengl.org 上的 GLUT 页面 包含一个指向 < a href="http://www.cs.csustan.edu/~rsc/SDSU/GLUTinstall.html" rel="nofollow">这些说明。你尝试过这个方法吗?
请注意,它们似乎特定于 Microsoft Visual C++。确保替换路径,使其与您的 NetBeans 安装相匹配。
The GLUT page on www.opengl.org includes a link to these instructions. Have you tried this method?
Note that they seem to be specific to Microsoft Visual C++. Make sure you replace the paths so that they match your NetBeans installation.
刚刚经历了这种痛苦才能启动并运行一些依赖于 GLUT 的示例程序,这对我来说很有效。
注册成为 NIVIDA 开发人员 (https://developer.nvidia.com/join) 并使用他们的现在旧版 CG 工具包 (https://developer.nvidia.com/cg-toolkit-download)。您可能想看看是否可以在不成为开发人员的情况下下载它。
这包括 32 位和 64 位预编译的 GLUT 库和标头。请参阅以下 URL:http://http.developer.nvidia.com/Cg/glut。 用于 Windows 的 Cg Toolkit 安装程序
提供了预编译的 GLUT 32 位(如果选择,则为 64 位)版本。 GLUT 以动态链接库 (DLL) 和静态库的形式提供。
GLUT DLL 称为 glut32.dll,需要链接 glut32.lib。这些 32 位版本通常安装在:
c:\Program Files\NVIDIA Corporation\Cg\bin\glut32.dll
c:\Program Files\NVIDIA Corporation\Cg\lib\glut32.lib
64 位 (x64) 版本安装在:
c:\Program Files\NVIDIA Corporation\Cg\bin.x64\glut32.dll
c:\Program Files\NVIDIA Corporation\Cg\lib.x64\glut32.lib
我知道这很奇怪,但是 glut 非常古老,很多东西都需要名称专门为“glut32”,即使对于 64 编译也是如此。
希望这有帮助!
Having just gone through this pain to get some example programs up and running that rely on GLUT this is what worked for me.
Sign to be a developer for NIVIDA (https://developer.nvidia.com/join) and use their now legacy CG toolkit (https://developer.nvidia.com/cg-toolkit-download). You might want to see if you can download that without being a developer.
This includes both a 32 bit and a 64 bit pre-compiled GLUT library and header. See the following URL: http://http.developer.nvidia.com/Cg/glut.html
he Cg Toolkit installer for Windows provides a pre-compiled 32-bit (and 64-bit if selected) versions of GLUT. GLUT is provided both as a Dynamic Link Library (DLL) and a static library.
The GLUT DLL is called glut32.dll and requires linking against glut32.lib. These 32-bit versions are typically installed at:
c:\Program Files\NVIDIA Corporation\Cg\bin\glut32.dll
c:\Program Files\NVIDIA Corporation\Cg\lib\glut32.lib
The 64-bit (x64) versions are installed at:
c:\Program Files\NVIDIA Corporation\Cg\bin.x64\glut32.dll
c:\Program Files\NVIDIA Corporation\Cg\lib.x64\glut32.lib
Which is wierd I know, but glut is super old and lots of things require the name to be specifically "glut32" even for 64 compiliing.
Hope this helps!