Announcement

Collapse
No announcement yet.

Set Driven Key to pilot Blend amount of Blend Material

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Set Driven Key to pilot Blend amount of Blend Material

    Hi,

    As the title says. I'm asking the maya specialists
    I would like to drive the blend amount of a Vray blend material. I need to connect different things to be driven by an attribute (3 blend materials + a light). So far, I have no success but I'm not really an animation specialist.
    Any help would be really appreciated.

    Olivier
    www.mirage-cg.com

  • #2
    Hey, to blend a value in vray blend material its just a float. So you need to create your custom attribute on a new control node load that as a driver for the set driven key ui, once you load you will see that attribute appear, then you can pick your blend material as driven. You key the state at initial value, then set the value to which the blend has to go to and key that again. For example control attribute 0, blend amount 0. Control attribute 0.5 blend amount 0.5. You can then change your driven object to a different blend or a light, or whatever and repeat that process. Let me know if you need more help with it.
    Dmitry Vinnik
    Silhouette Images Inc.
    ShowReel:
    https://www.youtube.com/watch?v=qxSJlvSwAhA
    https://www.linkedin.com/in/dmitry-v...-identity-name

    Comment


    • #3
      Originally posted by Morbid Angel View Post
      Hey, to blend a value in vray blend material its just a float. So you need to create your custom attribute on a new control node load that as a driver for the set driven key ui, once you load you will see that attribute appear, then you can pick your blend material as driven. You key the state at initial value, then set the value to which the blend has to go to and key that again. For example control attribute 0, blend amount 0. Control attribute 0.5 blend amount 0.5. You can then change your driven object to a different blend or a light, or whatever and repeat that process. Let me know if you need more help with it.
      Hi Dmitry,

      Thanks for your answer. That is exactly what I'm trying to do, but when I key one of the blend material attributes (opacity or blend amount) it doesn't keep it. I did some driven key stuff before but this time it doesn't seem to work with the VrayMat inputs.
      I will try again. Maybe I did some mistake on the custom attribute part :/
      www.mirage-cg.com

      Comment


      • #4
        Looks like its a bug. The proper dynamic attribute of vray blend is not being exposed in the set driven key editor. I think these attributes need to be modified to be keyable in the channel control ui.
        However the easy thing about set driven key is that you can also manually make it. Here I've attached the scene with this working.
        Attached Files
        Dmitry Vinnik
        Silhouette Images Inc.
        ShowReel:
        https://www.youtube.com/watch?v=qxSJlvSwAhA
        https://www.linkedin.com/in/dmitry-v...-identity-name

        Comment


        • #5
          Thanks a lot Dmitry ! I will check tomorrow morning
          www.mirage-cg.com

          Comment


          • #6
            It works well Dmitry. Thanks a lot!
            But how did you set it up ? Can you describe briefly ?
            www.mirage-cg.com

            Comment


            • #7
              Hey glad it worked for you.
              Sure I can explain:

              A driven key is essentially a remaping of a value, you can potentially achieve the same with the remap node but I don't like that one.
              Your control attribute output must be connected to a key. The key must have corresponding value matching your control attribute. So if your control attribute has a float range of 0-1, then the key has to have 2 keys on the maya timeline one key frame at frame 0 and one keyframe at frame 1 (zero for the start of the control attribute, and one for the end of control attribute) It does not have to be a 0-1, it can be 0-100 or -100-100. For those key frames it has to have a float value which you want to drive your driven attribute by. In case of vray blend, its a 0-1 float. You then plug your keyframe output value into the R,G,B channel of the blend amount using connection editor, or hypershade connection. It has to be plugged into all 3 channels.

              The set driven key ui in maya is ancient, it was there since I studied maya back in 1999. I bet it just hasn't been updated at all, but it's purpose was to automate and simplify this process.
              I often use driven keys for what you would call shader rigging, creating a bunch of custom attributes and wiring them into the shader network so they are all controlled by one main control node. Its super useful when you want to do shots and always set the same values to shaders on different render layes. Example would be - I have scene with a bunch of snow. Its using alsurface to render for main complex shader, but its long and slow to render that. So you create a vray switch material, where you have 0 as alsurface (main shader) then 1 where you have a simple grey vray material. You then create a control attribute called "enum" which you can name like - beauty/simple, and in the shot toggle between alsurface and grey shaded to setup your lighting really quick, then switch back to main alsurface for rendering final.
              Dmitry Vinnik
              Silhouette Images Inc.
              ShowReel:
              https://www.youtube.com/watch?v=qxSJlvSwAhA
              https://www.linkedin.com/in/dmitry-v...-identity-name

              Comment


              • #8
                Thanks a lot Dmitry for your explanation ! Very helpful.
                www.mirage-cg.com

                Comment

                Working...
                X