OpenGl movement problem(textures)
I made my program smooth scroll and my sprite moves perfectly but when my world scrolls, I get weird lines like these:
Please help! This only happens when it scrolls
It appears you are skipping a pixel when tiling, you couldn't possible post some code could you? Just make sure you are rendering out tiles at the same width as you are moving along the x-axis.
I had the same problem tiling in my game. Try using:
when you load your textures.
Alternatively, try making your tiles over lap just a little bit, and that might alleviate the problem.
Nice screen by the way :D.
glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE );glTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE );
when you load your textures.
Alternatively, try making your tiles over lap just a little bit, and that might alleviate the problem.
Nice screen by the way :D.
Thanks! I like feedback on the looks of my game :D
I know this sounds weird but I get a compiler error that says GL_CLAMP_TO_EDGE is not defines, even though it is part of the OpenGL standard library. Any thoughts?
I know this sounds weird but I get a compiler error that says GL_CLAMP_TO_EDGE is not defines, even though it is part of the OpenGL standard library. Any thoughts?
it all worked, except now i get darker less visible lines like the old ones but only when I scroll down. Any Ideas?
are you using a frame buffer for rendering? If not it could be that the time it takes to refresh the screen (i.e. paint the client rectangle of your app) is out of synch with the time it takes you to render a frame. It may be this delay is causing you to see a flickering of sort (not sure if that's actually the problem or something else)
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement