a minor multitexturing problem

Hi all,

I just added multitexturing to my terrain engine. I’m new to multitexturing, so I was
a bit surprised by one side-effect that the multitexturing caused: I get weird coloring
on the terrain after I apply the detail texture to it.

Here’s an example: http://saez1.tripod.com/mtex.jpg

This is how the textures are applied:

// base texture
glActiveTextureARB(GL_TEXTURE0_ARB);
glEnable(GL_TEXTURE_2D);
glBindTexture(GL_TEXTURE_2D, baseTexture[0]);

// detail texture
glActiveTextureARB(GL_TEXTURE1_ARB);
glEnable(GL_TEXTURE_2D);
glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_COMBINE_EXT);
glTexEnvi(GL_TEXTURE_ENV, GL_RGB_SCALE_EXT, 2);
glBindTexture(GL_TEXTURE_2D, detailTexture[0]);

glMatrixMode(GL_TEXTURE);
    glLoadIdentity();
    glScalef((float)detailscale, (float)detailscale, 1);
glMatrixMode(GL_MODELVIEW);

The basetexture is just lightbrown sand, but the multitexturing
(detail texture is just a grayscale bitmap) adds red’ish spots on the terrain as you can
see from the screenshot. Why is that? How can I remove the unwanted side-effect?

Thank you.

saeZ

Without more information, I would way they are part of the texture.