From 6b2958cad3dc168c2e8c52ef36e66a89dc78e801 Mon Sep 17 00:00:00 2001 From: ExMix Date: Tue, 5 Aug 2014 12:31:56 +0300 Subject: [PATCH] [drape] new clear depth buffer function --- drape/glfunctions.cpp | 6 ++++++ drape/glfunctions.hpp | 1 + 2 files changed, 7 insertions(+) diff --git a/drape/glfunctions.cpp b/drape/glfunctions.cpp index 3e1a694176..4134430756 100644 --- a/drape/glfunctions.cpp +++ b/drape/glfunctions.cpp @@ -194,6 +194,12 @@ void GLFunctions::glClear() GLCHECK(glClearFn(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT)); } +void GLFunctions::glClearDepth() +{ + ASSERT(glClearFn != NULL, ()); + GLCHECK(glClearFn(GL_DEPTH_BUFFER_BIT)); +} + void GLFunctions::glViewport(uint32_t x, uint32_t y, uint32_t w, uint32_t h) { ASSERT(glViewportFn != NULL, ()); diff --git a/drape/glfunctions.hpp b/drape/glfunctions.hpp index 3046224d59..9c0cbff0f5 100644 --- a/drape/glfunctions.hpp +++ b/drape/glfunctions.hpp @@ -11,6 +11,7 @@ public: static bool glHasExtension(string const & name); static void glClearColor(float r, float g, float b, float a); static void glClear(); + static void glClearDepth(); static void glViewport(uint32_t x, uint32_t y, uint32_t w, uint32_t h); static void glFlush();