Re: [Plib-devel] Texture and blend modes
Brought to you by:
sjbaker
From: Sam S. <sa...@sp...> - 2000-08-18 18:58:16
|
----- Original Message ----- From: "Steve Baker" <sjb...@ai...> To: <pli...@li...> Sent: Friday, August 18, 2000 6:38 PM Subject: Re: [Plib-devel] Texture and blend modes > Sam Stickland wrote:-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 - ----- Original Message ----- From: "Steve Baker" <sjb...@ai...> To: <pli...@li...> Sent: Friday, August 18, 2000 6:38 PM Subject: Re: [Plib-devel] Texture and blend modes > Sam Stickland wrote: > > > How are these specified in ssg? I'll take a wild guess that ssg > > doesn't manage texture environment modes (GL_MODULATE, GL_DECAL > > etc.) at all, and it only cares whether blending is on or off. > > Well, when you add a texture into an ssgSimpleState, you can either > pass it an 'ssgTexture' or an OpenGL texture handle - or even a > filename (which will result in an ssgTexture being constructed on > your behalf). Oh wait, I'll look lame for saying this but I genuinely thought that glTexEnv didn't get caught up in the glBindTexture bit? The results from glTexEnv depend on what surface you render onto, not just the texture so I thought it effected the "global" rendering mode - - hence I believed this sort of stuff was planned for: glBindTexture(blah); glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE); /* Render surface */ glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_DECAL); /* Render another surface */ Oh well.. > > 5) Edit the SSG source code to add 'setEnvMode/getEnvMode' methods > to ssgTexture - then > contribute your change via CVS and earn fame, the recognition of > your peers, etc, etc. And Beer? > While you are about it - add Mag/Min filter and texture wrap > options. > > People who know me well soon realise that I ALWAYS put my most > favored option at the end of a list of choices. :-) Guess I'll do this one then. :) Oh, how do you set the glBendFunc ? (Meant to ask this in the original email but forgot). Thanks, Sam -----BEGIN PGP SIGNATURE----- Version: PGPfreeware 6.5.3 for non-commercial use <http://www.pgp.com> iQA/AwUBOZ2G59oVH1DfwTXWEQJ/aQCfR8CBuFXWfx7pYZ/J5Y3rjtdfOpsAoOV5 HpjkfLnKO/vlY+1sx3SXmioi =U5l/ -----END PGP SIGNATURE----- > > > How are these specified in ssg? I'll take a wild guess that ssg > > doesn't manage texture environment modes (GL_MODULATE, GL_DECAL etc.) > > at all, and it only cares whether blending is on or off. > > Well, when you add a texture into an ssgSimpleState, you can either > pass it an 'ssgTexture' or an OpenGL texture handle - or even a > filename (which will result in an ssgTexture being constructed on > your behalf). Oh wait, I'll look lame for saying this but I genuinely thought that glTexEnv didn't get caught up in the glBindTexture bit? The results from glTexEnv depend on what surface you render onto, not just the texture so I thought it effected the "global" rendering mode - hence I believed this sort of stuff was planned for: glBindTexture(blah); glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE); /* Render surface */ glTexEnvf(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_DECAL); /* Render another surface */ Oh well.. > > 5) Edit the SSG source code to add 'setEnvMode/getEnvMode' methods to ssgTexture - then > contribute your change via CVS and earn fame, the recognition of your peers, etc, etc. And Beer? > While you are about it - add Mag/Min filter and texture wrap options. > > People who know me well soon realise that I ALWAYS put my most favored option > at the end of a list of choices. :-) Guess I'll do this one then. :) Oh, how do you set the glBendFunc ? (Meant to ask this in the original email but forgot). Thanks, Sam |