1
0
Fork 0
mirror of https://github.com/luanti-org/luanti.git synced 2025-06-27 16:36:03 +00:00

Improvements to colored shadows (#11516)

This commit is contained in:
x2048 2021-10-01 16:21:53 +02:00 committed by GitHub
parent 21113ad410
commit 982e03f60d
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 29 additions and 5 deletions

View file

@ -461,7 +461,10 @@ void ClientMap::renderMap(video::IVideoDriver* driver, s32 pass)
layer.Texture = shadow->get_texture();
layer.TextureWrapU = video::E_TEXTURE_CLAMP::ETC_CLAMP_TO_EDGE;
layer.TextureWrapV = video::E_TEXTURE_CLAMP::ETC_CLAMP_TO_EDGE;
layer.TrilinearFilter = true;
// Do not enable filter on shadow texture to avoid visual artifacts
// with colored shadows.
// Filtering is done in shader code anyway
layer.TrilinearFilter = false;
}
driver->setMaterial(material);
++material_swaps;