View Full Version : Help! Problem with an OpenGL view

10-08-2000, 08:35 AM
Hey guys...ok I have this little problem.I'm making a terrain editor using MFC and one of my view is an OpenGL view.However,it's not turning out properly.It's kinda hard to explain in words so I've posted a link to my app.Included is the executable and the cpp source code that handles my OpenGL view.Keep resizing the OpenGL view (the one on the bottom right with the 2 triangles) and you'll see what I mean.I'm not sure what it is I'm doing wrong.So can you guys please download it and take a look at the source code? I would REALLY appreciate it.Thanx!

Here's the link: http://members.fortunecity.com/thegecko1/editor.zip

It's a 270KB download

(If the fortune city website tells you it doesn't permit links to it's files then just copy the link to your browser and open it there.)

[This message has been edited by TheGecko (edited 10-08-2000).]

10-08-2000, 11:16 AM
Very strange. Your code looks right (it is identical to mine) so it should be working. The only theory I can offer is that maybe you are handing the wrong values of height and width to the resize function?

10-08-2000, 11:28 AM
What specifically is wrong with the view? It looks fairly normal to me, although the flashing on resize is annoying and if I Alt-Tab away and then back to the app, it doesn't repaint that view properly.

Matt Craighead

10-08-2000, 11:33 AM
Keep resizing the view and you'll see what I mean.The 2 triangles are supposed to be centerd at all times and the view should automatically scale itself properly but that's not what's happening here.

10-08-2000, 02:14 PM
You're not calling resize on the OnSize event, only on OnMove...? Could that be it?

- Matt

10-09-2000, 07:39 AM
You are a GODDAMN GENIUS!!! That worked just fine! thanx!