Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
A current known issue is that you need to set the
English

Overview

With Environment Probes you have the ability to place cubemaps easily throughout a level just as you would a light. It is very useful especially with reflective materials because it will automatically assign the cubemap to anything within its radius.

This tool can be useful when used with dynamic lighting as well; it just requires a minor Flow Graph setup so that the different probes used in different situations will transition smoothly.One thing the user should keep in mind though is to not have too many probes an overlap their radii because this will cause overdraw and

increase rendering timeWith the introduction of Physically Based Shading in CRYENGINE 3.6 cubemaps control many things in the engine now. Everything from Shadow colors, ambient diffuse values, particle diffuse, and reflections. They act as bounce lighting by taking the colors from the surroundings and applying them directly into the diffuse of materials inside their radius.

Table of Contents
maxLevel3
minLevel2
excludeOverview

Setup

Having loaded a level in Sandbox, select from the RollupBar the Objects -> Misc -> Environment Probe.

After selecting the ' Environment Probe', move your cursor into the view port to position and place the 'Environment Probe' into your level. You can adjust the location the same as with any entity.

Info

With the new tile shading in CRYENGINE all cubemaps must be at resolution of 256. The image generated is a floating point HDR image and has a much higher fidelity than previously.

Cubemap Generation

The texture file name will always change to the name of the Environment Probe entity. So it is a good idea to name your probe right away before you start generating anything. When you generate you will get get back 2 textures. one will be the diffuse bounce lighting information and the other is the reflection map.

On the RollupBar, you see the entity options and 'Probe Functions' panel. Click the Generate Cubemap button.

This will generate a Tif cubemap image in: Textures\cubemaps\<Level Directory><LevelDirectory>\<EnvironmentProbeName_cm>.tif

Tip

Global CM Probes

CRYENGINE also supports a "Global" approach to cubemaps. If you set the Radius of the Environment Probe entity to 100000 (one hundred thousand) then the ambient of the cubemap will be merged with the normal ambient pass. This is an optimization effort and makes it cheaper to render than a regular local cubemap. In addition, the ambient of the cubemap will be added on top of the normal ambient, rather than overwriting the ambient locally.

Having a "Global"

Generally, the environment probe should be placed at head height to generate proper reflections.

Global Cubemap Probes

Every level should have a Global cubemap to start with. This is a special cubemap that acts as the default/fallback. Generally you only need one Global cube map per level.

Having a Global probe in your level ensures that you will always have an active cubemap available for reflective surfaces. Any "local" probes will automatically sort as a higher priority within its defined radius and blend in over the top of the "Global" probe.

Setting a cubemap to be a Global cubemap requires just a few special settings:

  • Ensure that it covers the entire level by setting the BoxSizeXYZ values high enough.
  • Set the SortPriority to 0.
  • Set AttenuationFalloffMax to 0.
  • Set IgnoreVisAreas to true.

Image Added

Environment Probe Properties

Image Removed
Property e.g. 256 = 256x256 pixels per face. This will give you real time feedback of the cubemap that has been saved to diskProperty
Image Added

EnvironmentProbe Params

 

Description

cubemap_resolution

This allows you to tweak the resolution of the generated cubemap to ensure a good balance between quality and memory usage.


Note that since CRYENGINE 3.6, the Physically Based Shading model has been tuned for 256px cubemaps and this resolution is enforced.
An additional option introduced here is "skip update" which sets this Probe to not update it's cubemap texture.

preview_cubemap

Toggle this on and off to see the probe change to a default sphere with the cubemap applied and rendered

.

Probe Functions

 

Description

Generate Cubemap

Generates a cubemap for the currently selected Environment Probe.

Generate All Cubemaps

Generates a cubemap for each Environment Probe placed in the current level.
The intention of this is to make the updating process for all Environment Probes automated.

EnvironmentProbe Properties

Property

Description


Active

Turns the entity on/off.

RadiusBoxSizeXYZ

