开发者

Cameras and Modelview in OpenGL ES (WebGL)

I'm having a little trouble with my OpenGL transformations -- I have a vertex shader that se开发者_StackOverflowts gl_Position to projection * view * model * vertex. I have code that generates a view matrix by inverting the model matrix of a camera in space, but when I set the object the camera is looking at to rotate in space, it seems as if the camera is rotating instead.

What could be causing this?


Apparently I had projection * model * view * vertex instead. Oops!

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