[GEM-dev] Re: [GEM-cvs] Gem/src/Base GemMan.cpp,1.36,1.37

IOhannes m zmoelnig zmoelnig at iem.at
Wed Mar 9 14:55:31 CET 2005


Jamie Tittle wrote:
> Update of /cvsroot/pd-gem/Gem/src/Base
> In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv16801
> 
> Modified Files:
> 	GemMan.cpp 
> Log Message:

> IOhannes: the gl headers and such are in GemMan.h:  
> why would you want to put them in GemMan.cpp?

because they were already there ?

the only real change i made was the use of
"#if !defined DONT_INCLUDE_GLEXT && !defined __APPLE__"
instead of
"#ifdef INCLUDE_GLEXT"

(really! i have also changed the indentation of the other 
preprocessor-directives a bit. that's why the diff was so big)


> I'm a big fan of including headers in, um, the header :-)  

well, i think this might be discussable (although i don't have a 
theoretical background in such things):
1. i think it is good style to include header-files that are only needed 
to make the "body" (this is: .c/.cpp) compilable in the body instead of 
the header.
in the header only those files should be present that make the header 
"compilable".
e.g is i use GL_RGBA in my header, then i have to include gl.h; if no 
reference to any gl-related thing can be found in the header, why 
include it ?

2. sometimes it is good to include "some" .h-files in the header because 
they are needed by all body-files that include the header (even though 
the header-file itself does not depend on the includes)

that having said, i admit that i don't want to flame about where to 
include header files.
i have just put them into GemMan.cpp because all related headers where 
already there (or probably i myself didn't put them there at all, but 
they had been there since ever)

i really just had encountered a bug within GemPixUtil.h due to using 
INCLUDE_GLEXT instead of DONT_... and then i grepped all occurences of 
INCLUDE_GLEXT and replaced them.


Btw, the "GL/ vs. OpenGL/" thing is due to apple's use of framework's...
> 
yes i know this. that's why i have put in the "nevermind".
it just makes things unnecessarily complicated (but that is what live is 
anyhow)


keep rocking

mfg.ads.r
IOhannes




More information about the GEM-dev mailing list