Announcement

Collapse
No announcement yet.

How to Render through Maxscript to vray VFB

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

  • How to Render through Maxscript to vray VFB

    So if I set my renderer to vray, and run this maxscript command:

    render vfbff

    It does a vray render (vfb off is to turn off the standard max vfb)

    But after rendering to the vray vfb, the vfb disappears. If I run this command:

    renderers.current.showLastVFB()

    It shows me the vray vfb, but it doesn't contain the image I rendered using the maxscript render command, it contains the last image I rendered using the max ui.

    How can I render to the vray vfb through maxscript such that the vfb remains up, or how can I view the vfb that contains my last rendered image using the maxscript render command? Thanks.

    - Neil

  • #2
    Please to see you're making the switch, I can't help you though with this problem unfortunately.

    I've been using VFB+ plugin which doesn't disappear when using texmappreview.
    Win10 x64, 3DS Max 2017 19.0, Vray 3.60.03
    Threadripper 1950x, 64GB RAM, Aurous Gaming 7 x399,

    Comment


    • #3
      Originally posted by soulburn3d View Post
      So if I set my renderer to vray, and run this maxscript command:

      render vfbff

      It does a vray render (vfb off is to turn off the standard max vfb)

      But after rendering to the vray vfb, the vfb disappears. If I run this command:

      renderers.current.showLastVFB()

      It shows me the vray vfb, but it doesn't contain the image I rendered using the maxscript render command, it contains the last image I rendered using the max ui.
      The VFB is created and maintained by the renderer object. When you use the render() command, internally it creates a new renderer, copies the settings from the production one, and then destroys it. The VFB into which this temporary renderer writes the image is destroyed along with it.

      How can I render to the vray vfb through maxscript such that the vfb remains up, or how can I view the vfb that contains my last rendered image using the maxscript render command? Thanks.
      You can do that by using the 3ds Max "render last" or "render" command, rather than the render() call.

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

      Comment


      • #4
        So for example the render last command is
        Code:
        max render last
        ; the command to render the current view is
        Code:
        max quick render
        .

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

        Comment


        • #5
          Originally posted by DPS View Post
          Please to see you're making the switch
          Slowly but surely

          - Neil

          Comment


          • #6
            Originally posted by vlado View Post
            The VFB is created and maintained by the renderer object. When you use the render() command, internally it creates a new renderer, copies the settings from the production one, and then destroys it. The VFB into which this temporary renderer writes the image is destroyed along with it.
            That's only true of vray though, correct? Because if I use the render() command with scanline, mentalray or brazil, the vfb remains up.

            Originally posted by vlado View Post
            You can do that by using the 3ds Max "render last" or "render" command, rather than the render() call.
            So the disadvantage of that technique is that I am not trying to do an exact copy of the production renderer. I want to change a bunch of parameters. Which is why using the render() command has advantages, since it can take arguments that are different from the current settings.

            So I suppose if I can only use render last, I need to store the current values of all the parameters I want to change, change the parameters, do render last, then change all the parameters back?

            Thanks for the suggestions so far.

            - Neil
            Last edited by soulburn3d; 05-09-2013, 08:16 PM.

            Comment


            • #7
              Originally posted by soulburn3d View Post
              That's only true of vray though, correct? Because if I use the render() command with scanline, mentalray or brazil, the vfb remains up.
              If you don't use the V-Ray VFB, then V-Ray will render to the standard 3ds Max frame buffer and will work identically to all the other renderers. But the V-Ray VFB on the other is tied to the renderer, yes.

              So the disadvantage of that technique is that I am not trying to do an exact copy of the production renderer. I want to change a bunch of parameters. Which is why using the render() command has advantages, since it can take arguments that are different from the current settings.
              You could consider the V-Ray VFB to be a part of the renderer settings

              So I suppose if I can only use render last, I need to store the current values of all the parameters I want to change, change the parameters, do render last, then change all the parameters back?
              If you want to use the V-Ray VFB, yes. If the 3ds Max VFB is ok, then you can use the render() command.

              We could think about making the V-Ray VFB global for all renderer instances, but I it is a bit of work and must be tested carefully.

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

              Comment


              • #8
                Originally posted by vlado View Post
                We could think about making the V-Ray VFB global for all renderer instances, but I it is a bit of work and must be tested carefully.
                I think that would be a good idea. In the meanwhile, I'll use the parameter swap technique in my script and use render last. I'll let you know how it goes. Thanks for all the information!

                - Neil

                Comment


                • #9
                  So lets say I use "max quick render" to render to the vfb, how do I then save the resulting image through maxscript?

                  - Neil

                  Comment


                  • #10
                    Originally posted by soulburn3d View Post
                    So lets say I use "max quick render" to render to the vfb, how do I then save the resulting image through maxscript?
                    See here: http://help.chaosgroup.com/vray/help...script.htm#vfb

                    Specifically the vrayVFBGetChannelBitmap() function.

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

                    Comment


                    • #11
                      Thanks Vlado. So the reason I didn't find that was because the url

                      http://help.chaosgroup.com/vray/help/

                      redirects to the 1.5 help file. So I was looking at the wrong helpfile. Now that I know where the vray 2 helpfile is, I'm set. But you may want to have the website guys redirect to the latest and greatest. Thanks again!

                      - Neil

                      Comment

                      Working...
                      X