Jump to content

[SOLVED] multi uv mixing


photo

Recommended Posts

This is quite interesting technique:

 

http://udn.epicgames.com/Three/TerrainAdvancedTextures.html#Multi-UV%20Mixing:%20Reducing%20tiling%20through%20scalar%20mixing

 

In some cases it can save one texture slot, because exactly this I am doing by using same texture 2x with different tiling value. If I remember well, even in valley demo is grass used 2x with different tiling to eliminate tiling efect. It can be good idea to add this as check box option to terrain material.

Link to comment

That would increase the number of shaders considerably (while a terrain is already complex enough, and to think of combinatorial explosion). In it's turn it will result in a longer loading time. So it's less painful to simply assign two textures, if necessary.

Link to comment

On the other side 4 texture limit is causing lots of problems. For any terrain I typically need 2 textures for rock and 2 for grass to prevent tiling and achieve reasonable result.

If I need to add sand, beach, road, etc I have big problem. And 256*256 size of chunk is still quite big area (the smaller chunk, the less textures I need in average). And I am not quite sure, if decals are proper solution.

 

Can you give us some advice, how to approach this situation? Thanks.

Link to comment

Decals are performance killers if used at larger scales (size, count) and might also introduce z-fighting problems for larger distances (when terrain morphing kicks in). The limit of 4 textures is per terrain surface tile, so on the total terrain more textures can be used in theorie (nevertheless in practice this is hardly usable).

 

There were already a lot of forum requests for solving this 4-textures-per surface limit at least for DirectX 10+ based on texture array functionality, but due to missing support of texture arrays on low-end platforms (e.g. DirectX 9, mobile platforms) UNIGINE rejected this idea.

Link to comment

 

There were already a lot of forum requests for solving this 4-textures-per surface limit at least for DirectX 10+ based on texture array functionality, but due to missing support of texture arrays on low-end platforms (e.g. DirectX 9, mobile platforms) UNIGINE rejected this idea.

 

There are other techniques, how to achieve 4+ textures on DX9. You can double the number of splat textures (so you can have 8 textures) and do rendering in 2 pass. It costs some performance, but it would solve problems with tiles, where you need more textures. There are even other ways, how to store texture information (use vertex color...) and still be DX9 compatible.

 

Generally this is about strategy. Engine can support very well few high end platforms, or low-end/mobile, or do both in mediocre way. As I already wrote some time ago, by deciding to support every calculator and ancient DX, Unity3D has now in HUGE troubles with stability and growth. Their customers are mostly kids and fanboys, no sane gamestudio will make any development there. No matter how hard they try to present them as AAA engine, you cant achieve 2012 level of quality wihout rewriting half of engine and you will still suffer from stability issues.

It is not possible to satisfy all customers and if you try it, quality of your product is going down or in best case you have big problem to implement new technologies and approaches.

Link to comment
  • 3 weeks later...

  • 2 rendering passes for terrain is not an option, I'm afraid. Clever blending of detail materials (mixing of diffuse colors and normals with mask normalization) can only be done in 1 pass.
  • Another variant such as using an atlas destroys assets compatibility across all renderers. It is not supported on mobiles, PS3 and DirectX 9.

So we are sticking to 4 detail materials, so far it's the best option.

Link to comment
×
×
  • Create New...