diff options
author | Jean-Patrick Guerrero <kilbith@users.noreply.github.com> | 2021-03-16 23:28:16 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-16 23:28:16 +0100 |
commit | 285ba74723695c4b51192dac0e1e17c5d8f880db (patch) | |
tree | 5b6147a093f28d01d7a6b9da40770e2c434b1641 /src/client | |
parent | 66b5c086644ac18845731d6f3556d9e7cde4ee28 (diff) | |
download | minetest-285ba74723695c4b51192dac0e1e17c5d8f880db.tar.gz minetest-285ba74723695c4b51192dac0e1e17c5d8f880db.tar.bz2 minetest-285ba74723695c4b51192dac0e1e17c5d8f880db.zip |
GUIScene: Clear depth buffer + replace deprecated clearZBuffer calls
Diffstat (limited to 'src/client')
-rw-r--r-- | src/client/camera.cpp | 2 | ||||
-rw-r--r-- | src/client/hud.cpp | 2 | ||||
-rw-r--r-- | src/client/render/anaglyph.cpp | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/src/client/camera.cpp b/src/client/camera.cpp index 350b685e1..5158d0dd1 100644 --- a/src/client/camera.cpp +++ b/src/client/camera.cpp @@ -664,7 +664,7 @@ void Camera::wield(const ItemStack &item) void Camera::drawWieldedTool(irr::core::matrix4* translation) { // Clear Z buffer so that the wielded tool stays in front of world geometry - m_wieldmgr->getVideoDriver()->clearZBuffer(); + m_wieldmgr->getVideoDriver()->clearBuffers(video::ECBF_DEPTH); // Draw the wielded node (in a separate scene manager) scene::ICameraSceneNode* cam = m_wieldmgr->getActiveCamera(); diff --git a/src/client/hud.cpp b/src/client/hud.cpp index 46736b325..74c1828e3 100644 --- a/src/client/hud.cpp +++ b/src/client/hud.cpp @@ -950,7 +950,7 @@ void drawItemStack( if (imesh && imesh->mesh) { scene::IMesh *mesh = imesh->mesh; - driver->clearZBuffer(); + driver->clearBuffers(video::ECBF_DEPTH); s32 delta = 0; if (rotation_kind < IT_ROT_NONE) { MeshTimeInfo &ti = rotation_time_infos[rotation_kind]; diff --git a/src/client/render/anaglyph.cpp b/src/client/render/anaglyph.cpp index 9ba4464a2..153e77400 100644 --- a/src/client/render/anaglyph.cpp +++ b/src/client/render/anaglyph.cpp @@ -40,7 +40,7 @@ void RenderingCoreAnaglyph::setupMaterial(int color_mask) void RenderingCoreAnaglyph::useEye(bool right) { RenderingCoreStereo::useEye(right); - driver->clearZBuffer(); + driver->clearBuffers(video::ECBF_DEPTH); setupMaterial(right ? video::ECP_GREEN | video::ECP_BLUE : video::ECP_RED); } |