VRaySun and VRaySky Overview


The VRaySun and VRaySky are special features which are provided by the V-Ray renderer. Developed to work together, the VRaySun and VRaySky reproduce the real-life Sun and Sky environment of the Earth. Both are coded so that they change their appearance depending on the direction of the VRaySun.

The V-Ray Sun and Sky are based largely on the model presented in [1]. For a more complete list of references, please see the References and Links section.

Example: Direction of the VRaySun Light

Note: All the images below are rendered with Color mapping: HSV exponentialDark multiplier: 1.0Bright multiplier: 1.0 unless otherwise noted.

This example demonstrates the effect of the sun direction. Note how in addition to the scene brightness, the sun position also changes the appearance of the sky and the sun light color.

Enabled: onTurbidity: 3.0Shadow subdivision: 8Intensity multiplier: 0.01Size multiplier: 1.0.


Sun Z height500


Sun Z height: 1600


Sun Z height: 6000 (almost straight above)

VRaySun Parameters


The VRaySun is located in the (Create - Lights - VRay) panel. You can also specify the VRaySun as the sun type inside a Rhino Daylight system. 

Modify Sun Button - Clicking this button will open up the Rhino Sun Options where you are able to adjust Sun Position, Date and Time, and Location

Sun

Enabled - turns on and off the sun light. 

Water Vapor - aqueous vapor, is the gas phase of water. Water vapor is one state of the water cycle within the hydrosphere. 

Size multiplier - this parameter controls the visible size of the sun. This affects the appearance of the sun disc as seen by the camera and reflections, as well as the blurriness of the sun shadows.

Example: The Size Multiplier Parameter

This example demonstrates the effect of the Size multiplier parameter. Notice how changes in this parameter affect both the visible sun size and the shadow softness (however overall illumination strength remains the same).

Enabled: onTurbidity: 3.0Shadow subdivision: 8, Intensity multiplier: 0.01


Size multiplier is 4.0


Size multiplier is 10.0


Size multiplier is 40.

Horizon Illum. - specifies the intensity (in lx) of the illumination on horizontal surfaces coming from the sky

Sky Model - Allows you to specify the procedural model that will be used to generate the VRaySky texture.

  • Preetham et al. - when this mode is selected the VRaySky procedural texture will be generated based on the Preetham et al. method.
  • CIE Clear - when this mode is selected the VRaySky procedural texture will be generated based on the CIE method for clear sky. 
  • CIE Overcast - when this mode is selected the VRaySky procedural texture will be generated based on the CIE method for cloudy sky

Turbidity - this parameter determines the amount of dust in the air and affects the color of the sun and sky. Smaller values produce a clear and blue sky and sun as you get in the country, while larger values make them yellow and orange as, for example, in a big city.

Example: The Turbidity Parameter

This example demonstrates the effect of the Turbidity parameter. Generally, this controls the amount of dust particles in the air. Notice how larger values cause the sun and the sky to become yellowish while smaller values make the sky clear.

Enabled: onIntensity multiplier: 0.01Shadow subdivision: 8Size multiplier: 1.0


Turbidity is 2.0


Turbidity is 4.0


Turbidity is 8.0

Intensity multiplier - this is an intensity multiplier for the VRaySun. Since the sun is very bright by default, you can use this parameter to reduce its effect. See the Notes section for more information.

Example: The Intensity Multiplier Parameter

Enabled: onTurbidity: 3.0Shadow subdivision: 8Size multiplier: 1.0


Height: Z = 0, Intensity mult: 0.01


Height: Z = 0, Intensity mult: 0.03

Height: Z = 0, Intensity mult: 0.05


Height: Z = 500, Intensity mult: 0.01


Height: Z = 500, Intensity mult: 0.03


Height: Z = 500, Intensity mult: 0.0.

Ozone - this parameter affects the color of the sun light. Available in the range between 0.0 and 1.0. Smaller values make the sunlight more yellow, larger values make it blue.

Example: Ozone Value

The Ozone parameter affects only the color of the light emitted by the sun. Higher values cause the color mapping mode to change. This example demonstrates the looks achieved with several different color mapping modes. See also the section on Color mapping for more details.

Enabled: onTurbidity: 2.0Shadow subdivision: 36, Intensity multiplier: 0.01Size multiplier: 10.0.


Ozone: 0.0


Ozone: 0.5


Ozone: 1.0

Invisible - when on, this option makes the sun invisible, both to the camera and to reflections. This is useful to prevent bright speckles on glossy surfaces where a ray with low probability hits the extremely bright sun disk.

Sampling

Photon Subdivs - this value is used by V-Ray when calculating the Global Photon Map. Lower values mean more noisy results, but will render faster. Higher values produce smoother results but take more time.

