mirror of https://github.com/axmolengine/axmol.git
Merge pull request #13635 from super626/v3.8
Enable depth write for transparent object
This commit is contained in:
commit
7f04a191c7
|
@ -350,9 +350,9 @@ void Mesh::draw(Renderer* renderer, float globalZOrder, const Mat4& transform, u
|
||||||
flags);
|
flags);
|
||||||
|
|
||||||
|
|
||||||
if (isTransparent && !forceDepthWrite)
|
// if (isTransparent && !forceDepthWrite)
|
||||||
_material->getStateBlock()->setDepthWrite(false);
|
// _material->getStateBlock()->setDepthWrite(false);
|
||||||
else
|
// else
|
||||||
_material->getStateBlock()->setDepthWrite(true);
|
_material->getStateBlock()->setDepthWrite(true);
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue