Fix LightmapGI not taking environment sky rotation into account when baking
The sky rotation now affects the baked environment lighting as it should,
making it match how real-time ambient light rendering works.
Co-authored-by: Per Melin <git@melin.net>
(cherry picked from commit 661cf1f351)
This commit is contained in:
committed by
Rémi Verschelde
parent
a7756d530e
commit
6595395b8b
@ -1072,6 +1072,7 @@ LightmapGI::BakeError LightmapGI::bake(Node *p_from_node, String p_image_data_pa
|
||||
|
||||
if (env.is_valid()) {
|
||||
environment_image = RS::get_singleton()->environment_bake_panorama(env->get_rid(), true, Size2i(128, 64));
|
||||
environment_transform = Basis::from_euler(env->get_sky_rotation()).inverse();
|
||||
}
|
||||
}
|
||||
} break;
|
||||
|
||||
Reference in New Issue
Block a user