mirror of
https://github.com/luanti-org/luanti.git
synced 2025-08-01 17:38:41 +00:00
Refactor the way you set material properties
Instead of using SMaterial::setFlag, you now set them directly on SMaterial or SMaterialLayer.
This commit is contained in:
parent
128d22e6ee
commit
307e380f30
15 changed files with 202 additions and 171 deletions
|
@ -1125,9 +1125,9 @@ core::array<scene::ISceneNode*> CGUITTFont::addTextSceneNode(const wchar_t* text
|
|||
|
||||
// the default font material
|
||||
SMaterial mat;
|
||||
mat.setFlag(video::EMF_LIGHTING, true);
|
||||
mat.setFlag(video::EMF_ZWRITE_ENABLE, false);
|
||||
mat.setFlag(video::EMF_NORMALIZE_NORMALS, true);
|
||||
mat.Lighting = true;
|
||||
mat.ZWriteEnable = video::EZW_OFF;
|
||||
mat.NormalizeNormals = true;
|
||||
mat.ColorMaterial = video::ECM_NONE;
|
||||
mat.MaterialType = use_transparency ? video::EMT_TRANSPARENT_ALPHA_CHANNEL : video::EMT_SOLID;
|
||||
mat.MaterialTypeParam = 0.01f;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue