Announcement

Collapse
No announcement yet.

VrayTriplanar Baking

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

  • VrayTriplanar Baking

    Is it possible to somehow bake the unwrap that the triplanar does in rendertime? For example in the map node, we could select which channel to bake it to, click bake and it somehow could do a render calc without affecting the actual render setup in the scene.

    This would be amazing not only so that we could use it in other render engines that don't have such a good triplanar, but also to minimize the calculations at render time. Also we could then customize the unwrap if needed. I don't know how long this would take, but probably doing it on the GPU side would be faster?

  • #2
    You should be able to do this with render to texture already...

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

    Comment


    • #3
      The standard render to texture interface isn't good at rendering specific maps, but I have a script that does it called texmapBaker:

      http://www.neilblevins.com/cg_tools/...urnscripts.htm

      Give it a shot, and see if it does what you need.

      - Neil

      Comment


      • #4
        I have a job in hands where i have to bake the triplanar, i tried several options, but none seem to work:

        Clean channel 1 » Apply shader with triplanar with texture in channel 1 » render to texture "use existing channel" = 1 » does nothing
        Clean channel 1 » Apply shader with triplanar with texture in channel 1 » render to texture "use automatic unwrap" = 1 or 2 » uses 3dsmax default auto unwrap in both options
        Clean channel 1 » Add new Unwrap in channel 2 » Apply shader with triplanar with texture in channel 2 » render to texture "use existing channel" = 2 » does nothing

        Also neil's script doesn't change anything here, still no baking.

        Anyone able to do this? Vray 3.45.02

        Comment


        • #5
          Ive done that kind of work the last vew days, I hate render to texture but it works.

          You can't get the UVs the Triplaner creates, you'll have to do your own uvs.
          But the triplaner blending and tiling can be baked in.
          Unwarp your model and take care nothing is overlapping.
          Create a new VrayMtl. plug your map into the selfillumination slot and put it onto your model.
          Deactivate the exposure control and the gi.
          Select your model open Render to Texture dialoge, add a selfillum element and deactivate color mapping.
          Set up size/path and push render.

          You can also do that with Multi/Subobject based materials.
          Create a VrayMultiSubTex, plug all your maps of one kind (diffuse for example) into the right channel and use the VrayMultiSubTex as the selfillum tex.
          Normal maps will come out in linear space, for use in other engines (for example unity) you'll have to open the map in photoshop add a exposure ajustment layer and edit the gamma. 0.47 seems to be right.

          Edit:
          @Vlado: Are you going to do a vray version of the 'save map...' feature as part of the Mateial Preview improvement you are planning?
          Could make those things easier/faster. But it would need an option to add a reference geometry for the geometry dependent stuff.

          @Neil: Have to give that a try. Sounds great
          Last edited by Ihno; 05-07-2016, 06:06 AM.
          German guy, sorry for my English.

          Comment


          • #6
            But that's not what im looking for, i just want the UV's it creates (of course without the blending and tiling, even though it could be done after the uv's were created)...

            Comment


            • #7
              I think thats what Vlado meant.
              So you're not looking for a way to bake the triplaner map but to kind of collapse its UV's onto your model. Which propably would be a simple box mapping without the blending... But a relaxed one...

              You could use box mapping and 'pack uv's...' to make it quick.
              The benefit of my workflow is that you don't have to take care that everything is tiling correctly, which can be very hard to do over map seams in a 2d software like Photoshop.
              Last edited by Ihno; 05-07-2016, 06:15 AM.
              German guy, sorry for my English.

              Comment

              Working...
              X