Terrain Texture Blending Screenshot
The way I textured my terrain was that I created 2 vertex buffers. The first vertex buffer is for my base texture. The vertex color for that always has an alpha value of 1.0. My second vertex buffer contains the same information as the first vertex buffer except that the alpha information for the vertex is taken from a bitmap file that shows were the texture should be shown and how transparent it is. I do that as follows:
pVertTB->color=D3DXCOLOR(shade,shade,shade,float(alphamap.buffer[counts*3])/256.0f);
Then I render the base vertex buffer and then the second vertex buffer switching textures.
It seems to be running at the same speed even though it''s rendering each triangle twice. I''m a newbie as this is my first time doing a terrain engine. Does anyone have a method that may be more effective then my method and may look better? I have a feeling as though my terrain has some skin disease like Micheal Jackson. Any way... comments, critism, or ways to do the blending better would be appreciated.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement