View Full Version : GL Rendering Context
03-27-2000, 02:20 PM
If my program fails to create a GL Rendering context, what can I do to fix it?
You have to make sure that the Pixelformat has been set correctly and that you rendering context exits too.
if (!hDC =GetDC(hwnd))
error! This one means that your video card doesn't support the pixel format you asked. You'll have to change some parameters
Then if this ok, maybe it's the window fault.
These are the things you have to be sure of:
when you make the window class, you must have CS_OWNDC for the style.
If that is all ok, well I must say I don't know, and let's hope somebody else has an answer.
[This message has been edited by Gorg (edited 03-27-2000).]
03-27-2000, 09:42 PM
i've got problems with the RC when going fullscreen ( == program crashes!! )...
all the tutorials from nehe and stuff can't create a RC..has it to do with win2000 ??
03-28-2000, 02:26 AM
Oh no!.. that doesn't sound good!.. Have you tried on win9x too?.. And it works there?..
Hopefully its a driver problem. Does the card you have have win2000 drivers?. Check that!
03-28-2000, 03:30 AM
a few hours ago i visited a friend of mine,
carrying a disk with openGL stuff in my pocket..
he's got the same graphics card (ATI Rage pro) and same 'puter ,with win98...
We couldn't get this stuff to work,too!
It MUST have to do with the ATI crap...
03-28-2000, 04:22 AM
Oh I see... Have you tried running other OpenGL apps?.. Like Quake or something?.
03-28-2000, 07:28 AM
nope,i don't have quake or something...
i also have NO time :-( to code some openGL stuff.
a little question: when i create a window (in Windows...) with the argument WS_POPUP(with no other params,like WS_SIZEBOX),
am i fullscreen then? if i am,my own code works, if not,could you tell me how to do it?
i think i will study some code now...
04-04-2000, 06:35 AM
hehe, i gots windows 2000, my ATI Rage IIc card does the nehe stuff fine (under 98 partition)... I haven't tried it under 2k... I don't go on 2k much, becuase I have a cheap korean sound card, which refuses to make 2000 drivers.
I have a voodoo 2 and an ATI Rage IIc, and I seem to be having a similar problem.
When I try to run Nehe's first windows tutorial fullscreen, it dies on
However, the program works fine when I run it in a normal window.
If I put
then the program dies while trying to get the PixelFormat.
If Gorg is right, then I should mess with my pdf settings in hopes of finding a setup that likes my video cards. But so far I haven't been able to find a working configuration.
Hrm, I again tried moving around chunks of the NeHe code, and now I successfully get through the pfd error checking stuff without any problems. But it still fails when I try hRC=wglCreateContext(hDC).
So now I really have no idea were the problem is.
Take 3dfxgl32.dll put in program dir, rename to opengl32.dll, everything works.
I really should have figured that out earlier :P.
Powered by vBulletin® Version 4.2.2 Copyright © 2015 vBulletin Solutions, Inc. All rights reserved.