Photon Emit Distance - this parameter defines a radius around the sun from where the photons will be shot.

Photon Radius - determines the radius of the area, in where photons would be shot. This area is represented by the green cylinder around the Sun's ray vector. This parameter has effect when photons are used in the GI solutions or caustics.

Caustic Subdivs - this value is used by V-Ray when calculating Caustics. Lower values mean more noisy results, but will render faster. Higher values produce smoother results but take more time.

Affect Diffuse - this determines whether the VRaySun is affecting the diffuse properties of the materials.

Affect Specular - this determines whether the VRaySun is affecting the specular of the materials.

Diffuse Mult - a multiplier for the illumination generated by the Global Photon Map.

Caustic Mult - a multiplier for the illumination created by Caustics.

Shadow

Shadows - turns the casting of shadows On and Off

Shadow Bias - moves the shadow toward or away from the shadow-casting object (or objects). If the bias value is too low, shadows can "leak" through places they shouldn't, produce moire patterns or making out-of-place dark areas on meshes. If bias is too high, shadows can "detach" from an object. If the bias value is too extreme in either direction, shadows might not be rendered at all.

Example: Shadow Bias

Enabled: onTurbidity: 2.0Shadow subdivision: 36, Intensity multiplier: 0.01Size multiplier: 10.0


Shadow bias: 0.0


Shadow bias: 7.0

Shadow bias: 13.0

Shadow Subdivs - this controls the number of samples for the area shadow of the sun. More subdivs produce area shadows with better quality but render slower.  

Example: The Shadow Subdivs Parameter

This example demonstrates the effect of the Shadow subdivs parameter. Note how lower subdivs cause the shadows to be more noisy.

Enabled: onHeight Z1200, Turbidity is 2.0, Intensity multiplier is 0.01, Size multiplier: 10.0


Shadow subdivs is 8


Shadow subdivs is 16


Shadow subdivs is 48

Shadow Color - a tint for the shadows created by the V-Ray Sun

VRaySky Parameters


The VRaySky texture map is typically used as an environment map, either in the Rhino Environment dialog, or in one of the slots of the V-Ray Environment rollout and behaves very much like a HDRI environment map. The VRaySky changes its appearance based on the position of the VRaySun.

Sun - specifies how the VRaySky determines its parameters: 

  • Off - the VRaySky will automatically take its parameters from the first enabled VRaySun in the scene. In this case, none of the other parameters of VRaySky are accessible.
  • On - you can choose a different light source. It is recommended that you choose only direct lights, as the vector for the direction is taken into consideration when computing the appearance of the sky. In that case the VRaySun is no longer controlling the VRaySky and the parameters in the texture map rollout determine the final look of the sky.

Sky Brightness -

Turbidity - refer to VRaySun parameters

Ozone - refer to VRaySun parameters

Invisible - when on, this option makes the sun invisible, both to the camera and to reflections. This is useful to prevent bright speckles on glossy surfaces where a ray with low probability hits the extremely bright sun disk.

Sky Model - Allows you to specify the procedural model that will be used to generate the VRaySky texture.

  • Preetham et al. - when this mode is selected the VRaySky procedural texture will be generated based on the Preetham et al. method. 
  • CIE Clear - when this mode is selected the VRaySky procedural texture will be generated based on the CIE method for clear sky. 
  • CIE Overcast - when this mode is selected the VRaySky procedural texture will be generated based on the CIE method for cloudy sky

Size Mult - refer to VRaySun parameters

Water Vapor - refer to VRaySun parameters

Horizon Illum. - refer to VRaySun parameters

Example: VRay Sun and Sky with Different Color Mapping Types

In addition to the parameters of the sun and sky, their appearance also depends on the selected color mapping mode. This example demonstrates the looks achieved with several different color mapping modes. See also the section on Color mapping for more details.

Enabled: onHeight Z800, Turbidity: 3.0Shadow subdivision: 8, Intensity multiplier: 0.01Size multiplier: 1.0


Color mapping: Linear


Color mapping: Exponential


Color mapping: HSV exponential


Color mapping: Intensity exponential

Notes


  • By default, the VRaySun and VRaySky are very bright. In the real world, the average solar irradiance is about 1000 W/m^2 (see the references below). Since the image output in V-Ray is in W/m^2/sr, you will typically find that the average RGB values produces by the sun and the sky are about 200.0-300.0 units. This is quite correct from a physical point of view, but is not enough for a nice image. You can either use Color mapping to bring these values to a smaller range (which is the preferred way) or you can use the Sun intensity multiplier to make the sun and sky less bright. Using the VRayPhysicalCamera with suitable values also produces a correct result without changing the sun and sky parameters.


Here is a list of links and references about the V-Ray Sun and Sky implementation, as well as general information about the illumination of the Sun.