Announcement

Collapse
No announcement yet.

Vray echo mel commands?

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

  • Vray echo mel commands?

    Is there a way to see, or perhaps get a list in how vray is implemented with Maya mel commands?

    Example:

    When you create a proxy, you don't get a list of strings in the output editor other than button presses being executed to run create proxy.

    I would love to try and script an automatic proxy system that looks for tagged groups to proxy at once. This would allow for me to tag an attribute on a group, then have vray create proxy scan for the attribute, unparent everything below, create proxy then parent it back under the tagged group and continue to the next one.

    This would be a huge time saver for automatically creating proxies to something that is animated by keyframes at group level. Like a car.

  • #2
    Scott,

    I was digging in the vray/scripts directory and found two text files (not mel scripts) that had all of the vray non echoed commands. it was very helpful. With some trial and error and really digging though the "echo" all commands. I was able to make a simple script to turn on the vray gamma/srb node on all or selected file reads. Which at face value for a more novice scripter like me is problematic on figuring out how to turn on a check box as in the file>attribute>gamma node thingy.....

    I've been meaning to post some of my scripts.... I'll try and wrangle them all up this week.

    Andy

    Comment


    • #3
      You can use the vrayCreateProxy MEL command to create .vrmesh files from the selection:
      Code:
      vrayCreateProxy
          -previewFaces $previewFaces
          -dir $path -fname $filename
          [-makeBackup] [-overwrite] [-vertexColorsOn] [-ignoreHiddenObjects]
          [-createProxyNode -node $newNodeName]
          [-animOn -animType {0|1|2} [-startFrame $startFrame -endFrame $endFrame]]
          -exportType {1|2}
          [-velocityOn -velocityIntervalStart $velocityIntervalStart -velocityIntervalEnd $velocityIntervalEnd];
      The parameters are more or less exactly the same as they appear in the V-Ray create proxy dialog. The -animType option specifies the animation range, if -animOn is specified: 1 is playback range, 2 is animation range, 3 is explicit range specified with the -startFrame and -endFrame options. The -exportType option specifies if the entire selection should be exported in one single .vrmesh file (when set to 1), or each object should go into its own file (when set to 2).

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

      Comment


      • #4
        Wow! This is awesome Vlado! Thanks so much. Is any of this documented anywhere?

        Comment


        • #5
          One more question. Is there a way to call the create proxy command and have the name of the proxy created returned? For instance, if I had multiple objects with the same name in the grouping or another group.

          Comment


          • #6
            Just checking in to ask if there's any way to query the vrayCreateProxy command for its parameters... it seems there are some new options (such as preview type) which are not listed in the code snippet above.
            Best Regards,
            Fredrik

            Comment

            Working...
            X