Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   Related Pages  

sglDithering Class Reference

#include <sglStatelet.hpp>

Inheritance diagram for sglDithering::

sglBooleanStatelet sglStatelet sglObject List of all members.

Public Methods

 sglDithering (bool on=true)
virtual ~sglDithering ()
void apply (sglCurrState *curr_state) const

Detailed Description

This statelet encapsulates OpenGL's glEnable(GL_DITHER) functionality, which determines whether or not dithering is desired to increase the number of apparent colors on graphics hardware. This is enabled by default (as it is in OpenGL.


   sglDithering *dither = new sglDithering(false);     // disable it
   dither->enable(true);                               // enable it

Definition at line 1048 of file sglStatelet.hpp.

Constructor & Destructor Documentation

sglDithering::sglDithering ( bool on = true ) [inline]

Constructor (also default constructor).

on   True to enable dithering (the default); false to disable.

Definition at line 1054 of file sglStatelet.hpp.

sglDithering::~sglDithering ( ) [inline, virtual]

virtual destructor.

Definition at line 1058 of file sglStatelet.hpp.

Member Function Documentation

void sglDithering::apply ( sglCurrState * curr_state ) const [virtual]

Apply this state change to the current rendering state.

curr_state   Required for statelets that affect one another. For example the sglTransparency sets up depth mask and blending modes which interact with the sglBlending and sglDepthMask statelets, and the curr_state object is used to resolve these internal issues.

Reimplemented from sglStatelet.

The documentation for this class was generated from the following file:
Generated at Mon Jul 1 18:00:07 2002 for SGL by doxygen1.2.6 written by Dimitri van Heesch, © 1997-2001