Specifies how far from the source the light affects the surroundingthe XYZ dimensions of the Environment Probes area of effect.
Probes are now projected in Box fashion rather than Spherical fashion for better flexibility with level setups.

Color

 

Diffuse

The diffuse color of the light can be specified here.

DiffuseMultiplier

To make the light brighter this diffuse multiplier can be used.

HDRDynamic

Specifies how much brighter than the default 256,256,256 white the light is. (sunlight set in the time of day window is for example 3 times brighter).

SpecularMultiplier

Multiplies the specular color brighter, use to adjust brightness.

Options

 

AffectThisAreaOnly

Set this parameter to false to make lights other visarea.deferred_ClipBounds

AttenuationFalloffMax

Controls the falloff amount (0 - 1) to create smoother transitions or hard-edges which can be useful in interior lighting.

DeferredClipBounds

Specifies that the light is linked to a light box or light area and to use the volume of the target area for clipping. See: Light Boxes and Light Shapes.

IgnoresVisAreas

Controls whether the light should respond to visareas.

SortPriority

Gives control over which Probe should be a higher priority.
With two probes in the same area, the probe with the higher sort priority will be rendered on top.

OptionsAdvanced

 

deferred_cubemap

Specifies the location of the cubemap texture.

Projection

 

BoxHeight

Adjusts the height of cubemap box.

BoxLength

Adjusts the length of cubemap box.

BoxProject

Needs to be checked in order to be enabled and once done; the size of the box will need to be taken into consideration.

BoxWidth

Adjusts the width of cubemap box.

Note
titleBox Dimensions

box

dimensions to half the size of the room. This has been fixed since CryENGINE 3

.

5.3.

Tweaking Environment Probes

High reflective materials are suggested to be used in conjunction with SSR (Screen Space Reflections) as it will provide localized real-time reflections.

No SSR and no Environment Probe.

The following example was put together using a box projection method SSR with Environment Probe. Notice how the grid is accurately aligned with the shapes. When modifying your box projection be aware that a bounding green bounding box appears and to tweak the size accordingly.

This screen has SSR with no Environment Probe enabled. Notice the localized reflections located around edges and corners.

No SSR with BoxProject enabled Environment Probe aligned with the size of the room.

SSR with spherical Environment Probe. This aspect is not as accurate but in less reflective areas this option may be easier to use.

Things to Consider

  • If the cubemap preview renders completely black apart from specular it's likely that the 'Config Spec' for Sandbox is set to low. Try a higher config spec.
  • The environment probes automatically create a 'Deferred Cubemap Light' with the cubemap applied to it so you don't need to set anything else up to have these working in your levels.

    Chinese

    创建环境探针

    在 Sandbox 中加载关卡后,从 Rollup 栏选择*对象 -> 杂项 -> 环境探针*。

    选中“环境探针”后,将光标移至视区,以便将“环境探针”放置在您的关卡中。对于任何实体,您都可以相同的方法调整位置。

    在 Rollup 栏,您可看到实体选项和“探针功能”窗格。单击*生成立方体贴图*按钮。此操作将在:{{Textures\cubemaps\<Level Directory>\<EnvironmentProbeName_cm>.tif}}中生成 Tiff 立方体贴图图像

    “探针功能”窗格

    “探针功能”窗格上有两个按钮:

    生成立方体贴图:为当前选中的环境探针生成立方体贴图。
    生成所有立方体贴图:为放在当前关卡中每个环境探针生成立方体贴图。此操作的目的是让所有环境探针的更新过程自动化。

    “环境探针参数”

    在环境探针参数中您可为环境探针优化两个特定的选项:

    需要注意的事项

    如果立方体贴图除高光外全部渲染成黑色,则可能是 Sandbox 的“配置规格”设置过低。请尝试将“配置规格”调高。

    立方体贴图光照

    环境探针自动创建应用于立方体贴图的“立方体贴图延迟光照”,并在您的关卡中运行,所以您无需再另外设置。