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"

Office Holiday

Epic Games' offices will be on holiday from June 22nd to July 7th. During this period support will be limited. Our offices will reopen on Monday, July 8th. 

What't the right way to override and clear a texture in a material instance?

I have a material which uses texture parameters. If I create a material instance, I want to override some of these textures, specifically clear them (make the material behave as if they're all black). I tried overriding the parameter and selecting "clear" on the texture, which makes the texture show "None", but this doesn't work - the material still uses the default texture used by the parent material. Everything works properly if I replace the texture with some other texture, instead of just leaving it "None".

Am I doing something wrong? What's the right way to disable a texture in the instanced material?

Thanks, Dan

Product Version: UE 4.15
Tags:
more ▼

asked Jul 30 '17 at 09:06 AM in Using UE4

avatar image

dandrestor
33 1 2 3

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

2 answers: sort voted first

texture parameter shouldn't be None. if you need it to be black, create simple 2*2 black texture and set it in material instance.

or use static switch node to replace all textures with vector (0,0,0) or even scalar 0.

more ▼

answered Jul 30 '17 at 11:58 AM

avatar image

redbox
4.3k 80 17 104

avatar image dandrestor Jul 30 '17 at 12:15 PM

Thanks, I ended up going the static switch route. Can you explain what "none" means and why it doesn't work?

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

None means no value. In materials texture samples must have value to pass some color into shader. Its because they always have default texture value. if you set None, you will get an error, and shader doesn't compile.

more ▼

answered Jul 30 '17 at 12:21 PM

avatar image

redbox
4.3k 80 17 104

avatar image dandrestor Jul 30 '17 at 01:40 PM

Is there a reference to any official documentation you could provide for this? Thanks.

avatar image redbox Jul 30 '17 at 03:34 PM

Never saw any documentation about. This information from my experience.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
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