Announcement

Collapse
No announcement yet.

command to set vray resolution in UI?

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

  • command to set vray resolution in UI?

    Hey,

    I want to use mel to switch the resolution and i can't figure out the command. I don't get any feed back from the script editor in echo all...and the standard

    setAttr defaultResolution.width/height doesn't work for vray common parameters.

    would it be possible to link the maya common default resolution to the vray resolution parameters.... it causes some weird proxy renders as well, since the test resolution is based off of the maya resolution (and smaller "Test resolution" setting from the Maya FB.

    anyone know this?

    on this same note, Vlado I would love a bit more feedback in the script editor when changing UI parameters, as I have to really dig to figure out what the variables are.

    Andy
    Last edited by mr furious; 24-11-2010, 06:56 PM.

  • #2
    Try
    Code:
    setAttr vraySettings.width=X;
    setAttr vraySettings.height=Y;
    There isn't echo in the Script editor as more complicated tasks are peformed when changing the resolution; this is also the case for the Maya software renderer when changing its resolution.

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

    Comment


    • #3
      thanks Vlado!

      I'm going to start a tread so we can keep track of some of the non echo'd attributes. I'm assuming it would be pretty time consuming to ask for these non echo'd attributes in the in the docs? (can't hurt to ask)

      I'm guessing changing the file type is similar. I've noticed i can change the file output type in the vraysettings node, but couldn't figure out how to change it in the main render globals UI.
      Not a huge deal, but i like to make lots of shelf buttons.

      thanks... i'll give it a whirl when i get back to work.

      Andy

      Comment


      • #4
        I'm changing image format like this
        Code:
        setAttr "vraySettings.imageFormatStr" -type "string" "exr";    
        if(vraySetParentToCommonTab()) {
        	optionMenuGrp -e -sl 5 vrayImageFormatMenu;			// format 5=exr
        	evalDeferred vrayUpdateTargetFilePreview;			// update filename and path preview
        }
        I'm not sure if you actually need the first line.

        Comment


        • #5
          Thanks!

          as a relatively new coder... whats the best way to figure out some of the attributes that don't echo in the script editor?

          Comment


          • #6
            Have a look at the mel scripts in the vray install. Often I can simply cut and paste procs from there and change little bits to do what I need.

            Comment


            • #7
              cool thanks!

              A

              Comment


              • #8
                This doesn't work for me.. Did something change in newer builds?

                Comment


                • #9
                  Ok I got it.. Typed in:

                  setAttr "vraySettings.width" 1280;
                  setAttr "vraySettings.height" 720;
                  vrayUpdateResolution();

                  Comment


                  • #10
                    You can also:

                    select vraySettings;

                    and alter attrs on the hidden vraySettings node... those should echo back in the script editor for you.

                    --T

                    Comment


                    • #11
                      Originally posted by treyharrell View Post
                      You can also:

                      select vraySettings;

                      and alter attrs on the hidden vraySettings node... those should echo back in the script editor for you.
                      I was about to suggest that.
                      Make sure you open Render Settings of Vray to have vraySettings node created. Then you can see all the attributes in the Attribute Editor, so you can test them and see their names, etc.
                      V-Ray for Maya developer

                      Comment

                      Working...
                      X