rtx: do not treat SURF_SKY as light source, fix #232

This commit is contained in:
Ivan Avdeev 2021-11-27 19:40:58 -08:00 committed by Ivan Avdeev
parent ecaac9d4c7
commit a394038f22

View File

@ -604,7 +604,7 @@ void VK_LightsAddEmissiveSurface( const struct vk_render_geometry_s *geom, const
if (!geom->surf)
goto fin; // TODO break? no surface means that model is not brush
if (geom->material != kXVkMaterialSky && geom->material != kXVkMaterialEmissive && !g_lights.map.emissive_textures[texture_num].set)
if (/* geom->material != kXVkMaterialSky && */geom->material != kXVkMaterialEmissive && !g_lights.map.emissive_textures[texture_num].set)
goto fin;
if (g_lights.num_emissive_surfaces >= 256)
@ -634,7 +634,7 @@ void VK_LightsAddEmissiveSurface( const struct vk_render_geometry_s *geom, const
// Insert into emissive surfaces
esurf->kusok_index = geom->kusok_index;
if (geom->material != kXVkMaterialSky && geom->material != kXVkMaterialEmissive) {
if (/* geom->material != kXVkMaterialSky && */geom->material != kXVkMaterialEmissive) {
VectorCopy(g_lights.map.emissive_textures[texture_num].emissive, esurf->emissive);
} else {
// TODO see #227