OpenGL Multitexturing Details w/Alpha

Post: #16
Again, thanks for all the help. I hope I can repay it one day somehow either to this community or to you =-).

Thanks a million - you made my day... err no - month =-D
Quote this message in a reply
Post: #17
Seems I spoke too soon -

The base isn't drawing where the details aren't.

Meaning the base is also using the details alpha.

If you need a screen of this i can p rovide one
Quote this message in a reply
Post: #18
Err wait - I'm going to try a forth pass, interpolate of colormap and colormap in respect to alpha
Quote this message in a reply
Post: #19
                    glActiveTextureARB( GL_TEXTURE2_ARB );//detail - instead of pass through, interpol with tex0 in respect to 1-alpha
                     /*glTexEnvi (GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_COMBINE);
                      glTexEnvi (GL_TEXTURE_ENV, GL_COMBINE_RGB_EXT, GL_REPLACE);
                      glTexEnvi (GL_TEXTURE_ENV, GL_SOURCE0_RGB_ARB, GL_PREVIOUS);*/
                     glTexEnvi(GL_TEXTURE_ENV,GL_SOURCE0_RGB_ARB, GL_PREVIOUS );
                     glTexEnvi(GL_TEXTURE_ENV,GL_SOURCE1_RGB_ARB, GL_TEXTURE0  );
                     glTexEnvi(GL_TEXTURE_ENV,GL_SOURCE2_RGB_ARB, GL_TEXTURE1);
That should work right? (replacing the old tu2)
Quote this message in a reply
Post: #20
makes it visible now, but the details are MUCH too light ( I switched to a GL_MODULATE for the details since its the actualy effect I want, not GL_ADD_SIGNED)
Quote this message in a reply
Posts: 1,234
Joined: 2002.10
Post: #21
You don't need to enable blending for multitexturing, unless you intend for the final combined texture to be translucent (usually not, for terrain.)
Quote this message in a reply
Post: #22
Hmm, well see, since I'm using multiple textures, and the DOT3 hack wont work for me, I have to make like 3-4 passes. I can't figure out how to do this otherwise since in my TU1 I need to references the previous and previous only grabs the previous tu
Quote this message in a reply
Post: #23
I ended going up with this as it was "close enough". The tool is for Myth III: The Wolf Age. Here are the results of the multitexturing on one of the standard maps:

Before: Pepper Heights
After: Pepper Heights
After: Pepper Heights Close up
After: Llanc Close Up Road

Its still not quite right (It actually brightens when there is white instead of darkens... hmm...) but I think it will work for its purpose (which is seeing how things look in a rough fashion without switching to the engine every 5 minutes).
Quote this message in a reply
Post Reply 

Possibly Related Threads...
Thread: Author Replies: Views: Last Post
  OpenGL Alpha Channel Problem Moganza 1 5,781 Jan 19, 2013 08:25 AM
Last Post: sealfin
  OpenGL ES 2.0, 2D Alpha Transparency Artifacts Macmenace 3 11,126 Mar 28, 2010 11:18 PM
Last Post: AnotherJake
  Can't get multitexturing to work Coyote 4 6,250 Nov 16, 2009 11:48 PM
Last Post: arekkusu
  Opengl alpha premultiplication issue Najdorf 5 8,091 Nov 13, 2008 09:49 AM
Last Post: Najdorf
  Loading and using textures with alpha in OpenGL with Cocoa corporatenewt 4 9,491 Dec 8, 2007 02:06 PM
Last Post: Malarkey