Cg Parameters with Vertex Buffers?
I have a program that is working well by using DrawElements (a vertex buffer). I wanted to integrate Cg into the project. How can I pass position to my vertex shader and still use DrawElements?
I could do this in immediate mode but I would like to keep my vertex buffer.
NOMADMAN!
Does OpenGL pass vertex information to each vertex shader processed during a call to DrawElements. Can I expect to have a POSITION input in my vertex shader without explicitly setting the position parameter each vertex?
(If you didnt figure it out by now I'm terribly new to Cg and shders in general)
NOMADMAN!
(If you didnt figure it out by now I'm terribly new to Cg and shders in general)
NOMADMAN!
There are examples in the Cg documentation. On the bit about the OpenGL Runtime. I suggest you take a look.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement