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

Basic model shading (#9374)

This commit is contained in:
Danila Shutov 2020-02-16 22:37:28 +03:00 committed by GitHub
parent 478e753298
commit 6958071f49
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
9 changed files with 338 additions and 41 deletions

View file

@ -188,7 +188,7 @@ public:
delete setter;
}
virtual void OnSetConstants(video::IMaterialRendererServices *services, s32 userData)
virtual void OnSetConstants(video::IMaterialRendererServices *services, s32 userData) override
{
video::IVideoDriver *driver = services->getVideoDriver();
sanity_check(driver != NULL);
@ -198,6 +198,12 @@ public:
for (IShaderConstantSetter *setter : m_setters)
setter->onSetConstants(services, is_highlevel);
}
virtual void OnSetMaterial(const video::SMaterial& material) override
{
for (IShaderConstantSetter *setter : m_setters)
setter->onSetMaterial(material);
}
};