# osg::Multisample Class Reference

Multisample - encapsulates the OpenGL Multisample state. More...

Inheritance diagram for osg::Multisample:

[legend]
List of all members.

## Public Types

enum | Mode { FASTEST = GL_FASTEST, NICEST = GL_NICEST, DONT_CARE = GL_DONT_CARE }

## Public Member Functions

| Multisample ()
| Multisample (const Multisample &trans, const CopyOp &copyop=CopyOp::SHALLOW_COPY)
| Copy constructor using CopyOp to manage deep vs shallow copy.
| META_StateAttribute (osg, Multisample, MULTISAMPLE)
virtual int | compare (const StateAttribute &sa) const
| return -1 if *this < *rhs, 0 if *this==*rhs, 1 if *this>*rhs.
void | setSampleCoverage (float coverage, bool invert)
float | getCoverage () const
bool | getInvert () const
void | setHint (Mode mode)
virtual void | apply (State &state) const
| apply the OpenGL state attributes.

## Static Public Member Functions

static Extensions * | getExtensions (unsigned int contextID, bool createIfNotInitalized)
| Function to call to get the extension of a specified context.
static void | setExtensions (unsigned int contextID, Extensions *extensions)
| setExtensions allows users to override the extensions across graphics contexts.

## Protected Member Functions

virtual | ~Multisample ()

## Protected Attributes

float | _coverage
bool | _invert
Mode | _mode

## Classes

class | Extensions
| Extensions class which encapsulates the querying of extensions and associated function pointers, and provide convenience wrappers to check for the extensions or use the associated functions. More...

## Detailed Description

Multisample - encapsulates the OpenGL Multisample state.

## Member Enumeration Documentation

enum osg::Multisample::Mode

Enumeration values:

  FASTEST |
  NICEST |
  DONT_CARE |

## Constructor & Destructor Documentation

Multisample::Multisample | ( |  | ) |

osg::Multisample::Multisample | ( | const Multisample & | trans,
|  | const CopyOp & | copyop = `CopyOp::SHALLOW_COPY`
| ) | `[inline]`

| Copy constructor using CopyOp to manage deep vs shallow copy.

Multisample::~Multisample | ( |  | ) | `[protected, virtual]`

## Member Function Documentation

void Multisample::apply | ( | State & | state | ) | const`[virtual]`

| apply the OpenGL state attributes. The global state for the current OpenGL context is passed in to allow the StateAttribute to obtain details on the the current context and state. Implements osg::StateAttribute.

virtual int osg::Multisample::compare | ( | const StateAttribute & | sa | ) | const`[inline, virtual]`

| return -1 if *this < *rhs, 0 if *this==*rhs, 1 if *this>*rhs. Implements osg::StateAttribute.

float osg::Multisample::getCoverage | ( |  | ) | const`[inline]`

Multisample::Extensions * Multisample::getExtensions | ( | unsigned int | contextID,
|  | bool | createIfNotInitalized
| ) | `[static]`

Function to call to get the extension of a specified context.

If the Exentsion object for that context has not yet been created and the 'createIfNotInitalized' flag been set to false then returns NULL. If 'createIfNotInitalized' is true then the Extensions object is automatically created. However, in this case the extension object will only be created with the graphics context associated with ContextID..

bool osg::Multisample::getInvert | ( |  | ) | const`[inline]`

osg::Multisample::META_StateAttribute | ( | osg | ,
|  | Multisample | ,
|  | MULTISAMPLE |
| ) |

void Multisample::setExtensions | ( | unsigned int | contextID,
|  | Extensions * | extensions
| ) | `[static]`

| setExtensions allows users to override the extensions across graphics contexts. Typically used when you have different extensions supported across graphics pipes but need to ensure that they all use the same low common denominator extensions.

void osg::Multisample::setHint | ( | Mode | mode | ) | `[inline]`

void osg::Multisample::setSampleCoverage | ( | float | coverage,
|  | bool | invert
| ) | `[inline]`

## Member Data Documentation

float osg::Multisample::_coverage `[protected]`

bool osg::Multisample::_invert `[protected]`

Mode osg::Multisample::_mode `[protected]`

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

- Multisample
- Multisample.cpp