Results 1 to 2 of 2

Thread: Depth buffer question

  1. #1

    Depth buffer question

    How do you disable writes to the depth buffer so that things are still dependent upon the depth buffer to be drawn, but don't draw themselves into it? I've seen this discussed before, but I couldn't be sure as to how it was done.


  2. #2
    Senior Member Regular Contributor
    Join Date
    May 2001
    London UK

    Re: Depth buffer question

    To control whether the depth buffer is writable, use glDepthMask(); if you pass GL_FALSE as the argument, the buffer becomes read-only, whereas GL_TRUE restores the normal, writable operation.

Similar Threads

  1. Depth buffer / depth test question
    By openglbeginner123 in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 12-14-2014, 05:13 PM
  2. question on z-buffer depth test algorithm
    By michael2212 in forum OpenGL: General
    Replies: 2
    Last Post: 02-27-2012, 08:46 AM
  3. Noobie Question: Depth buffer setup
    By coder2010 in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 03-01-2010, 07:32 PM
    By zadeh79 in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 02-24-2007, 02:38 PM
  5. Depth Buffer Question
    By in forum OpenGL: macOS
    Replies: 1
    Last Post: 09-21-2005, 10:38 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Proudly hosted by Digital Ocean