Sets the state of z-buffering to on or off
| 1729 | |
| 1730 | // Sets the state of z-buffering to on or off |
| 1731 | void rend_SetZBufferState(int8_t state) { |
| 1732 | if (state == gpu_state.cur_zbuffer_state) |
| 1733 | return; // No redundant state setting |
| 1734 | |
| 1735 | OpenGL_sets_this_frame[5]++; |
| 1736 | gpu_state.cur_zbuffer_state = state; |
| 1737 | |
| 1738 | // mprintf(0,"OPENGL: Setting zbuffer state to %d.\n",state); |
| 1739 | |
| 1740 | if (state) { |
| 1741 | dglEnable(GL_DEPTH_TEST); |
| 1742 | dglDepthFunc(GL_LEQUAL); |
| 1743 | } else { |
| 1744 | dglDisable(GL_DEPTH_TEST); |
| 1745 | } |
| 1746 | |
| 1747 | CHECK_ERROR(14) |
| 1748 | } |
| 1749 | |
| 1750 | // Clears the display to a specified color |
| 1751 | void rend_ClearScreen(ddgr_color color) { |
no outgoing calls
no test coverage detected