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"

Can texture coordinate parameters be applied to material instances?

Hi.

I'm setting up a master material for instancing and am having trouble figuring out how to add texture coordinate functionality to the master material so that I can scale the material instances without having to create a new material and add a new texture coordinate each time. Is this possible?

In short - how do I add texture scaling functionality to my material instances?

Thanks!

Product Version: Not Selected
Tags:
more ▼

asked Mar 27 '14 at 02:36 AM in Rendering

avatar image

soulblighter
36 3 6 6

avatar image BiasedGamer Jul 14 '14 at 12:50 AM

So what I tried to do is get my TexCoord and multiply it with a Scalar Param but it messes with my textures![alt text][1]

Before

![alt text][2]

After

Am i ding something wrong also whats MIC [1]: /storage/temp/10246-screenshot+2014-07-13+17.44.27.png [2]: /storage/temp/10247-screenshot+2014-07-13+17.44.40.png

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

5 answers: sort voted first

Yes, they can be applied. They have to first be exported as parameters from the original material. This was a bit difficult for me to find also, not sure why you cannot directly exporte the TextureCoordinate object.

This is how you can export UV coordinates from the original material:

  • add two ScalarParameter nodes and name them UTiling and Vtiling

  • add Append node and connect the two previews nodes to it

  • add a Multiply node and a TextureCoordinate node and connect the outputs of the Append and TextureCoordionate node to the Multiply node

  • connect the output of the Multiply node to the UVs input of your TextureSample node

Now, the two UV coordinates will appear in your material parameters. Go ahead and make a material instance by right clicking the material in the content browser, double click the material instance and modify the UV tiling in the upper left corner in the Parameters window.

Video tutorial here: https://youtu.be/y7yWSlzxu-4

alt text

more ▼

answered Feb 04 '16 at 02:26 PM

avatar image

Andrei Branescu
207 6 33 26

avatar image so2gamemake Mar 01 '16 at 05:32 AM

Thank you for this. I make into Material Function so I can easily share between other materials! :)

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

MIC is a material instance constant which you can read up on here:

https://docs.unrealengine.com/latest/INT/Engine/Rendering/Materials/MaterialInstances/index.html

Basically you create one by right clicking on your material in the content browser and selecting create material instance. The material instance will be a child of your parent material and when you add scalar parameters and so on in your material, you add functionality to the material INSTANCE which can be edited more quickly.

alt text

This is what the material EDITOR window looks like and how the scalar multiply should be setup. (don't worry about the texture looking weird in the material editor, it happened for me too)

alt text

And this is the material INSTANCE window, which looks different to the material editor. You can see I have parameters for the roughness, metallic and SCALAR. (which I should have probably named uv scaling)

If I change the 1.0 value to 2.0 or 4.0 or whatever it will scale the material UV's, in essence replacing the texture coordinate as the UV scaling option.

Remember to check the tickbox in the parameter value to edit the values in the MIC.

Hope this helps ;)

more ▼

answered Jul 14 '14 at 01:30 PM

avatar image

soulblighter
36 3 6 6

avatar image Bob3DGames Jan 21 '16 at 07:52 PM

It seems a bit odd to me that you can't convert a TexCoord node into a parameter.

Anyway, this post almost answers my question. What I need to be able to do, however, is tile each dimension separately. How would I go about doing that?

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

multiply your texture coordinate by a scalar parameter. then you can edit the scalar parameter in the MIC.

more ▼

answered Mar 27 '14 at 02:41 AM

avatar image

Jordan Walker STAFF
66 2 2 1

avatar image soulblighter Mar 27 '14 at 02:43 AM

Thanking you sire ;)

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

vreviews, it looks like you're multiplying by 0 as your default, just do some other value and you will be fine. A good default is 1, higher than 1 will tile more, less than 1 will tile less.

more ▼

answered Jul 14 '14 at 01:34 PM

avatar image

Jordan Walker STAFF
66 2 2 1

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

It seems a bit odd to me that you can't convert a TexCoord node into a parameter.

Anyway, this post almost answers my question. What I need to be able to do, however, is tile each dimension separately in each material instance. How would I go about doing that?

Edit: I tried multiplying the TexCoord node by a Constant2Vector, which works in an ordinary material. However, when I convert the C2V node to a parameter it turns it into a four channel colour input which causes an error in the multiply node.

more ▼

answered Jan 21 '16 at 07:51 PM

avatar image

Bob3DGames
119 4 11 16

avatar image Andrei Branescu Feb 04 '16 at 02:29 PM

Look at my answer below, I have found a solution.

(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