Skip to content
07-848 2005

V-Ray for SketchUp, textures

V-Ray Distance texture

Use the V-Ray Distance texture in SketchUp to set colours based on distance from selected objects.

On this page
  1. Overview
  2. Where to find it
  3. Parameters
  4. Example: Distance with a Noise texture
  5. Example: Far Color
  6. Example: Near Color
  7. Inside Separate
  8. Example: Inside Separate
  9. Outside Separate
  10. Example: Outside Separate
  11. Example: Refine texture placement with the Distance texture
  12. Example: Displacement
  13. Example: Fur

Use the V-Ray Distance texture in SketchUp to set colours based on distance from selected objects.

Overview

VRayDistanceTex is a procedural texture specific to V-Ray. It returns a colour based on a point's distance from the objects in a selection list.

Replace With New Texture icon.
V-Ray Distance texture result shows stepped rings in sand around a dark, curved object.

Where to find it

||V-Ray Asset Editor|| > Textures (right-click) > Distance

||V-Ray Asset Editor|| > Create Asset (left-click) > Textures > Distance

Parameters

Distance specifies a texture that multiplies the distance value. Within the radius, black areas of the distance map shade points with Far Color. White areas shade them with Near Color. See the Distance Texture example below.

Far Color sets the colour for points farther than the Distance value from the listed objects. See the Far Color example below.

Near Color sets the colour for points at the edges of the listed objects. See the Near Color example below.

Add Objects adds the objects you have already selected in the scene.

Distance parameters show Distance set to 10, white Far Color, black Near Color and the Add Objects button.

Example: Distance with a Noise texture

In this example, the Fur geometry uses a Distance texture as its Density map. The Distance texture has a Distance value of 60 and uses a Noise map. Rocks and grass Assets are added to the Distance texture's Add Objects list. Fur Density is zero within a radius of 60 units from these objects. Outside this radius, Density uses the value set by Fur Count. The Noise texture multiplies the Distance value. Within the radius of 60 units, black points in the Noise texture give zero Fur Density, while white points give normal Density. This varies the grass density for a more natural appearance.

Grass surrounds rocks and grass clumps, with broad areas of exposed gravel between them.
Noise varies grass density around rocks and grass clumps, creating patches of grass and exposed gravel.

Example: Far Color

Far Color example shows grass around three rocks, bare soil along their edges and an inset greyscale Distance texture.

Far Color

= R1G1B1

V-Ray Distance render shows sparse grass around three rocks, with a dark circular greyscale texture preview.

Far Color

= R04G04B04

V-Ray Distance render shows more grass around three rocks, with a circular greyscale texture preview.

Far Color

= R06G06B06

V-Ray Distance render shows patchy grass around three rocks, with a black and white noise texture preview.

Far Color

= Noise

V-Ray Distance render shows dense grass around three rocks, with a circular greyscale texture preview.

Far Color

= R08G08B08

Example: Near Color

V-Ray Distance Near Color example shows thick grass around three rocks, with a bright circular texture preview.

Near Color

= R0G0B0

V-Ray Distance Near Color example shows thick grass around three rocks, with a sharply defined dark ring in the preview.

Near Color

= R02G02B02

V-Ray Distance render with Near Color set to R02G02B02, showing stones in grass and a greyscale preview.

Near Color

= R04G04B04

V-Ray Distance render with Near Color set to R04G04B04, showing stones in grass and a greyscale preview.

Near Color

= R06G06B06

V-Ray Distance render with Near Color set to R06G06B06, showing stones in grass and a Noise texture preview.

Near Color

= Noise

Inside Separate

Inside Separate replaces Near Color with Inside Color for points inside the specified geometry when enabled.

Inside Color sets the colour for points just inside the listed objects.

Inside Solid applies Inside Color to all points inside the specified geometry when enabled. The colours do not blend.

Inside Separate panel with Inside Separate enabled, Inside Color set to black and Inside Solid disabled.

