Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Professional Discussion / texture blending?

Author
Message
Link102
21
Years of Service
User Offline
Joined: 1st Dec 2004
Location: On your head, weeeeee!
Posted: 7th Jun 2010 20:03 Edited at: 7th Jun 2010 20:03

source: http://www.gotow.net/andrew/wordpress/?tag=texture-blending

I'm trying to start a blend mapped terrain engine progect, but I can't get around the numbers.

Lets say you are using this method. You have a 32 * 32 matrix and each tile is 1 texture. And say the texture size is 512 * 512 px, that's a texture map of 16384 * 16384 px or 1024 blend maps.

That's a HUGE amount of data. Is there any other, better way of processing/displaying a huge terrain(Perhaps with shaders)? Is there something I'm missing?

Math89
22
Years of Service
User Offline
Joined: 23rd Jan 2004
Location: UK
Posted: 7th Jun 2010 21:22
Each tile isn't one texture, that's what you're missing. That would be true if you were using some kind of preprocessing method, but you don't need to if you use a shader (or a DBPro blending mode) which processes the colour on the fly.
paul5147
20
Years of Service
User Offline
Joined: 11th Jan 2006
Location: Hot & Sunny
Posted: 8th Jun 2010 11:19 Edited at: 8th Jun 2010 13:50
Posted this for somebody else the other day,dont no if its of any use to you but the way i do it is to make all my textures first,blend them together from within dbpro then apply them to the terrain objects just like any other texture,advantagre is it still leaves all the other texture layers to play with.

good luck with your project.
Van B
Moderator
23
Years of Service
User Offline
Joined: 8th Oct 2002
Location: Sunnyvale
Posted: 8th Jun 2010 11:56
Often, people use shaders with multiple textures, or 1 big colour map texture with a detail texture.

The technique I ended up with gives a colour map texture over the whole terrain plus 5 detail textures, like sand, grass, path etc. In fact go look at my youtube video of Tersculpt...

http://www.youtube.com/watch?v=rndPdaTClJ8&feature=PlayList&p=7C141353FB64022A&playnext_from=PL&index=0&playnext=1

With that system, I paint the textures onto the terrain - like you might start with all grass, or all sand, then paint the detail textures on - or analyse the terrain and work out the texturing with code.


Health, Ammo, and bacon and eggs!
Link102
21
Years of Service
User Offline
Joined: 1st Dec 2004
Location: On your head, weeeeee!
Posted: 9th Jun 2010 22:57
Thank you all for your help.

Van B - You used 128 bits per channel?
How big is your color map on a 32*32 matrix?

Login to post a reply

Server time is: 2026-07-25 16:21:14
Your offset time is: 2026-07-25 16:21:14