SmallChange  1.0.0
A collection of extensions to Coin3D
Loading...
Searching...
No Matches
SmDepthBuffer Class Reference

The SmDepthBuffer class is a node used to control the GL depth buffer. More...

#include <SmDepthBuffer.h>

Inheritance diagram for SmDepthBuffer:
SoNode

Public Types

enum  Func {
  NEVER = GLDepthBufferElement::NEVER , ALWAYS = GLDepthBufferElement::ALWAYS , LESS = GLDepthBufferElement::LESS , LEQUAL = GLDepthBufferElement::LEQUAL ,
  EQUAL = GLDepthBufferElement::EQUAL , GEQUAL = GLDepthBufferElement::GEQUAL , GREATER = GLDepthBufferElement::GREATER , NOTEQUAL = GLDepthBufferElement::NOTEQUAL
}
 

Public Member Functions

 SmDepthBuffer (void)
 
virtual void GLRender (SoGLRenderAction *action)
 

Static Public Member Functions

static void initClass (void)
 

Public Attributes

SoSFBool clearNow
 
SoSFBool enable
 
SoSFEnum func
 

Protected Member Functions

virtual ~SmDepthBuffer ()
 

Detailed Description

The SmDepthBuffer class is a node used to control the GL depth buffer.

It is basically a direct mapping of glDepthFunc(). In addition it is possible to enable/disable depth buffer and clear the depth buffer when the node is traversed.

Member Enumeration Documentation

◆ Func

Enumeration for the various depth functions.

Enumerator
NEVER 

Never passes.

ALWAYS 

Always passes.

LESS 

Passes if the incoming depth value is less than the stored depth value.

LEQUAL 

Passes if the incoming depth value is less than or equal to the stored depth value.

EQUAL 

Passes if the incoming depth value is equal to the stored depth value.

GEQUAL 

Passes if the incoming depth value is greater than or equal to the stored depth value.

GREATER 

Passes if the incoming depth value is greater than the stored depth value.

NOTEQUAL 

Passes if the incoming depth value is not equal to the stored depth value.

Constructor & Destructor Documentation

◆ SmDepthBuffer()

SmDepthBuffer::SmDepthBuffer ( void )

Constructor.

◆ ~SmDepthBuffer()

SmDepthBuffer::~SmDepthBuffer ( )
protectedvirtual

Destructor.

Member Function Documentation

◆ GLRender()

void SmDepthBuffer::GLRender ( SoGLRenderAction * action)
virtual

Coin method.

◆ initClass()

void SmDepthBuffer::initClass ( void )
static

Required Coin method.

Member Data Documentation

◆ clearNow

SoSFFloat SmDepthBuffer::clearNow

If TRUE, clear buffer when node is traversed. Default is FALSE.

◆ enable

SoSFBool SmDepthBuffer::enable

Enable depth buffer writes. Defaults to TRUE.

◆ func

SoSFEnum SmDepthBuffer::func

Which depth function to use. Defaults to LESS.


The documentation for this class was generated from the following files: