Announcement

Collapse
No announcement yet.

DistanceTex + Ramp control

Collapse
This topic has been answered.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • DistanceTex + Ramp control

    Can Ramp Tex control the fade of Distance Tex like the 3ds Max version?
    (VRayDistanceTex + Ramp)​
    https://docs.chaos.com/display/VMAX/VRayDistanceTex

    OakCorp Japan - Yuji Yamauchi
    oakcorp.net
    v-ray.jp
  • Answer selected by aleksandar.kasabov at 05-04-2023, 02:10 AM.

    Hi flat, it is possible to use it, although the setup is a bit different. Unfortunately the setup is also currently only available for the node materials.

    Basically you need to connect the distance node to the Context port of the ramp node (with an intermediate conversion from Color to UVW). See the example below:
    Click image for larger version

Name:	distance_tex_with_ramp.png
Views:	187
Size:	515.5 KB
ID:	1177435

    Comment


    • #2
      Hi flat, it is possible to use it, although the setup is a bit different. Unfortunately the setup is also currently only available for the node materials.

      Basically you need to connect the distance node to the Context port of the ramp node (with an intermediate conversion from Color to UVW). See the example below:
      Click image for larger version

Name:	distance_tex_with_ramp.png
Views:	187
Size:	515.5 KB
ID:	1177435
      Deyan Hadzhiev
      Developer
      chaos.com

      Comment


      • #3
        Thank you for your advice.
        I noticed that Color to UVW Node describes an application.
        Here is what I wanted to know. thank you.

        https://docs.chaos.com/display/VC4D/Color+to+UVW+Node

        OakCorp Japan - Yuji Yamauchi
        oakcorp.net
        v-ray.jp

        Comment


        • #4
          Hi again, just as a follow up, because I forgot about the native Colorizer shader. Since we added native support for it, you can actually use it for a similar setup (which should also work for displacement). Here is an example:
          Click image for larger version

Name:	distance_tex_with_colorizer.png
Views:	182
Size:	502.0 KB
ID:	1177443
          Deyan Hadzhiev
          Developer
          chaos.com

          Comment


          • #5
            Thank you for the additional useful information!

            OakCorp Japan - Yuji Yamauchi
            oakcorp.net
            v-ray.jp

            Comment


            • #6
              deyan.hadzhiev Could you explain what does the color to uvw node do in this situation? Is this something necessary or just for fast explanation sake?

              I was wondering if parametric objects will be supported by the distance map in the next updates? i had to make the linked objects editable to make the distance map work.

              Comment


              • #7
                Hi akos_kiss, the workings of the Color to UVW node are briefly explained here, but generally in this context it is used to "drive" the vertical part of the UV coordinates for the ramp and is necessary for this setup. As a whole the Color to UVW node is used to convert any color (or grayscale) information into a UVW coordinate pair that may be used in another node's Context port.

                More specifically in the case in the example - the distance node produces values from black to white, based on the distance from the geometry. This output is then converted to the V part of the UV coordinates that will be used to sample the Ramp (or Gradient) node. So values which are black (or close to black) will make the sampler use values from the bottom of the gradient, while values which are white (or close to white) will use values from the top of the gradient.

                I was wondering if parametric objects will be supported by the distance map in the next updates? i had to make the linked objects editable to make the distance map work.
                Currently V-Ray for Cinema 4D supports only parametric Sphere, Plain and Renderable Splines, but unfortunately the distance node implementation in V-Ray can only work with triangulated geometry. So this means you need to either make the object editable, or have it somehow produce real triangles (e.g. by disabling the "Render perfect" Sphere option). For now there are no plans on adding support for non-triangulated geometry, at least not for the next updates of V-Ray 6.

                I hope this answers your questions. Don't hesitate to ask more if you need further assistance.
                Deyan Hadzhiev
                Developer
                chaos.com

                Comment

                Working...
                X