OpenGL Window Framework Beta [Updated - Beta 1.0.2]

Started by
33 comments, last by _the_phantom_ 19 years, 2 months ago
[[ Beta 1.0.2 is out, see here for upto date details. ]] Some of you, depending on how much attension you pay, might have noticed me waffling about a 'windowing framework' or even seen it in my sig. Well, after 2 days of writing an API guide and making sure the examples compiled and worked properly (including the knocking off of a couple of last moment bugs) I'm finally happy enuff to release it into the world [grin] So, why here and why not the Announcements forum I hear you ask? (yes, thats you mr mod *waves*) Well, frankly, its had somewhat 'limited' testing, and I could really do with other poking it and testing it on other hardware. Now, I dont invisage and problem (famous last words) but if some of you could see your way clear to giving it a go I'd appricate it. Currently it only support Win32/VS.Net03, I've got plans to port it to linux/X-win soon and would like an OSX port done. Also I do plan on improving win32 compiler support as well (as I know a fair amount use the free compiler, whos name has escaped me right now, heh). The project can be found here, with the address staying in my sig as well. With that in mind I've also uploaded all four tests, precompiled for win32 to here for others to test if they so wish. As always, feedback etc is welcome. Edit: See this post for the latest details, downloads can be found at the sourceforge page as before. [Edited by - _the_phantom_ on January 9, 2005 5:51:37 PM]
Advertisement
Is it DevC++? MinGW Developer Studio?...
I suggest you at least support the MinGW compiler (SDL supports VC 6 and MinGW)
Your WindowMgr CreateWin member function ignores the return value of the Window InitOpenGL member function, which makes it possible to request an OpenGL capable window and get back a non-OpenGL capable window. This can be made to occur by failing to specify the OpenGL settings*:
int main(){	using namespace OpenGLWFW;	WindowManager windowManager;	windowManager.Init();	if(!windowManager.FindCompatibleDisplayMode(800,600))		return -4;	winHnd windowHandle = windowManager.CreateWin(winprops::initogl);	// windowHandle is now a handle to a non OpenGL-capable window}


*The actual OpenGL settings requested in this case are undefined, usually this means they are invalid but this is not guaranteed.

EDIT: Nearly forgot. Your Window class defines a destructor that is not declared, resulting in a "Body has already been defined for function" error under BCC. You also use standard exception classes without #includeing <stdexcept>.

Enigma
@Enigma:
ah, thanks for pointing them out.

Didnt accure to me about the exceptions stuff, VS.Net seems to let it go with no problems, I'll get that fixed.
Not sure how the lack of destructor got past either, VS.Net again didnt complain and it worked how i wanted it to, still thats what these releases are for, to get people to spot issues [smile]

Anyway I never thought about using the API that way, heh
The thing is, I'm not completely sure what todo about it, technicaly its fine as you can go back at a later date, give the window manager a valid OpenGL mode and request the window is initalised.
Your right about the lack of checking the return value as well, false technically shouldnt be able to happen, so I guess an exception of some sort might be the way to head there.
To be honest, now I go back to look at that function I'm not 100% comvinced its as exception safe as I'd like it to be.

If you've any suguestion on how to go with the issue you brought up then I'm all ears [smile]
BCC is a Borland compiler, right?

@LordMyth;
Yeah MinGW was the one I was thinking about, i'll probably get that installed later today and see about setting the project up for that as well.
I'm not too fussed about VC6.0 right now, however I dont see any reason why it couldnt be made to build on it, I'm pretty sure I'm not doing anything VC6 will choke over.
ack, the above AP was me, foolish forums *cries*
It looks good.

Tell me about these tests. Should they draw something ? Or just disaapear as they did.

Also where can I find the code , that uses this wrapper , I couldn't find any , maybe I am just blind or something :)
aye, they should draw a spinning cube in the window until they close.

What gfx card/driver/OS do you have?

As for the code, I was tired last night so while I updated my sig to reflect the new location I forgot that some people have sigs turned off etc
The project can be found here, link to a download page on the left (all downloads from sourceforge)
Nope I didn't saw anything the windows just opened and closed. I have worked with OpenGl , and working right now, so it seems a bit strange.
Here are my system specs:

Windows XP SP2

Celeron 1.2 Ghz
RADEON 9000
256 MB RAM

Driver version :

6.14.10.6476 25.08.2004

About the examples , I couldn't run them. I included the link to libraries and header files. But once I try to build the application I receive the following error...

Quote:
c:\my downloads\projects\oglwfw-lib-1.0\include\oglwfw\windowmgr.hpp(16) : fatal error C1083: Cannot open include file: 'boost/shared_ptr.hpp': No such file or directory


Maybe I am missing something. I am using Visual Studio 6.

[Edited by - DMINATOR on January 5, 2005 12:28:53 PM]
Excelent work! I will give it out a try tonight and get back to you when I'm done [smile].
@Drew_Benton:
cheers, I'd hold off on it a bit however, due to tiredness a rather large bug managed to sneak past with buffer swapping, I've squished it but having downloaded Dev-C++ earlier I'll be putting new packages up later tonight with all the fixes and hopefully a Dev-C++ build enviroment as well [smile]

@DMINATOR:
You'll need the boost::thread libraries installed (with the headers and libs in the compilers path) to compile the multithreaded stuff.
Boost isnt the only way todo multi-thread, but its what I'm used to and cross platform.

This topic is closed to new replies.

Advertisement