Attention: Here be dragons
This is the latest
(unstable) version of this documentation, which may document features
not available in or compatible with released stable versions of Godot.
Checking the stable version of the documentation...
WorldEnvironment
整个场景的默认环境属性,后期处理效果、照明和背景设置。
描述
WorldEnvironment 节点用于为场景配置默认的 Environment。
WorldEnvironment 中定义的参数可以被设置为当前的 Camera3D 上所设置的 Environment 资源覆盖。此外,在一个给定场景中,同一时间只能实例化一个 WorldEnvironment。
WorldEnvironment 允许用户指定默认的照明参数(例如环境照明)、各种后处理效果(例如 SSAO、DOF、色调映射)、以及如何绘制背景(例如纯色、天空盒)。通常,添加这些是为了提高场景的真实感/色彩平衡。
教程
属性
属性说明
CameraAttributes camera_attributes 🔗
void set_camera_attributes(value: CameraAttributes)
CameraAttributes get_camera_attributes()
Camera3D 上未设置时 CameraAttributes 时默认使用的资源。
Compositor compositor 🔗
void set_compositor(value: Compositor)
Compositor get_compositor()
Camera3D 上未设置时要使用的默认 Compositor 资源。
Environment environment 🔗
void set_environment(value: Environment)
Environment get_environment()
此 WorldEnvironment 世界环境所使用的 Environment 环境资源,定义默认属性。