Jump to content

[Material] Lot of useful material functions


Henk

Recommended Posts

DOWNLOAD: https://www.dropbox.com/s/ir6oruzyzhljrfj/Renegade X Landscape Material.zip?dl=0

Download contains a package with some textures, and the map file, please note that this map can not be played, it's just there to showcase the materials and so you can see how I've applied it.

This landscape material combines a lot of techniques used in existing maps, and I've also added some things of my own.

It would've come in very useful for me if I had this when I started making maps. So that's why I'm sharing it here now.

One problem when making a landscape material is the fact you can only have 4 different layers, when you would make a very basic material you would only have 4 different textures, this material enables you to have a lot of variation on your landscape.

I'm using blending techniques based on:

  • Distance
  • Height
  • Vector (direction)
  • Texture Sampling

I've used a lot of comments to make clear what everything does.

You can expand on this yourself by adding more color variations, using different textures, adding normal maps for all layers, and adding distance blend to all of the layers.

 

Here's some preview screenshots:

MLQ0To6.jpg

You can create color variations based on the height of the landscape, very useful when you want to make a canyon for instance. There's 4 different, subtle, colours now but you can go crazy with it and create a rainbow cliff if you'd like.

XJtk0EO.jpg

This layer uses a texture to blend between 2 color variations. this way it looks less repetitive. You can also blend between 2 different textures so you could for instance have grass with patches of snow or sand.

C4x8OIh.jpg

This way you don't have to handpaint your cliffs anymore, and it saves you a layer.

QingItW.png

When the landscape is above X height, the rocks become covered in snow, used in combination with the vector based blending. Useful for mountian tops.

 

The nodes:

f5luM2z.png

Should be clear enough to follow.

  • Like 2
Link to comment
Share on other sites

Nice. I'll add this to the new SDK build if you're allright with that. What you're saying regarding the 4 layers.. it's not entirely true. The limitation is in the amount of textures we're applying in a material. You can only have 7 unique textures before it freaks out (been there done that). However, if you're smart you can combine those textures to have a completely new look for a new layer. You could also add a color multiplier to it, use masks and what not. If you just keep sticking to those 7 textures.

Link to comment
Share on other sites

On ‎28‎/‎09‎/‎2016 at 6:16 PM, Ruud033 said:

Nice. I'll add this to the new SDK build if you're allright with that. What you're saying regarding the 4 layers.. it's not entirely true. The limitation is in the amount of textures we're applying in a material. You can only have 7 unique textures before it freaks out (been there done that). However, if you're smart you can combine those textures to have a completely new look for a new layer. You could also add a color multiplier to it, use masks and what not. If you just keep sticking to those 7 textures.

I thought the limiit was 12 textures... ?!

edit: but I agree, you can do a lot with only a few textures ;)

Edited by j0g32
Link to comment
Share on other sites

Oh wow, I can't add more than 4 when I use the Layer Blend node? But Lakeside has 9 layers without problems, how? I also read on the internet that 4 was the max but I guess it's not. Learning new things every day :P

 

And yeah the color variations come in handy because you only need one texture. One thing I also find annoying is that you need to use up 2 of your texture spots, if you want to use the same texture but with different UV coordinates, like in the distance blend.

Link to comment
Share on other sites

21 hours ago, Henk said:

Too bad we can't multiply texture coordinates because that would be awesome. There's a Panner, a Rotator, wish there was a scaler.

Quote

And yeah the color variations come in handy because you only need one texture. One thing I also find annoying is that you need to use up 2 of your texture spots, if you want to use the same texture but with different UV coordinates, like in the distance blend.

Quite sure that this should be possible ;)
In my Landscape Material, I usually employed the same texture for close-up Detail and distance based LowDetail (with higher scaling and lower contrast). You take the Terrain Coordinates and divide them by your scaling factor.
In addition I used a colormap to for variation, and obviously a normal map.
You can also use e.g. the red channel of your diffuse texture for a specular input, and the blue channel of your normal map for height blending of layers.

This gives 3 texture inputs per layer, and I was using 4 Layers in total: generic soil, grass, rock, snow.
See the screenshot below (dunno why it says 5/12 texture samplers). Maybe you have to convert the texture samplers into "parameters", which means that 2 samplers can refer to the same parameter, i.e. the texture that is loaded in this sampler will be the same for both, whereas two simple texture samplers don't restrict you to chose the same texture for both... Maybe that's way ;)

 

TerrainMaterial_example.PNG

Edited by j0g32
  • Like 1
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...