|
|
Multitex Terrain + Normalmapping
#361297
03/02/11 11:59
03/02/11 11:59
|
Joined: Apr 2005
Posts: 4,506 Germany
fogman
OP
Expert
|
OP
Expert
Joined: Apr 2005
Posts: 4,506
Germany
|
HeelX was so kind to do some shaderwork for me. I want to spend this shader as open source to the community. Something like this has been requested many times. Download source & example, only 1,3 MB: http://www.vulkanware.de/stuff/Terrainshader.zip-Three textures + Lightmap -Up to three lights (sun + two dynlights) -Fog is supported -Colormask compatible to mtl_terraintex3 -Every texture got their own normalmap -Works for models and terrain -Use it for noncommercial or commercial projects, no credits required. Just don´t claim that you´ve written it and don´t sell it directly. You are free to include it as asset in a project. If you´ve any doubts, ask HeelX directly. He is the author. I´ve got only the rights to use and spread it.
no science involved
|
|
|
Re: Multitex Terrain + Normalmapping
[Re: fogman]
#361475
03/03/11 03:01
03/03/11 03:01
|
Joined: Mar 2009
Posts: 146 USA
paracharlie
Member
|
Member
Joined: Mar 2009
Posts: 146
USA
|
I have been looking for something like this for a long time. Thank you, thank you...
A8 Commercial
|
|
|
Re: Multitex Terrain Normalmapping
[Re: paracharlie]
#361479
03/03/11 05:54
03/03/11 05:54
|
Joined: Jan 2011
Posts: 122 GUILIN , CHINA
tzw
Member
|
Member
Joined: Jan 2011
Posts: 122
GUILIN , CHINA
|
thx it's very useful to my game.
Full of my eyes are class struggles.....
|
|
|
Re: Multitex Terrain Normalmapping
[Re: xxxxxxx]
#361547
03/03/11 19:20
03/03/11 19:20
|
Joined: Aug 2007
Posts: 1,922 Schweiz
Widi
Serious User
|
Serious User
Joined: Aug 2007
Posts: 1,922
Schweiz
|
@7x: Du findest im Ordner "earth2" eine Bilddatei mit dem Namen "earth2_mask.dds". Die kannst du mit einem Mahlprogramm (z.B Paint.Net) öffnen. Nun siehst du so eine farbige Fläche. Diese Farben (r,g,b) werden nun vom Shader ausgewertet. Es gibt 3 Detailmaps in diesem Shader: earth2_grass, earth2_rock und earth2_sand. Diese werden nun gekachelt und abhängig von der Blendmask "earth2_mask.dds" auf das Terrain aufgetragen. Blau = grass, Grün = sand und Rot = rock. Je stärker eine Farbe ist, desto besser ist die jeweilige Detailmap sichtbar.
Wieso wird das so gemacht? Wenn man eine normale Skin auf ein Terrain setzen wollte, müsste diese Skin riesig sein, um einigermassen gut auszusehen. Bei einer normalen Skin würde ein Pixel im Game schnell mal 1 * 1 cm gross sein und dementsprechend schlecht wäre die Auflösung des Terrains. Deshalb arbeitet man mit Blendmask, über die eine viel höher aufgelöste Detailmap gekachelt auf das Terrain aufgetragen wird.
Male mal mit rot,grün und blau auf der "earth2_mask.dds" herum, dann siest du die Aenderungen.
|
|
|
Re: Multitex Terrain Normalmapping
[Re: Widi]
#361550
03/03/11 19:36
03/03/11 19:36
|
Joined: Jan 2011
Posts: 797 Da wo du nicht bist! Muhahaha!
xxxxxxx
User
|
User
Joined: Jan 2011
Posts: 797
Da wo du nicht bist! Muhahaha!
|
Danke Widi, ich hatte nur nicht verstanden welche farbe für was zuständig ist, aber jetzt ist alles klar  Also wenn ich das jetzt richtig verstehe hat der unterstützt dieser shader nur 3 texturen + normalmap! ich brauche leider 5-8 texturen( + normalmap)  gibt es da noch was anderes an multiterrain shadern(außer den standart 3dgs shader meine irgend gehört zu haben das der (zu) langsam sei oder sowas) oder kann man den shader erweitern? xxxxxxx
Es ist immer wieder erstaunlich, dass Leute die riesen Scripte schreiben die einfachsten sachen nicht können zb. mich mit SIEBEN x zu schreiben!
|
|
|
Re: Multitex Terrain Normalmapping
[Re: xxxxxxx]
#361558
03/03/11 20:01
03/03/11 20:01
|
Joined: Jul 2001
Posts: 6,904
HeelX
Senior Expert
|
Senior Expert
Joined: Jul 2001
Posts: 6,904
|
You can access through material- and entity skins a total of 8 textures. Using one texture as mask this means that you have access to a total of 7 texture á 4 channels => 28 monochrome texture maps which can be divided into 5 pairs of RGB textures and 5 XY normal maps (for texture, the z-component can be restored easily through arithmetics). This means, assuming you use it on terrains and / or entities, you can have a multitexture normalmapping shader with 5 texture + normalmaps max!
Since you have access to static bitmaps and if you are only using ONE terrain at a time with this shader, you can, though, use unlimited texture/normalmaps, of course, if you use then static bitmap references.
Nevertheless, there more texture/normalmaps you use, the longer calculations are to be taken into account. Are you sure that you need 5-8 textures? Can't you break your environment into pieces and use textures only where they belong?
|
|
|
Re: Multitex Terrain Normalmapping
[Re: HeelX]
#361567
03/03/11 20:26
03/03/11 20:26
|
Joined: Jan 2011
Posts: 797 Da wo du nicht bist! Muhahaha!
xxxxxxx
User
|
User
Joined: Jan 2011
Posts: 797
Da wo du nicht bist! Muhahaha!
|
The problem is: i have villige! the streets must shoult look like this:  and their will be gardens, forest and rivers too so i need much textures! im so sorry for my englich! HeelX i'm not able to write shaders but i think i understand what you mean i'll try tomorrow to split my terrains into parts(street and landscape)! xxxxxxx
Es ist immer wieder erstaunlich, dass Leute die riesen Scripte schreiben die einfachsten sachen nicht können zb. mich mit SIEBEN x zu schreiben!
|
|
|
|