Archived

This topic is now archived and is closed to further replies.

evilclown

what is ChangeDisplaySettings?

Recommended Posts

I tried to find information on it so I knew what to pass but I didn''t see it at www.opengl.org Here''s the error:
129 template.cpp
 `CDS_FULLSCREEN'' undeclared (first use this function)

173 template.cpp
 `PFD_DOUBLE_BUFFER'' undeclared (first use this function)
 
It tells me there is a pase error. I thought this is how the tutorial did it:
  static PIXELFORMATDESCRIPTOR pfd = {
    sizeof(PIXELFORMATDESCRIPTOR),      //sizeof PFD
    1,                                  //version number
    PFD_DRAW_TO_WINDOW |                //format must support window
    PFD_SUPPORT_OPENGL |                //format must support OpenGL
    PFD_DOUBLE_BUFFER,                  //format must support double buffering
    PFD_TYPE_RGBA,                      //request RGBA format
    bits,                               //select color depth
    0, 0, 0, 0, 0, 0,                   //color bits ignored
    0,                                  //no alpha buffer
    0,                                  //shift bit ignored
    0,                                  //no accumulation buffer
    0, 0, 0, 0,                         //accumulation bits ignored
    16,                                 //16bit z-buffer (depth buffer)
    0,                                  //no stencil buffer
    0,                                  //no auxiliary buffer
    PFD_MAIN_PLANE,                     //main drawing layer
    0,                                  //reserved
    0, 0, 0                             //layer masks ignored
  }; 
I thought this would be in the api, but it didn''t find anything.

Share this post


Link to post
Share on other sites
*sigh* Search the forums before you post stuff like this. It gets answered every day.

put this right after you include windows.h:

#ifndef CDS_FULLSCREEN
#define CDS_FULLSCREEN 4
#endif


and in order to fix the other problem, spell PFD_DOUBLEBUFFER correctly.

Later,
ZE.

//email me.//zealouselixir software.//msdn.//n00biez.//
miscellaneous links

[if you have a link proposal, email me.]

Share this post


Link to post
Share on other sites