See the Inside Separate example below.

Example: Inside Separate

In this example, the stones are hidden by adding Raytrace Properties Attribute and turning off all visibility options. When you use a Noise map for either Inside or Outside colours, the preview swatch does not show the final Distance texture or any noise. In these cases, only the Noise texture appears in the render.

V-Ray Distance render with stones hidden, showing bare patches in the grass and a greyscale texture preview.

Color = R0G0B0

V-Ray Distance render with Color set to R0G0B0, showing grass across the hidden stone footprints.

Color = R04G04B04

Inside Separate result shows grass within bare soil borders and a light grey circular texture preview.

Color = R08G08B08

Inside Separate result shows bare soil patches in grass and a black circular texture preview.

Color = R0G0B0; Inside Solid = On

Inside Separate with Inside Solid on shows grass within soil borders and a white circular texture preview.

Color = R1G1B1; Inside Solid = On

Inside Separate with Inside Solid on shows patchy grass and exposed soil, with a black-and-white noise preview.

Color = Noise Texture; Inside Solid = On

Outside Separate

Outside Separate replaces Near Color with Outside Color for points outside the specified geometry when enabled.

Outside Color sets the colour for points outside the listed objects.

Outside Solid applies Outside Color to all points outside the specified geometry when enabled. The colours do not blend.

See the Outside Separate example below.

Outside Separate panel shows an unchecked Outside Separate box and disabled Outside Color and Outside Solid controls.

Example: Outside Separate

Outside Separate result shows three rocks surrounded by grass and soil, with a shaded circular texture preview.

Color = R0G0B0

V-Ray Distance result at R0G0B0, showing bare patches around rocks and a grey distance map inset.

Color = R04G04B04

V-Ray Distance result at R04G04B04, showing grass close to the rocks and a light grey distance map inset.

Color = R08G08B08

V-Ray Distance result at R08G08B08, showing rocks on bare soil and a distance map inset with a black background.

Color = R0G0B0; Outside Solid = On

V-Ray Distance result at R0G0B0 with Outside Solid on, showing dense grass and a distance map inset on white.

Color = R1G1B1; Outside Solid = On

V-Ray Distance result at R1G1B1 with Outside Solid on, showing patchy grass and a mottled black-and-white map inset.

Color = Noise Texture; Outside Solid = On

Example: Refine texture placement with the Distance texture

Watch the example on YouTube.

Example: Displacement

This example shows how to use geometry to create a Distance map for Displacement. The pot has a Displacement geometry tool. It uses the Distance texture created from the intersection as its Displacement map.

Rendered pot holding a flowering tree, with surface displacement driven by a V-Ray Distance texture.

Displacement:

Off

Vase with protruding pinwheel decorations and an inset showing the source geometry.

Distance:

Geometry

Vase with pinwheel reliefs blended into its surface using the V-Ray Distance texture.

Distance Displacement

,

White Ceramic:

On

Example: Fur

The Density image shows how the Distance texture controls grass density. Inside Separate and Inside solid are set to On, and Inside Separate uses black. The final image shows how the Distance texture controls grass density and length, with a map connected to Length.

Courtyard render with stone paving slabs set in gravel around a vase holding a flowering tree.

Fur:

Off

Courtyard render with dense grass covering the ground and hiding the paving slabs.

Distance:

Off

Courtyard render with dense grass beside the paving and scattered blades growing through the slabs.

Distance:

Density

Courtyard render with grass density and length controlled to keep the paving slabs clear.

Distance Inside Separate:

Density

Rendered garden showing V-Ray Fur grass density around a stone path.

Distance Inside Separate:

Density Length

Procadsys customer support

Still need help?

Licences, renewals and billing

Our New Zealand team looks after your V-Ray licences, renewals and invoices.

Monday to Friday, 9:00 am to 4:30 pm NZ time, excluding New Zealand public holidays.

Technical problems

Installation errors, crashes and other technical problems with V-Ray are handled by Chaos support.