Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why not use VAO? OpenGL3.0 need VAO. #83

Open
shunlibest opened this issue Jan 30, 2024 · 0 comments
Open

Why not use VAO? OpenGL3.0 need VAO. #83

shunlibest opened this issue Jan 30, 2024 · 0 comments

Comments

@shunlibest
Copy link

My computer system is MacOS (M1). If I run the project directly, I only see the background color, not the cube. (I'm running fine on Windows). I checked the data and said that after OpenGL3.0, if you use core mode, you must use VAO. But I don't see that in the code.

Add the following statement to MacOS to make it work:

val vaoId: Int = GL30.glGenVertexArrays()
GL30.glBindVertexArray(vaoId)
val clock = Clock()
while (!canvas.shouldClose()) {
   renderer.render(scene, camera)
   box.rotation.x += 1f * clock.getDelta().toFloat()
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant