Developer Documentation

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Modules Pages
Public Member Functions | Private Attributes | List of all members
ACG::QtColorTranslator Class Reference

`#include <ACG/QtWidgets/QtColorTranslator.hh>`

## Public Member Functions
| QtColorTranslator ()
| Default constructor.
| QtColorTranslator (QGLContext &_context)
| construct with QGLcontext
| ~QtColorTranslator ()
| Destructor.
void | initialize ()
| init (takes current QGLcontext)
void | initialize (QGLContext &_context)
| init with given QGLcontext
bool | initialized () const
| has it been initialized?
bool | index2color (unsigned int _idx, QRgb &_col) const
| index -> color (one buffer)
bool | index2color (unsigned int _idx, QRgb &_frontColor, QRgb &_backColor) const
| index -> color (two buffers)
int | color2index (QRgb _c) const
| color -> index (one buffer)
int | color2index (QRgb _frontColor, QRgb _backColor) const
| color -> index (two buffers)
unsigned int | maxIndex () const
| returns max convertable index (using ONE buffer)

## Private Attributes
bool | initialized_
GLint | redBits_
GLint | greenBits_
GLint | blueBits_
GLuint | redMask_
GLuint | greenMask_
GLuint | blueMask_
GLuint | redShift_
GLuint | greenShift_
GLuint | blueShift_
GLuint | redRound_
GLuint | greenRound_
GLuint | blueRound_

## Detailed Description

This class translates index <-> RGB color.

The QtColorTranslator is attached to a QGLContext and translates index to color and vice versa. If the RGB bits of one buffer are not sufficient, both front and back buffer can be used.

Definition at line 86 of file QtColorTranslator.hh.

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

- ACG/QtWidgets/QtColorTranslator.hh
- ACG/QtWidgets/QtColorTranslator.cc