Texture splatting

Sorry for the long delay between posts, but I’ve been busy on other fronts, and needed to learn how to do this before posting about it. 🙂 I want to add some color and texture to my terrain. So I’ve starting investigating texture splatting. This will allow me to generate one texture for each tile from several others, so I can have rock texture on steep parts and grass texture on flat areas. I’ve created a small test program to teach myself, and after fighting quite a bit with pixel color data and SDL pixel formats, I’ve finally managed to blend two textures together.

Original textures

Original textures

I found these textures at CG Textures, and managed to mangle them into this:

Mossy rock

Mossy rock

Sort of looks like mossy rock? Maby? Well, anyway…this is a 50/50 mix. I need to work on this to allow me to have different blending values, and then create a method to make these blending maps automatically.

More on that when I have something to show 🙂

-Knut

Advertisements

Tags: , ,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s


%d bloggers like this: