使用 GLAD 进行 Raspberry Pi 项目
我想弄清楚如何为我的项目创建一个窗口。我想使用 OpenGL ES,并且我找到了有关如何使用 X11 和 EGL 创建窗口的在线指南,并且此选项工作得很好。
但我正在尝试遵循 OpenGL 指南,并且我能找到的所有内容都使用 GLAD 和 GLFW 来创建窗口,并且它似乎更容易使用和理解,但每当我尝试使用它时,我都会收到一堆错误,例如 “void Glad_glClearColor(GLclampf, GLclampf, GLclampf, GLclampf)”重新声明为不同类型的实体
。
当我尝试使用 此处。
它不适合 Linux,还是我还缺少其他东西?
I am trying to figure out how to create a window for my project. I want to work with OpenGL ES and I found online guides on how to use X11 and EGL for creating the window, and this option works just fine.
But I am trying to follow OpenGL guides and all I can find use GLAD and GLFW to create a window, and it seems much easier to work with and understand, but whenever I try to use it I get a bunch of errors like 'void glad_glClearColor(GLclampf, GLclampf, GLclampf, GLclampf)’ redeclared as different kind of entity
.
I got 58 errors just like that one when I tried using the code from here.
Is it not suited for Linux, or is there something else I am missing here?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
Raspbebrry 是基于 ARM 的开发卡,我不确定 GLFW 对树莓派的支持,但您可以使用带有 OpenGL 绑定的 SDL2 库来创建窗口并进行一些渲染
Raspbebrry is ARM based development card, I am not sure about GLFW support for raspberry pi but you can use SDL2 library with OpenGL bindings to create window and do some rendering