HOW-TO: Use Reflection Probes

Env Probes - which are Reflection Probes - are responsible for reflections and indirect/ambient lighting in a given area.

They cover a spherical area based on its bounding box, and override lighting and reflection on the environment in this contained area. Anything within the volume of the Env probe will use the cubemap rendered from the origin of the env probe.

Learn the basics of applying weather, here:https://cdprojektred.atlassian.net/wiki/spaces/W3REDkit/pages/6325476.

Exteriors and interiors

Each world has 1 large all-encompassing Env probe, with the lowest importance, usually placed a few meters into the air to add global ambient lighting.

  • exterior location - usually then has its own all-encompassing Env Probe to give more accurate near lighting and general reflections, most often placed in the centre of a village or clearing. Some large geological formations, such as deep crevices had Env Probes added because at the bottom of these formations, less of the sky would be reflected. There are also smaller env probes above mesh water bodies to add reflections of their surroundings.

  • interiors - each room would have its own Env Probe to cut out the sky ambient from the global Env Probe and then provide more accurate local ambient and reflections. For caves, it’s one large env probe that covers the entire cave. And then any chamber that had more significant local lighting changes would be its own Env probe.

Keep EnvProbe overlapping/nesting to a minimum for performance. Try to use them only when a high contrast in the lighting of a space or important reflective surfaces appears.


Placing an EnvProbe

To place an envprobe, you should select the envprobe EntityTemplate in the Asset Browser and place it in the world.

You can place many env probes in many different layers in your world to cover specific areas or globally affect the whole environment. The envprobe EntityTemplate has an CEnvProbeComponent with default settings.


Properties

Property name

Description

Property name

Description

Contribution

-1 makes it a global probe.

NestingLevel

controls the order in which Env probes are stacked. The higher number has priority over lower numbers.

effectIntensity

allows the impact of the Env Probe to be adjusted from 100% replacement to a mix of the probes below in importance.

areaMarginFactor

controls the width transition over which the Env Probe will be rendered

areaDisplace

move the area of effect separate from the origin of the probe which the cubemap is baked from. Often you want to place the cubemap in a good middle spot, not too close to walls or other surfaces and away from light sources. This allows you to have a well-positioned cubemap and then position the area of effect back over the room or location precisely.

isParallaxCorrected

parallax Corrected is useful when placing an env probe above a highly reflective plane such as puddles. It fixes the perspective of the reflection to look correct on horizontal surfaces.

parallaxTransform

how to transform the parallax shift

genParams

generation parameters: Env probes also have settings for directing the look of a space.

useInInterior

you can set an Env probe to only render within Weather Volumes which allows you to constrain the effects of the env probe to a certain area, such as the interior of a cave without darkening the landscape above or the interior of a building.

useInExterior

un-check useInExterior and then it would only render on top of weather volumes.

isInteriorFallback

 

cullingDistance

do not render behind that distance

ambientColor

you can add a tint to the ambient to shift the colour of a space. We used this subtly, mostly in caves and abandoned interiors, it creates a visual disconnect with the sky or lights when large shifts are used.

ambientIntensity

you can also boost the ambient, which was used sometimes to brighten very dark spaces without adding extra lights.

dimmerFactor

 

fadeInDuration

how quickly the effects of the probe are applied

fadeOutDuration

how quickly the effects of the probe fade out when leaving the area

lightScaleGlobal

 

lightScaleLocals

0 should cut the point lights from showing in the rendered cubemap

fogAmount

the amount of fog

daycycleAmbientIntensity

 

daycycleLightScaleLocals

 

daycycleEffectIntensity

 

image-20240327-101832.png

Generate Cube Map

You also need to Generate Cube Map by right clicking the Viewport and selecting the Generate cube map option. If the option is not visible for you, Activate the layer you put the EnvProbe on and highlight the EnvProbe in the Scene Editor.

image-20240404-171749.png

Debug Overlays

You can access the debug overlays here: View > Settings > Editor Options > Debug > VisualDebug.

 

And EnvProbes: View > Settings > Editor Options > Debug > EnvProbes.

 

 

______________________________________
The Witcher 3: Wild Hunt Complete Edition © 2024 CD PROJEKT S.A. Published by CD PROJEKT S.A. Developed by CD PROJEKT RED. CD PROJEKT®, The Witcher®, REDengine® are registered trademarks of CD PROJEKT Capital Group. All rights reserved. The Witcher game is set in the universe created by Andrzej Sapkowski in his series of books. All rights reserved.