opengl view question

Something very strange is happening in my engine's tile drawing routine(s)(tiles=textured quads). I normally draw only the tiles which are visible(and nearly visible so there's no abrupt popping of tiles) but for some odd reason opengl initially only draws tiles which are immediately and completely within the bounds of the window or view.

If I decrease the size of the view/window, everything is drawn properly(I don't have any special reshape function if it makes any difference).

The pic on the right is how it appears normally, and the pic on the left is after I have decreased the size of the window/view(after decreasing it, I can then resize it anyway I like and everything will still draw properly.

sounds like your algorithm for checking if tiles are "nearly visible so there's no abrupt popping of tiles" is accounting for the resizing of the window. (or calculating it wrong somehow); can you post the code that conducts that test?
-wyrmmage

wyrmmage Wrote:sounds like your algorithm for checking if tiles are "nearly visible so there's no abrupt popping of tiles" is accounting for the resizing of the window. (or calculating it wrong somehow); can you post the code that conducts that test?
-wyrmmage

No it's not my drawing code(it doesn't matter if I draw the entire map or only the visible+near visible tiles), the code itself is fine.

The only thing(with my extremely limited knowledge of opengl) that comes to mind is that somehow the clipping planes are initially set to the bounds of my viewport, and perhaps somehow resizing the window extends them or something? I don't know, but I can't begin to figure out what's happening

here's the drawing function(which draws the entire map for the sake of my testing purposes):