OpenGL 1.2 ???
Where do i find OpenGL 1.2? I looked at www.opengl.org in the
download section but i could not find it. Could anyone tell
where i find it?
Does anyone use the search feature? OpenGL 1.2+ is NOT supported under Windows. HOWEVER your video card manufacturer can support it in their drivers. HOWEVER since Windows doesn''t support it you have to use extensions to get the 1.2+ functions.
[Resist Windows XP''s Invasive Production Activation Technology!]
[Resist Windows XP''s Invasive Production Activation Technology!]
Actually, i did use the search feature, and it didnt find
anything. Anyway , my problem is this:
I want to use the wglSwapIntervalEXT() function to turn off vsync
so i can test the TRUE fps of my app. To do this i was told
that i should go to opengl.org and get a file named "wglext.h"
which had the wglSwapIntervalEXT() function. So i got the file,
included it in my source file and called the function.
When i tryed to compile i got and "unresolved external symbol"
error message. So i thought that maybe i need a newer version of
opengl beacuse i only have 1.1.
So any hint on what i should do about this would be helpful.
anything. Anyway , my problem is this:
I want to use the wglSwapIntervalEXT() function to turn off vsync
so i can test the TRUE fps of my app. To do this i was told
that i should go to opengl.org and get a file named "wglext.h"
which had the wglSwapIntervalEXT() function. So i got the file,
included it in my source file and called the function.
When i tryed to compile i got and "unresolved external symbol"
error message. So i thought that maybe i need a newer version of
opengl beacuse i only have 1.1.
So any hint on what i should do about this would be helpful.
Ok, this question is kind of unique then . You pass the name of the function you want to wglGetProcAddress, and store the return value in a function pointer (look in the wglext.h header, I forget what the name of the typedef is). Then you call that function pointer as if it were wglSwapIntervalEXT (because it basically is).
[Resist Windows XP''s Invasive Production Activation Technology!]
[Resist Windows XP''s Invasive Production Activation Technology!]
Ok, in wglext.h the following is defined:
extern BOOL WINAPI wglSwapIntervalEXT (int);
typedef BOOL (WINAPI * PFNWGLSWAPINTERVALEXTPROC) (int interval);
And in my program i did this:
wglSwapIntervalEXT = (PFNWGLSWAPINTERVALEXTPROC)
wglGetProcAddress("wglSwapIntervalEXT");
When i compiled this i got this message:
error C2659: ''='' : overloaded function as left operand
What am i doing wrong?
NOTE:
I have declared my own function pointer, i just used the existing
one. Is that wrong?
extern BOOL WINAPI wglSwapIntervalEXT (int);
typedef BOOL (WINAPI * PFNWGLSWAPINTERVALEXTPROC) (int interval);
And in my program i did this:
wglSwapIntervalEXT = (PFNWGLSWAPINTERVALEXTPROC)
wglGetProcAddress("wglSwapIntervalEXT");
When i compiled this i got this message:
error C2659: ''='' : overloaded function as left operand
What am i doing wrong?
NOTE:
I have declared my own function pointer, i just used the existing
one. Is that wrong?
I think it goes:
I''m not looking at a reference or anything, but I still think that''s correct.
[Resist Windows XP''s Invasive Production Activation Technology!]
PFNWGLSWAPINTERVALEXTPROC wglSwapIntervalEXT = (PFNWGLSWAPINTERVALEXTPROC) wglGetProcAddress("wglSwapIntervalEXT");
I''m not looking at a reference or anything, but I still think that''s correct.
[Resist Windows XP''s Invasive Production Activation Technology!]
Yep Null and Void you are correct
The Joke, the problem with your code is that you declare wglSwapIntervalEXT as an extern function, so the linker searches for it in the .obj it is linking (static linking)
Opengl uses a dynamic link schema, this means that at compile time you do not know where is the function, the exact adress will be given at runtime.
Perhaps i''m not very clear, but this is the spirit of it
The Joke, the problem with your code is that you declare wglSwapIntervalEXT as an extern function, so the linker searches for it in the .obj it is linking (static linking)
Opengl uses a dynamic link schema, this means that at compile time you do not know where is the function, the exact adress will be given at runtime.
Perhaps i''m not very clear, but this is the spirit of it
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement