mirror of
https://github.com/godotengine/godot.git
synced 2025-01-09 11:37:35 +00:00
Merge pull request #2724 from SaracenOne/disable_baked_light_sampling_on_shadeless
Disable baked lighting sampling on shadeless materials.
This commit is contained in:
commit
0fd3e18818
@ -6530,6 +6530,8 @@ void RasterizerGLES2::_render_list_forward(RenderList *p_render_list,const Trans
|
||||
material_shader.set_conditional(MaterialShaderGLES2::ENABLE_AMBIENT_LIGHTMAP,false);
|
||||
material_shader.set_conditional(MaterialShaderGLES2::ENABLE_AMBIENT_DP_SAMPLER,false);
|
||||
|
||||
if (material->flags[VS::MATERIAL_FLAG_UNSHADED] == false && current_debug != VS::SCENARIO_DEBUG_SHADELESS) {
|
||||
|
||||
if (e->instance->sampled_light.is_valid()) {
|
||||
|
||||
SampledLight *sl = sampled_light_owner.get(e->instance->sampled_light);
|
||||
@ -6566,7 +6568,8 @@ void RasterizerGLES2::_render_list_forward(RenderList *p_render_list,const Trans
|
||||
}
|
||||
|
||||
}
|
||||
} else if (baked_light->mode==VS::BAKED_LIGHT_LIGHTMAPS) {
|
||||
}
|
||||
else if (baked_light->mode == VS::BAKED_LIGHT_LIGHTMAPS) {
|
||||
|
||||
|
||||
int lightmap_idx = e->instance->baked_lightmap_id;
|
||||
@ -6606,6 +6609,7 @@ void RasterizerGLES2::_render_list_forward(RenderList *p_render_list,const Trans
|
||||
rebind = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if (sort_flags!=prev_sort_flags) {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user