views:

380

answers:

0

I have a texture from this PNG:

alt text

And another from this PNG:

alt text

They both have the same blend function:

glBlendFunc(GL_ONE, GL_ONE_MINUS_SRC_ALPHA);

I want to see them on one single polygon first. I just couldn't find a simple example of this. Draw them to different polygons works perfect, but I just cannot "merge" them into one texture. Any working sample codelines would be appriciated well.

Second problem is to make the specular map's alpha variable. I can see that I have to texture combine somehow it's alpha with the primary color (created from my variable), but again, have no working example of codes. I began to study glTexEnvi function, but yet I have no any result.

Please, I beg you for just about 16 lines of code! I googled the whole net, but still stuck.

The engine I want to implement (working flash sketch on the bottom of the post): http://gotoandplay.freeblog.hu/archives/2010/01/07/compactTangram_072_-_tan_rendering_labs/