Developer forums (C::B DEVELOPMENT STRICTLY!) > Development

New project wizard (OpenGL)

(1/2) > >>

sethjackson:
Hello. I have created a OpenGL project wizard (Windows only for the moment).



[attachment deleted by admin]

sethjackson:
Well no replies, and yet is has been downloaded four times????  :( Is it the wizard.png that is hindering it?

Vampyre_Dark:
I figured since it was only in 'for developers' that it would be to include in the default wizards, and not for downloaidng and usage. I haven't even toucghed the new project things, I usually make everything from scratch. I'll check it out now then...

--edit--

Looks good. What's the point of calling DestroyWindow() explicitly, expecially after the message loop is over?

sethjackson:

--- Quote from: Vampyre_Dark on August 12, 2006, 05:13:45 am ---I figured since it was only in 'for developers' that it would be to include in the default wizards, and not for downloaidng and usage. I haven't even toucghed the new project things, I usually make everything from scratch. I'll check it out now then...

--edit--

Looks good. What's the point of calling DestroyWindow() explicitly, expecially after the message loop is over?

--- End quote ---

To be honest I don't know I never do that (Well I destroy the window in the WM_CLOSE message) but it seems that most of the Windows OpenGL tutorials do..... What I do (when using the Windows API): in the WM_CREATE message enable OpenGL; in the WM_CLOSE message disable OpenGL, and destroy the window; and in the WM_CLOSE message PostQuitMessage(0).

It always worked for me, however for the wizard I just copied the code from the OpenGL file based template (I'll admit I modified it a bit, but not much)......

Vampyre_Dark:
Heh. Well it sends a WM_DESTROY message, nothing more. That part of your code doesn't even run until the window is already nuked, and the message processing loop is done. It's a redundant call. Not nitpicking, I was just curious.

What is the different between these wizards and just using a file based template? It seems it just copies the main.cpp into the proper folder?

Navigation

[0] Message Index

[#] Next page

Go to full version