View Single Post
  #4  
Old May 30th 19, 10:49 AM posted to microsoft.public.windowsxp.general,comp.os.ms-windows.programmer.win32
R.Wieser
external usenet poster
 
Posts: 1,302
Default Geforce GTX 275 - OpenGL initialisation problem when program is started from the commmand console. Update

(x-posted/continued from microsoft.public.windowsxp.general)

After mulling over what you wrote I realized I forgot to mention something
thats (most likely) important : My "command prompt" window is full-screen
(80x25 char). So when a GUI program is started the OS first has to
switch from text to graphics mode.


I think I've narrowed the problem down to the ChoosePixelFormat function
(might be a red herring though ...). When I start the program from a full
screen console window the returned result is 0x4, but when I start it from
within the GUI the result is 0x7. (no idea what those numbers mean, as MS
doesn't seem willing to part with that kind of info - not described with the
above function, SetPixelFormat or the involved structure).

I also just spend an hour or two trying to re-initialize the OpenGL DC, but
was twarthed by not being able to choose a new pixel format for it (which I
only noticed/read *after* having spend all that time. :-\ )

I guess the new question is: Other than delaying the calling of the
ChoosePixelFormat function (and with it the whole OpenGL context
initialisation - which causes its own problems), how to I get the
ChoosePixelFormat function to return a result in reference to a GUI DC ?

Regards,
Rudy Wieser


Ads