Announcement

Collapse
No announcement yet.

Texture Baking with Vray in Max frame buffer, white background wanted.

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

  • Texture Baking with Vray in Max frame buffer, white background wanted.

    Dear all,

    when texture baking objects with Vray, using the Max frame buffer, the bake element setting "background color" is ignored. Also, if I change the render output bitmap background color to white (per script), it is ignored, since Vray obviously renders the textures always with a black background.
    Is this because of lightcache and irradiance map settings?
    I would like to render the lightmaps with a black background and the aoMaps (I use a VraycompleteMap for this with an AO override material in the scene) with a white background.

    Can I force this via maxscript? Rendering with transparency and doing the background in photoshop is a workaround, but much better it would be to have a white background in the beginning.
    I use still Vray Advanced 2.1 and Max 2012.

    Thank you much and best regards

    Robert
    Last edited by Robert1977; 11-03-2015, 07:21 AM.
    Robert

    Max, VRay, Fusion:

    https://www.youtube.com/watch?v=g5fSLrVzpxg
    https://www.youtube.com/watch?v=bpmJgTb_9Ro

  • #2
    You can change the environment color in the 3ds Max Environment dialog - it will be used as the texture baking background.

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

    Comment


    • #3
      Hmm, I just tried this, but it doesn't have an effect. Do I need the Vray Frame buffer? But here it also doesn't change anything. Is this a feature in an updated Vray version?
      The background is just black, regardless, what environment color I use.

      Best regards

      Robert
      Robert

      Max, VRay, Fusion:

      https://www.youtube.com/watch?v=g5fSLrVzpxg
      https://www.youtube.com/watch?v=bpmJgTb_9Ro

      Comment


      • #4
        I'm able to get this same issue. Is there a reason why the background has to be white for the AO pass? If there's edge issues maybe increasing the Padding would be a solution.
        Brendan Coyle | www.brendancoyle.com

        Comment


        • #5
          The reason is, that I want to have the freedom to rescale the baked maps later on to make them smaller for different applications and texture memory limitations. Also, if you are far away from the object in the 3d-environment, the mipmap levels are displayed which rescale the maps as well. Larger padding might help, but with rescaling it might not be sufficient.
          Robert

          Max, VRay, Fusion:

          https://www.youtube.com/watch?v=g5fSLrVzpxg
          https://www.youtube.com/watch?v=bpmJgTb_9Ro

          Comment


          • #6
            Hi Vlado, is there an update on this feature? Right now only the mental ray ambient occlusion bake element can switch its background color with the thumbnail provided in the render element. By default it is white. The way you described with setting the Background color in the environment doesn't work (at least on my computer). Actually for all vray bake elements the background color is not changeable, or I am missing something.

            Thanks and best regards

            Robert
            Robert

            Max, VRay, Fusion:

            https://www.youtube.com/watch?v=g5fSLrVzpxg
            https://www.youtube.com/watch?v=bpmJgTb_9Ro

            Comment


            • #7
              You can always save it out with alpha and just put white under it, but I guess if you have 100's of objects that's a pain. Maybe 'affect background' in the color mapping could help? (Guessing)

              Comment


              • #8
                Thanks, Deflaminis. Your suggestion is good, this is what I did before. I rendered it out with Alpha and put white under it later in Photoshop via batchscript (maxscript to vbs to javascript to Photoshop). This works fine and automatically, but it still needs a lot of converting time.
                So I today scripted to bake with Mental Ray Ambient Occlusion just for the AO pass and then switch back to Vray. Mental Ray has the white background in its render element AO and so I can save the png just without transparency.
                "Affect background" in the color mapping doesn't have an influence on the background of the bake element.

                Cheers
                Robert

                Max, VRay, Fusion:

                https://www.youtube.com/watch?v=g5fSLrVzpxg
                https://www.youtube.com/watch?v=bpmJgTb_9Ro

                Comment


                • #9
                  You can also just stick a white plane out in the distance and have it ignored by shadows, GI, AO and the like.

                  Comment


                  • #10
                    Hi Joelaff, can you explain further what you mean?
                    Robert

                    Max, VRay, Fusion:

                    https://www.youtube.com/watch?v=g5fSLrVzpxg
                    https://www.youtube.com/watch?v=bpmJgTb_9Ro

                    Comment


                    • #11
                      Not working with texture baking I guess.
                      Robert

                      Max, VRay, Fusion:

                      https://www.youtube.com/watch?v=g5fSLrVzpxg
                      https://www.youtube.com/watch?v=bpmJgTb_9Ro

                      Comment


                      • #12
                        I think I misunderstood your goal. I thought you were doing an AO pass of the image rendered from the camera. But you want to bake textures instead. So my suggestion is meaningless

                        Sorry.

                        Comment


                        • #13
                          Dear Chaosgroup team, still, when baking textures with Vray, the background color set you can set in the render to texture window (or by script) will be ignored for the VrayCompleteMap. It will always be black. I assume this is because of the frame buffer that just ignores the settings. Setting the environment color under Max -> Environment or under Vray Render Settings -> Environment doesn't have any effect.
                          Could this be solved? Would be great, since I don't want to use Mental Ray for baking AO. Or is it planned to have A VRayAO Bake Element in the future?

                          Kind regards
                          Robert

                          Max, VRay, Fusion:

                          https://www.youtube.com/watch?v=g5fSLrVzpxg
                          https://www.youtube.com/watch?v=bpmJgTb_9Ro

                          Comment


                          • #14
                            It is somewhere on the "to do" list to have a baking AO element.

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

                            Comment


                            • #15
                              Thanks for the quick reply. Would there be a workaround until then to get a white background during rendering on a vray bake element that I could use with the AO override material (Lightmat with dirtmap)? So a bake Element that by default has a white background.

                              Cheers

                              Robert
                              Robert

                              Max, VRay, Fusion:

                              https://www.youtube.com/watch?v=g5fSLrVzpxg
                              https://www.youtube.com/watch?v=bpmJgTb_9Ro

                              Comment

                              Working...
                              X