Announcement

Collapse
No announcement yet.

Enhance vrayUserScalar to allow addressing of any node property instead of just user

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

  • Enhance vrayUserScalar to allow addressing of any node property instead of just user

    If I could access any user property, we could do some interesting shaders driven by individual objects animations.

    As far as I know, there's no way to create a user property that updates every frame, or one that can be wired/scripted.

    If the userscalar could take a variable such as $.height, or $.pos.x, or $(some custom attribute).value then we could do some interest things...

    Would that be possible?
    Patrick Macdonald
    Lighting TD : http://reformstudios.com Developer of "Mission Control", the spreadsheet editor for 3ds Max http://reformstudios.com/mission-control-for-3ds-max/




  • #2
    Sounds interesting, a temporary work-around would be to have a time callback script which updated a user-defined property with the object property, but this would a bit laborious to set up each time.

    I'd be in favour of a Maxscript property query, as long as error handling could be handled with some kind of visual debugger.
    Maxscript made easy....
    davewortley.wordpress.com
    Follow me here:
    facebook.com/MaxMadeEasy

    If you don't MaxScript, then have a look at my blog and learn how easy and powerful it can be.

    Comment


    • #3
      Yes, thanks for the suggestion. A callback could work, or a pre-render-per-frame script, could do the trick too maybe, but yes, it's a faff.
      I assume the current Scalar parameter returns black if no attribute is found?
      Patrick Macdonald
      Lighting TD : http://reformstudios.com Developer of "Mission Control", the spreadsheet editor for 3ds Max http://reformstudios.com/mission-control-for-3ds-max/



      Comment


      • #4
        Hi Patric,

        I'm not sure whether the V-Ray User Scalar node will be extended in that direction, but I think you could use the Max native script controllers for this.
        Click image for larger version

Name:	Q6F520P.png
Views:	1
Size:	157.6 KB
ID:	855815
        Tashko Zashev | chaos.com
        Chaos Support Representative | contact us

        Comment


        • #5
          Originally posted by re:FORM View Post
          As far as I know, there's no way to create a user property that updates every frame, or one that can be wired/scripted.
          There is, actually. You can create a dynamic attribute with a special name that V-Ray picks up as a user attribute. See here for more info (I can also post a simple scene with the setup, if you are interested):

          http://docs.chaosgroup.com/display/V...userattributes

          (the part where it says Animated user attributes).

          Best regards,
          Vlado
          I only act like I know everything, Rogers.

          Comment


          • #6
            Ah sorry, this was in Maya... For 3ds Max you are right that there is no way to do it right now.

            Best regards,
            Vlado
            I only act like I know everything, Rogers.

            Comment


            • #7
              Hah, yes, I was about to say! I did see that in Maya it was working nicely.

              What would be the 3dsmax equivelant? You can add a custom attribute to either the base object or to a attribute holder modifier.

              What would work best? Both I guess, although it would probably be lighter computationally to check the base object for a custom attribute than to check all the modifiers for custom attributes and then match the attribute name... but then it's often nice to hook directly in to a custom attribute in an attribute holder modifier which might hold a bunch of other animation controllers.
              Patrick Macdonald
              Lighting TD : http://reformstudios.com Developer of "Mission Control", the spreadsheet editor for 3ds Max http://reformstudios.com/mission-control-for-3ds-max/



              Comment


              • #8
                I guess we can do whatever is easier for you. The check for the attribute value is done only once per frame, so it doesn't matter too much how complicated it is. Should we just go through all modifiers looking for an attribute holder modifier?

                Best regards,
                Vlado
                I only act like I know everything, Rogers.

                Comment


                • #9
                  That would be great as it would cover all bases I think....
                  Thanks vlado!
                  Patrick Macdonald
                  Lighting TD : http://reformstudios.com Developer of "Mission Control", the spreadsheet editor for 3ds Max http://reformstudios.com/mission-control-for-3ds-max/



                  Comment


                  • #10
                    Any news about that?

                    Comment


                    • #11
                      Nope, not yet. How important is this for you?

                      Best regars,
                      Vlado
                      I only act like I know everything, Rogers.

                      Comment


                      • #12
                        nothing urgent
                        but this could be extremely usefull in some situations

                        Comment

                        Working...
                        X