CBS_FULLSCREEN + Dev-C++
My compiler (dev-c++) tells me CBS_FULLSCREEN is undeclared in lesson02 from NEHE productions. What do I do?
it was the msvc version, i cant afford msvc cause im pretty poor now.
Here''s a snippet of code (e.g. the line where it''s problematic)
/* begin code */
// Try To Set Selected Mode And Get Results. NOTE: CDS_FULLSCREEN Gets Rid Of Start Bar.
if (ChangeDisplaySettings(&dmScreenSettings, CBS_FULLSCREEN )!=DISP_CHANGE_SUCCESSFUL)
/* end code */
/* begin code */
// Try To Set Selected Mode And Get Results. NOTE: CDS_FULLSCREEN Gets Rid Of Start Bar.
if (ChangeDisplaySettings(&dmScreenSettings, CBS_FULLSCREEN )!=DISP_CHANGE_SUCCESSFUL)
/* end code */
In the current distrubution of Dev-C++, CDS_FULLSCREEN is undefined. You need to define it yourself, so at the top of your source type this:
#define CDS_FULLSCREEN 4
Then recompile, the code should work fine.
#define CDS_FULLSCREEN 4
Then recompile, the code should work fine.
"...."
Even better! thanks for yr reply, but i have bad news:
c:\windows\TEMP\ccfLu9fb.o(.text+0x1bb):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x1d9):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x1e1):lesson2.cpp: undefined reference to `glEnd@0''
c:\windows\TEMP\ccfLu9fb.o(.text+0x1f9):lesson2.cpp: undefined reference to `glTranslatef@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x206):lesson2.cpp: undefined reference to `glBegin@4''
c:\windows\TEMP\ccfLu9fb.o(.text+0x224):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x23b):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x259):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x27e):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x286):lesson2.cpp: undefined reference to `glEnd@0''
c:\windows\TEMP\ccfLu9fb.o(.text+0x3b8):lesson2.cpp: undefined reference to `wglMakeCurrent@8''
c:\windows\TEMP\ccfLu9fb.o(.text+0x3e2):lesson2.cpp: undefined reference to `wglDeleteContext@4''
c:\windows\TEMP\ccfLu9fb.o(.text+0x9b4):lesson2.cpp: undefined reference to `ChoosePixelFormat@8''
c:\windows\TEMP\ccfLu9fb.o(.text+0x9f8):lesson2.cpp: undefined reference to `SetPixelFormat@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0xa2e):lesson2.cpp: undefined reference to `wglCreateContext@4''
c:\windows\TEMP\ccfLu9fb.o(.text+0xa74):lesson2.cpp: undefined reference to `wglMakeCurrent@8''
c:\windows\TEMP\ccfLu9fb.o(.text+0xdba):lesson2.cpp: undefined reference to `SwapBuffers@4''
c:\windows\TEMP\ccfLu9fb.o(.text+0x1bb):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x1d9):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x1e1):lesson2.cpp: undefined reference to `glEnd@0''
c:\windows\TEMP\ccfLu9fb.o(.text+0x1f9):lesson2.cpp: undefined reference to `glTranslatef@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x206):lesson2.cpp: undefined reference to `glBegin@4''
c:\windows\TEMP\ccfLu9fb.o(.text+0x224):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x23b):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x259):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x27e):lesson2.cpp: undefined reference to `glVertex3f@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0x286):lesson2.cpp: undefined reference to `glEnd@0''
c:\windows\TEMP\ccfLu9fb.o(.text+0x3b8):lesson2.cpp: undefined reference to `wglMakeCurrent@8''
c:\windows\TEMP\ccfLu9fb.o(.text+0x3e2):lesson2.cpp: undefined reference to `wglDeleteContext@4''
c:\windows\TEMP\ccfLu9fb.o(.text+0x9b4):lesson2.cpp: undefined reference to `ChoosePixelFormat@8''
c:\windows\TEMP\ccfLu9fb.o(.text+0x9f8):lesson2.cpp: undefined reference to `SetPixelFormat@12''
c:\windows\TEMP\ccfLu9fb.o(.text+0xa2e):lesson2.cpp: undefined reference to `wglCreateContext@4''
c:\windows\TEMP\ccfLu9fb.o(.text+0xa74):lesson2.cpp: undefined reference to `wglMakeCurrent@8''
c:\windows\TEMP\ccfLu9fb.o(.text+0xdba):lesson2.cpp: undefined reference to `SwapBuffers@4''
Make sure all of the OpenGL libs are included in your project. I don''t remember how to do that for Dev C++ (it''s been a while since I used it), but I know there''s a way
.
"Finger to spiritual emptiness underlying everything." -- How a C manual referred to a "pointer to void." --Things People Said
![Resist Windows XP''s Invasive Production Activation Technology!](http://www.crosswinds.net/~druidgames/resist.jpg)
http://www.gdarchive.net/druidgames/
![](tongue.gif)
"Finger to spiritual emptiness underlying everything." -- How a C manual referred to a "pointer to void." --Things People Said
![Resist Windows XP''s Invasive Production Activation Technology!](http://www.crosswinds.net/~druidgames/resist.jpg)
http://www.gdarchive.net/druidgames/
c:\dev-c++\opengl\lesson2.o(.text+0x9b4):lesson2.cpp: undefined reference to `ChoosePixelFormat@8''
c:\dev-c++\opengl\lesson2.o(.text+0x9f8):lesson2.cpp: undefined reference to `SetPixelFormat@12''
c:\dev-c++\opengl\lesson2.o(.text+0xdba):lesson2.cpp: undefined reference to `SwapBuffers@4''
these are the errors after i included all the files in my project. are there any other thingies i should d/l for opengl?
i have gl.h, glaux.h, and glu.h in my includes currently.
c:\dev-c++\opengl\lesson2.o(.text+0x9f8):lesson2.cpp: undefined reference to `SetPixelFormat@12''
c:\dev-c++\opengl\lesson2.o(.text+0xdba):lesson2.cpp: undefined reference to `SwapBuffers@4''
these are the errors after i included all the files in my project. are there any other thingies i should d/l for opengl?
i have gl.h, glaux.h, and glu.h in my includes currently.
March 20, 2001 02:49 PM
They are in the GDI library that you links to if you create a window GUI app or whatever the IDE calls it. From the command line would it be the -mwindows switch.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement