WTF Is? A Dynamic Material Instance in Unreal Engine 4

Поділитися
Вставка
  • Опубліковано 6 січ 2025

КОМЕНТАРІ •

  • @MagimanD
    @MagimanD Рік тому +2

    7 years and still works! great job!

  • @lucas14x87
    @lucas14x87 Рік тому +1

    What's the point of creating a dynamic instance of a material if you can change the parameter directly in the existing material?

    • @PixelsLaboratory
      @PixelsLaboratory Рік тому

      Check my last posted video on this topic, as apparently MIDs are not needed, which is VERY strange. I also made a forum ticket (link in its description). It's beyond me why this works, as the official documentation says you absolutely need a MID in order to control things during gameplay (at runtime), but it works not only by using a MIC instead of MID, but even without using any MI at all, just by using the Material itself 🤯. It's beyond me why, as it completely invalidates Material Instances altogether, not to mention the Constant vs. Dynamic difference.

  • @nierautomata9654
    @nierautomata9654 3 роки тому +1

    You did not click compile when changed the emissive value (50 and 100) thats why it didnt show up..

  • @DutchDread
    @DutchDread 6 років тому +7

    It would be really useful if you actually showed where you're building this blueprint. Is it on the actor that the material is going on, or the player bp? Or where?
    I'm trying everything I can think of but I can't even get "event construct" so.....

    • @LiamHeron
      @LiamHeron 6 років тому +1

      Event construct is found in the blueprint widget that he is using for the button.

  • @lobachevscki
    @lobachevscki 7 років тому +7

    Hi! great material (pun intended). Could you share how did you create the network from the Get All Actors node onwards? just how to get those nodes previous to set material. Thanks!

  • @yk-lz3nr
    @yk-lz3nr 3 роки тому

    So we replace our material that was set in the Editor by our Blueprint material. Thanks now I understand how it works

  • @makadi86
    @makadi86 3 роки тому

    I have used create dynamic material instance to distribute some actors with different colors.
    and that was ok. but when I’m trying to collect the materials in the scene it return one material.
    so I can’t track these actors material parameter values or collect then like I can collect their locations. so how can I collect material data from objects in the scene?

  • @primm4991
    @primm4991 5 років тому +1

    What can I do to change materials parameters in whole scene? I have a road, and I would like to make it look wet when it's rainy. Problem is that this road is not a blueprint. Whac can I do in this situation? Thank you. I would not do anything without your tutorials :D

    • @primm4991
      @primm4991 5 років тому +3

      Nevermind, I have got the answer. If anyone has the same issue, "Material Parameter Collection" is something you should probably look for.

  • @AlexPearce3d
    @AlexPearce3d 3 роки тому

    Thanks for this! Do you have to create a new variable for each instance you want to change? for instance, if I have 10 different texture parameters I want to change, do I need 10 variables?

  • @PixelsLaboratory
    @PixelsLaboratory Рік тому +1

    At 02:29 you said something, which boggles me for the past 2 days... If you check my last posted video on this topic, apparently MIDs are not needed, which is VERY strange. I also made a forum ticket (link in its description). It's beyond me why this works, as the official documentation says you absolutely need a MID in order to control things during gameplay (at runtime), but it works not only by using a normal MIC instead of MID, but even without using any MI at all, just by using the parent Material itself 🤯. It's beyond me why, as it completely invalidates Material Instancing altogether, not to mention the Constant vs. Dynamic difference.

  • @phaeton01
    @phaeton01 7 років тому

    how would you set up an array of textures to cycle through on a timer? would you need a different material for each texture or all the textures in like an array?

    • @MathewWadsteinTutorials
      @MathewWadsteinTutorials  7 років тому

      You can set up a Texture Parameter inside of the Material and then inside your blueprint or whatever controls the material it could change the texture from there. If you are trying to do this all in Material then you could use a time node with a max of your amount of seconds you want before it reset and then feed that value into an if node. That node could then based on the time use that material or if not, it goes to another if node and checks the time and it can repeat like that. I don't know how well this would perform due to the if nodes however.
      Using a blueprint to change the Texture Parameter inside of the Material would be what I would try first personally.

  • @BubuRuzu
    @BubuRuzu Рік тому

    But how do you point to the cube???

  • @yonjuunininjin
    @yonjuunininjin 8 років тому

    Do you know why it's possible to use "Set Scalar Parameter" without any dynamic material instance on the default material? We had this discussion on Discord, but nobody had an idea why it's working.

    • @MathewWadsteinTutorials
      @MathewWadsteinTutorials  8 років тому

      I am assuming this is using the Set Scalar Parameter Value on Materials node? If so this is a node that was added to allow you to change values easily without needing to create the material instance. You will find that there are other nodes that target the Dynamic Material Instance if you need to change other things.

    • @yonjuunininjin
      @yonjuunininjin 8 років тому

      My apologies, yes the full blueprint function name is "Set Scalar Parameter Value on Materials" like you said. Changing values with that node works, but not if you change the material with "Set Material" and using "Set Scalar Parameter Value on Materials" again. Basically this is not working gyazo.com/64e7a8d55d558e356c51a3433e2100e0

    • @conagher
      @conagher 3 роки тому

      It's because in the code of the described function original material is swapped with it's dynamic instance that is created on the fly.

    • @PixelsLaboratory
      @PixelsLaboratory Рік тому

      Check my last posted video on this topic, as apparently MIDs are not needed, which is VERY strange. I also made a forum ticket (link in its description). It's beyond me why this works, as the official documentation says you absolutely need a MID in order to control things during gameplay (at runtime), but it works not only by using a MIC instead of MID, but even without using any MI at all, just by using the Material itself 🤯. It's beyond me why, as it completely invalidates Material Instances altogether, not to mention the Constant vs. Dynamic difference.

  • @decorix
    @decorix 3 роки тому

    Hello,, wow really cool stuff. If I wanted to move a texture vertical on a billboard and lets say some build in timer is that all dynamic? any ideas suggestion would be great. Thanks

  • @ZlotyChannel
    @ZlotyChannel 8 років тому

    Can I use this to modify the specular of a material to do a rain effect? or there's an easier way to change the specular of all the materials in the scene to make the rain effect?

    • @MathewWadsteinTutorials
      @MathewWadsteinTutorials  8 років тому +1

      If you want to change a parameter in more than one material you would look into a Material Parameter Collection.

  • @ammaralammouri1270
    @ammaralammouri1270 4 роки тому

    Thanks Mathew for all your videos , do you have one that i can change between materials rather than vectors

  • @outtoplay
    @outtoplay 8 років тому

    Outstanding. well done! : )

  • @rifat.ahammed
    @rifat.ahammed 7 місяців тому

    Thanks again

  • @arendvandermerwe3309
    @arendvandermerwe3309 4 роки тому +2

    Mad lad spells "colour" wrong, acknowledges his mistake, and just keeps going

  • @ZlotyChannel
    @ZlotyChannel 7 років тому +1

    Hey Mathew I wonder how can I make wrinkle effects for my facial animation. Thanks :D

    • @RolandTechnicalDesigner
      @RolandTechnicalDesigner 7 років тому

      I am no expert but i would probably bake multiple Normal maps on some program like blender from a high poly model to a low poly model 1 without wrinkles and 1 or more with the wrinkles. Then using the method in this video you could make it so that when something happens like a animation the normal map changes and creates wrinkles on the character. To smooth the transition you could use something like a Lerp node. This is probably not the best way of doing it but it should work.

  • @xylvnking
    @xylvnking Рік тому

    thanks :)

  • @everythingisforever
    @everythingisforever 4 роки тому +1

    fyi emissive needed no space

  • @ethanwasme4307
    @ethanwasme4307 9 років тому +1

    omfg, like really... This is perfect for my project!

  • @garageman2236
    @garageman2236 5 років тому +2

    Tomatoes?

  • @rpvs5429
    @rpvs5429 7 років тому +1

    MEUS PARABENSSSSSSSSS rsrr estava uma semana procurando isso rsrs Brasil não tem suporte para unreal VLW