Sign in to follow this  
McFury

Picking related problem, screen goes wierd on click.

Recommended Posts

McFury    144
Hi, I have a problem in my application, where when I enable picking (using selection mode and glPickMatrix) the application screen seems to split and veer. When I stop calling the pick function the screen goes back to normal, so i was assuming it was caused when I reset the perspective/viewport settings in selection mode, but even with all of the gl calls removed it still occurs. I dont clear the depth/color bit flags before i do the picking, and i dont swap the buffers when its complete. The picking actually works, and it selects the correct objects i want it to, I can tell because when i comment out the call to switch to select mode it renders the small box on the screen exactly where i want it to be zoomed in on. But i really need to solve this screen veering that comes with it. Ill post a screenshot of what is happening below, i'll post some code if its not obvious, if anyone could help, thankyou so much. This is the screen without holding the mouse button down (not picking) No picking This is the screen holding the mouse button down (picking) Picking

Share this post


Link to post
Share on other sites
ViperG    206
post your mouse picking code

PS looks like graphical corruption, could be bad ram on video card.

and something is messing with your z buffer, so that might be the problem...

Share this post


Link to post
Share on other sites
jezham    204
I don't use that method to pick. But your farClip plane looks too close, what settings are you using for near and far? Try 1.0 and 10000.0, does that change anything?

Also, why not double buffering after selection? Surely you want to see the results of your selection!

Share this post


Link to post
Share on other sites

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