Sign in to follow this  

problem with vbo

This topic is 822 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

hello.
I have a camera and i created a system for drawing on the screen the trace of movement of mouse.
The problem is that if i insert in the vbo directly the coords of the mouse of an 800 x 600 window like 172,12,0 ecc..... i see nothing, i must divide the original x and y by a value for see something.
WHy?
i have a camera with a position of 0,0,15 and i set up a prospective projection.
Now the trace of the mouse is far away on the 15 on z is possible to use unproject or something of similar for see the drag of the mose in the real position?
ps. i use glm.
thanks

Share this post


Link to post
Share on other sites

..and perspective projection is going to take your vertices to clip space, then viewport transformed to window coords which is exactly what you are inputting so what exactly do you expect to happen. I suggest you take a more closer look at the graphics pipeline for the API you are using to see how one goes from vertex data input to what you see onscreen.

Share this post


Link to post
Share on other sites

could you give more details? How are you creating your projection matrix? How are you using your projection matrix/vbo data? Have you set the GlViewPort to 800x600? Did you bind the vbo?

Edited by Solid_Spy

Share this post


Link to post
Share on other sites

This topic is 822 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this