x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Problems with a Custom Terrain Material Using Vertex Color to Blend up to 4 Textures on Mobile

Hello all,

I need help trying to get this material setup to be mobile (android) friendly (if possible).

I am attempting to achieve vertex color blending of up tp 4 textures using heightmaps to define the transition between the different textures, for the terrains I want in my game. I am using the HeightLerp node for this. Besides the color textures, there will be normal textures and just flat values or colors to define the metal, specular, roughness and emission. I am targeting Open GLES 3.1 and above. I have 15 of the 16 allowed texture samplers in use.

I am also attempting to do UV tiling through the Custom UV pins in the material. I am using up to 6 as I need to tile the 4 textures, the heightmaps for blending and a Flow map which I may use optionally or not through a switch. So I have each UV channel plugged into the Custom UV pin, as well as into each texture parameter to define it's UV channel and associate it with the corresponding Custom UV pin (except for the one that is to be in UV Channel 0 which is the default). I understand that is how it's done, although I wonder if the "Const Coordinate" value in the Texture Parameters can be used instead of texture coordinate nodes to achieve the same effect (tell the material which texture gets tiled by which Custom UV coordinate).

The thing is that the material currently kills my framerate and is currently unusable, so I need your help to point out what I can or should do to get it to work with a decent performance. Is it killing my framerate because the Custom UV is not implemented correctly? Would I be better off ignoring any kind of UV tiling and just scale up the mesh UVs and reimport? Am I expecting too much by trying to blend 4 textures? Is using the HeightLerp node too expensive for mobile and should I just set up Lerp nodes with Heightmaps in the alpha to control the blend transition? Is it something else?

Thanks in advance!

alt text

alt text

Product Version: UE 4.20
Tags:
more ▼

asked Oct 21 '18 at 10:55 AM in Rendering

avatar image

Txeroki
3 1 2 3

(comments are locked)
10|2000 characters needed characters left

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question