james tittle wrote:
On Jun 8, 2006, at 2:48 PM, IOhannes m zmoelnig wrote:
i agree that it might be better to just have one big #ifdef _APPLE__ #endif instead of 4 of them would you change it or should i do it? (and honestly, i much prefer an #ifdef over an #ifndef for readability)
...either way, I think that one problem with setCSizeByFormat() is that it tries to also set type & format (ie. on macppc we want "GL_BGRA" instead of "GL_RGBA", yet we want to be lazy and not add an #ifdef to all instances of "setCSizeByFormat(GL_RGBA) in GEM...guess this means we need a little rewrite for macintel, too), but only returns "csize"...
actually i quite like the way it is done right now: require an rgba format and get what the system thinks is the best match for rgba. however, it might be better if we would use our own defines like: GEM_RGBA (which is GL_RGBA or GL_ARGB or whatever)
i also like that setCSizeByFormat() sets the csize and the format (after all, that is the idea of the function). the return value (csize) is just for convenience: if you need to know the format and the csize, they should be queried explicitely via imageStruct.csize and imageStruct.format
mfg.asdr IOhannes