Jump to content

[TUT] Mipmap fix


clara3ME

Recommended Posts

Hi there, this tutorial is about fixing the textures with alpha map like grass or leaves from getting darker with growing distance.

The problem is that dark colors that are usually masked by the alpha start bleeding in the visible parts of the texture.

That might be hard to understand but i guess the images speak for them self.

 

 

This is how we like our texture:

RtmjW39.png

 

But with the distance the engine will fade over to a lower resolouted image:

bVji4rM.png

 

You can see how dark pixels have appeared on the outer edge of the grass. That is causing the problem and yes this is not a custom texture these are from Bethesda.

So how are we going to fix this?

 

First we load up the texture in gimp

0lKWpJk.png

 

This is how the texture looks without alpha

TbhP8Rw.png

 

we want the invisible part to have a color that is as close as possible to the visible part.

So we copy the layer and apply some blur to the lower layer.

P60V5ql.png

 

Then we select only the opacity layer

v4t1JbS.png

(sorry for the german, I'm sure you'll find it anyway)

 

And then we fill the whole layer, the color does not matter, since we only fill the alpha

yjBdQ0B.png

 

Then we create a selection from the top (original) layer alpha

G7dLKuR.png

 

We merge the two layers and create a layer mask from the selection

VLqf0j4.png

 

(continued in comments)

Link to comment
Share on other sites

Then we apply the mask and everything looks like it did when we started, but its not.

If you create a selection from the green channel it should look like this

68xN4aV.png

 

so the color channels are different. And if you save your texture and generate mipmaps you should find something like this

pvkFBk0.png

 

a way better looking mipmap with the same colors as the higher resoluted image.

 

sorry for the ammount of immages, but i thought the more images the better to understand.

Edited by clara3ME
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...