OpenSceneGraph
3.0.1
|
DisplaySettings class for encapsulating what visuals are required and have been set up, and the status of stereo viewing. More...
Public Types | |
enum | DisplayType { MONITOR, POWERWALL, REALITY_CENTER, HEAD_MOUNTED_DISPLAY } |
enum | StereoMode { QUAD_BUFFER, ANAGLYPHIC, HORIZONTAL_SPLIT, VERTICAL_SPLIT, LEFT_EYE, RIGHT_EYE, HORIZONTAL_INTERLACE, VERTICAL_INTERLACE, CHECKERBOARD } |
enum | SplitStereoHorizontalEyeMapping { LEFT_EYE_LEFT_VIEWPORT, LEFT_EYE_RIGHT_VIEWPORT } |
enum | SplitStereoVerticalEyeMapping { LEFT_EYE_TOP_VIEWPORT, LEFT_EYE_BOTTOM_VIEWPORT } |
enum | ImplicitBufferAttachment { IMPLICIT_DEPTH_BUFFER_ATTACHMENT = (1 << 0), IMPLICIT_STENCIL_BUFFER_ATTACHMENT = (1 << 1), IMPLICIT_COLOR_BUFFER_ATTACHMENT = (1 << 2), DEFAULT_IMPLICIT_BUFFER_ATTACHMENT = IMPLICIT_COLOR_BUFFER_ATTACHMENT | IMPLICIT_DEPTH_BUFFER_ATTACHMENT } |
Methods used to set and get defaults for Cameras implicit buffer attachments. More... | |
enum | SwapMethod { SWAP_DEFAULT, SWAP_EXCHANGE, SWAP_COPY, SWAP_UNDEFINED } |
typedef int | ImplicitBufferAttachmentMask |
Public Member Functions | |
DisplaySettings () | |
DisplaySettings (ArgumentParser &arguments) | |
DisplaySettings (const DisplaySettings &vs) | |
DisplaySettings & | operator= (const DisplaySettings &vs) |
void | setDisplaySettings (const DisplaySettings &vs) |
void | merge (const DisplaySettings &vs) |
void | setDefaults () |
void | readEnvironmentalVariables () |
read the environmental variables. | |
void | readCommandLine (ArgumentParser &arguments) |
read the commandline arguments. | |
void | setDisplayType (DisplayType type) |
DisplayType | getDisplayType () const |
void | setStereo (bool on) |
bool | getStereo () const |
void | setStereoMode (StereoMode mode) |
StereoMode | getStereoMode () const |
void | setEyeSeparation (float eyeSeparation) |
float | getEyeSeparation () const |
void | setSplitStereoHorizontalEyeMapping (SplitStereoHorizontalEyeMapping m) |
SplitStereoHorizontalEyeMapping | getSplitStereoHorizontalEyeMapping () const |
void | setSplitStereoHorizontalSeparation (int s) |
int | getSplitStereoHorizontalSeparation () const |
void | setSplitStereoVerticalEyeMapping (SplitStereoVerticalEyeMapping m) |
SplitStereoVerticalEyeMapping | getSplitStereoVerticalEyeMapping () const |
void | setSplitStereoVerticalSeparation (int s) |
int | getSplitStereoVerticalSeparation () const |
void | setSplitStereoAutoAdjustAspectRatio (bool flag) |
bool | getSplitStereoAutoAdjustAspectRatio () const |
void | setScreenWidth (float width) |
float | getScreenWidth () const |
void | setScreenHeight (float height) |
float | getScreenHeight () const |
void | setScreenDistance (float distance) |
float | getScreenDistance () const |
void | setDoubleBuffer (bool flag) |
bool | getDoubleBuffer () const |
void | setRGB (bool flag) |
bool | getRGB () const |
void | setDepthBuffer (bool flag) |
bool | getDepthBuffer () const |
void | setMinimumNumAlphaBits (unsigned int bits) |
unsigned int | getMinimumNumAlphaBits () const |
bool | getAlphaBuffer () const |
void | setMinimumNumStencilBits (unsigned int bits) |
unsigned int | getMinimumNumStencilBits () const |
bool | getStencilBuffer () const |
void | setMinimumNumAccumBits (unsigned int red, unsigned int green, unsigned int blue, unsigned int alpha) |
unsigned int | getMinimumNumAccumRedBits () const |
unsigned int | getMinimumNumAccumGreenBits () const |
unsigned int | getMinimumNumAccumBlueBits () const |
unsigned int | getMinimumNumAccumAlphaBits () const |
bool | getAccumBuffer () const |
void | setMaxNumberOfGraphicsContexts (unsigned int num) |
unsigned int | getMaxNumberOfGraphicsContexts () const |
void | setNumMultiSamples (unsigned int samples) |
unsigned int | getNumMultiSamples () const |
bool | getMultiSamples () const |
void | setCompileContextsHint (bool useCompileContexts) |
bool | getCompileContextsHint () const |
void | setSerializeDrawDispatch (bool serializeDrawDispatch) |
bool | getSerializeDrawDispatch () const |
void | setNumOfDatabaseThreadsHint (unsigned int numThreads) |
Set the hint for the total number of threads in the DatbasePager set up, inclusive of the number of http dedicated threads. | |
unsigned int | getNumOfDatabaseThreadsHint () const |
Get the hint for total number of threads in the DatbasePager set up, inclusive of the number of http dedicated threads. | |
void | setNumOfHttpDatabaseThreadsHint (unsigned int numThreads) |
Set the hint for number of threads in the DatbasePager to dedicate to reading http requests. | |
unsigned int | getNumOfHttpDatabaseThreadsHint () const |
Get the hint for number of threads in the DatbasePager dedicated to reading http requests. | |
void | setApplication (const std::string &application) |
const std::string & | getApplication () |
void | setMaxTexturePoolSize (unsigned int size) |
unsigned int | getMaxTexturePoolSize () const |
void | setMaxBufferObjectPoolSize (unsigned int size) |
unsigned int | getMaxBufferObjectPoolSize () const |
void | setImplicitBufferAttachmentMask (ImplicitBufferAttachmentMask renderMask=DisplaySettings::DEFAULT_IMPLICIT_BUFFER_ATTACHMENT, ImplicitBufferAttachmentMask resolveMask=DisplaySettings::DEFAULT_IMPLICIT_BUFFER_ATTACHMENT) |
void | setImplicitBufferAttachmentRenderMask (ImplicitBufferAttachmentMask implicitBufferAttachmentRenderMask) |
void | setImplicitBufferAttachmentResolveMask (ImplicitBufferAttachmentMask implicitBufferAttachmentResolveMask) |
ImplicitBufferAttachmentMask | getImplicitBufferAttachmentRenderMask () const |
Get mask selecting default implict buffer attachments for Cameras primary FBOs. | |
ImplicitBufferAttachmentMask | getImplicitBufferAttachmentResolveMask () const |
Get mask selecting default implict buffer attachments for Cameras secondary MULTISAMPLE FBOs. | |
void | setSwapMethod (SwapMethod swapMethod) |
Select preferred swap method. | |
SwapMethod | getSwapMethod (void) |
Get preferred swap method. | |
void | setGLContextVersion (const std::string &version) |
Set the hint of which OpenGL version to attempt to create a graphics context for. | |
const std::string | getGLContextVersion () const |
Get the hint of which OpenGL version to attempt to create a graphics context for. | |
void | setGLContextFlags (unsigned int flags) |
Set the hint of the flags to use in when creating graphic contexts. | |
unsigned int | getGLContextFlags () const |
Get the hint of the flags to use in when creating graphic contexts. | |
void | setGLContextProfileMask (unsigned int mask) |
Set the hint of the profile mask to use in when creating graphic contexts. | |
unsigned int | getGLContextProfileMask () const |
Get the hint of the profile mask to use in when creating graphic contexts. | |
Static Public Member Functions | |
static ref_ptr< DisplaySettings > & | instance () |
Maintain a DisplaySettings singleton for objects to query at runtime. | |
Protected Member Functions | |
virtual | ~DisplaySettings () |
Protected Attributes | |
DisplayType | _displayType |
bool | _stereo |
StereoMode | _stereoMode |
float | _eyeSeparation |
float | _screenWidth |
float | _screenHeight |
float | _screenDistance |
SplitStereoHorizontalEyeMapping | _splitStereoHorizontalEyeMapping |
int | _splitStereoHorizontalSeparation |
SplitStereoVerticalEyeMapping | _splitStereoVerticalEyeMapping |
int | _splitStereoVerticalSeparation |
bool | _splitStereoAutoAdjustAspectRatio |
bool | _doubleBuffer |
bool | _RGB |
bool | _depthBuffer |
unsigned int | _minimumNumberAlphaBits |
unsigned int | _minimumNumberStencilBits |
unsigned int | _minimumNumberAccumRedBits |
unsigned int | _minimumNumberAccumGreenBits |
unsigned int | _minimumNumberAccumBlueBits |
unsigned int | _minimumNumberAccumAlphaBits |
unsigned int | _maxNumOfGraphicsContexts |
unsigned int | _numMultiSamples |
bool | _compileContextsHint |
bool | _serializeDrawDispatch |
unsigned int | _numDatabaseThreadsHint |
unsigned int | _numHttpDatabaseThreadsHint |
std::string | _application |
unsigned int | _maxTexturePoolSize |
unsigned int | _maxBufferObjectPoolSize |
ImplicitBufferAttachmentMask | _implicitBufferAttachmentRenderMask |
ImplicitBufferAttachmentMask | _implicitBufferAttachmentResolveMask |
std::string | _glContextVersion |
unsigned int | _glContextFlags |
unsigned int | _glContextProfileMask |
SwapMethod | _swapMethod |
DisplaySettings class for encapsulating what visuals are required and have been set up, and the status of stereo viewing.
Methods used to set and get defaults for Cameras implicit buffer attachments.
For more info: See description of Camera::setImplicitBufferAttachment method
DisplaySettings implicit buffer attachment selection defaults to: DEPTH and COLOR for both primary (Render) FBO and seconday Multisample (Resolve) FBO ie: IMPLICT_DEPTH_BUFFER_ATTACHMENT | IMPLICIT_COLOR_BUFFER_ATTACHMENT
osg::DisplaySettings::DisplaySettings | ( | ) | [inline] |
osg::DisplaySettings::DisplaySettings | ( | ArgumentParser & | arguments | ) | [inline] |
References osgDB::readCommandLine().
osg::DisplaySettings::DisplaySettings | ( | const DisplaySettings & | vs | ) |
virtual osg::DisplaySettings::~DisplaySettings | ( | ) | [protected, virtual] |
bool osg::DisplaySettings::getAccumBuffer | ( | ) | const [inline] |
bool osg::DisplaySettings::getAlphaBuffer | ( | ) | const [inline] |
const std::string& osg::DisplaySettings::getApplication | ( | ) | [inline] |
bool osg::DisplaySettings::getCompileContextsHint | ( | ) | const [inline] |
bool osg::DisplaySettings::getDepthBuffer | ( | ) | const [inline] |
DisplayType osg::DisplaySettings::getDisplayType | ( | ) | const [inline] |
bool osg::DisplaySettings::getDoubleBuffer | ( | ) | const [inline] |
float osg::DisplaySettings::getEyeSeparation | ( | ) | const [inline] |
unsigned int osg::DisplaySettings::getGLContextFlags | ( | ) | const [inline] |
Get the hint of the flags to use in when creating graphic contexts.
unsigned int osg::DisplaySettings::getGLContextProfileMask | ( | ) | const [inline] |
Get the hint of the profile mask to use in when creating graphic contexts.
const std::string osg::DisplaySettings::getGLContextVersion | ( | ) | const [inline] |
Get the hint of which OpenGL version to attempt to create a graphics context for.
ImplicitBufferAttachmentMask osg::DisplaySettings::getImplicitBufferAttachmentRenderMask | ( | ) | const [inline] |
Get mask selecting default implict buffer attachments for Cameras primary FBOs.
Referenced by osg::Camera::getImplicitBufferAttachmentRenderMask().
ImplicitBufferAttachmentMask osg::DisplaySettings::getImplicitBufferAttachmentResolveMask | ( | ) | const [inline] |
Get mask selecting default implict buffer attachments for Cameras secondary MULTISAMPLE FBOs.
Referenced by osg::Camera::getImplicitBufferAttachmentResolveMask().
unsigned int osg::DisplaySettings::getMaxBufferObjectPoolSize | ( | ) | const [inline] |
unsigned int osg::DisplaySettings::getMaxNumberOfGraphicsContexts | ( | ) | const |
unsigned int osg::DisplaySettings::getMaxTexturePoolSize | ( | ) | const [inline] |
unsigned int osg::DisplaySettings::getMinimumNumAccumAlphaBits | ( | ) | const [inline] |
unsigned int osg::DisplaySettings::getMinimumNumAccumBlueBits | ( | ) | const [inline] |
unsigned int osg::DisplaySettings::getMinimumNumAccumGreenBits | ( | ) | const [inline] |
unsigned int osg::DisplaySettings::getMinimumNumAccumRedBits | ( | ) | const [inline] |
unsigned int osg::DisplaySettings::getMinimumNumAlphaBits | ( | ) | const [inline] |
unsigned int osg::DisplaySettings::getMinimumNumStencilBits | ( | ) | const [inline] |
bool osg::DisplaySettings::getMultiSamples | ( | ) | const [inline] |
unsigned int osg::DisplaySettings::getNumMultiSamples | ( | ) | const [inline] |
unsigned int osg::DisplaySettings::getNumOfDatabaseThreadsHint | ( | ) | const [inline] |
Get the hint for total number of threads in the DatbasePager set up, inclusive of the number of http dedicated threads.
unsigned int osg::DisplaySettings::getNumOfHttpDatabaseThreadsHint | ( | ) | const [inline] |
Get the hint for number of threads in the DatbasePager dedicated to reading http requests.
bool osg::DisplaySettings::getRGB | ( | ) | const [inline] |
float osg::DisplaySettings::getScreenDistance | ( | ) | const [inline] |
float osg::DisplaySettings::getScreenHeight | ( | ) | const [inline] |
float osg::DisplaySettings::getScreenWidth | ( | ) | const [inline] |
bool osg::DisplaySettings::getSerializeDrawDispatch | ( | ) | const [inline] |
bool osg::DisplaySettings::getSplitStereoAutoAdjustAspectRatio | ( | ) | const [inline] |
SplitStereoHorizontalEyeMapping osg::DisplaySettings::getSplitStereoHorizontalEyeMapping | ( | ) | const [inline] |
int osg::DisplaySettings::getSplitStereoHorizontalSeparation | ( | ) | const [inline] |
SplitStereoVerticalEyeMapping osg::DisplaySettings::getSplitStereoVerticalEyeMapping | ( | ) | const [inline] |
int osg::DisplaySettings::getSplitStereoVerticalSeparation | ( | ) | const [inline] |
bool osg::DisplaySettings::getStencilBuffer | ( | ) | const [inline] |
bool osg::DisplaySettings::getStereo | ( | ) | const [inline] |
StereoMode osg::DisplaySettings::getStereoMode | ( | ) | const [inline] |
SwapMethod osg::DisplaySettings::getSwapMethod | ( | void | ) | [inline] |
Get preferred swap method.
static ref_ptr<DisplaySettings>& osg::DisplaySettings::instance | ( | ) | [static] |
Maintain a DisplaySettings singleton for objects to query at runtime.
Referenced by osg::Camera::getImplicitBufferAttachmentRenderMask(), and osg::Camera::getImplicitBufferAttachmentResolveMask().
void osg::DisplaySettings::merge | ( | const DisplaySettings & | vs | ) |
DisplaySettings& osg::DisplaySettings::operator= | ( | const DisplaySettings & | vs | ) |
void osg::DisplaySettings::readCommandLine | ( | ArgumentParser & | arguments | ) |
read the commandline arguments.
void osg::DisplaySettings::readEnvironmentalVariables | ( | ) |
read the environmental variables.
void osg::DisplaySettings::setApplication | ( | const std::string & | application | ) | [inline] |
void osg::DisplaySettings::setCompileContextsHint | ( | bool | useCompileContexts | ) | [inline] |
void osg::DisplaySettings::setDefaults | ( | ) |
void osg::DisplaySettings::setDepthBuffer | ( | bool | flag | ) | [inline] |
void osg::DisplaySettings::setDisplaySettings | ( | const DisplaySettings & | vs | ) |
void osg::DisplaySettings::setDisplayType | ( | DisplayType | type | ) | [inline] |
void osg::DisplaySettings::setDoubleBuffer | ( | bool | flag | ) | [inline] |
void osg::DisplaySettings::setEyeSeparation | ( | float | eyeSeparation | ) | [inline] |
void osg::DisplaySettings::setGLContextFlags | ( | unsigned int | flags | ) | [inline] |
Set the hint of the flags to use in when creating graphic contexts.
void osg::DisplaySettings::setGLContextProfileMask | ( | unsigned int | mask | ) | [inline] |
Set the hint of the profile mask to use in when creating graphic contexts.
void osg::DisplaySettings::setGLContextVersion | ( | const std::string & | version | ) | [inline] |
Set the hint of which OpenGL version to attempt to create a graphics context for.
void osg::DisplaySettings::setImplicitBufferAttachmentMask | ( | ImplicitBufferAttachmentMask | renderMask = DisplaySettings::DEFAULT_IMPLICIT_BUFFER_ATTACHMENT , |
ImplicitBufferAttachmentMask | resolveMask = DisplaySettings::DEFAULT_IMPLICIT_BUFFER_ATTACHMENT |
||
) | [inline] |
void osg::DisplaySettings::setImplicitBufferAttachmentRenderMask | ( | ImplicitBufferAttachmentMask | implicitBufferAttachmentRenderMask | ) | [inline] |
void osg::DisplaySettings::setImplicitBufferAttachmentResolveMask | ( | ImplicitBufferAttachmentMask | implicitBufferAttachmentResolveMask | ) | [inline] |
void osg::DisplaySettings::setMaxBufferObjectPoolSize | ( | unsigned int | size | ) | [inline] |
void osg::DisplaySettings::setMaxNumberOfGraphicsContexts | ( | unsigned int | num | ) |
void osg::DisplaySettings::setMaxTexturePoolSize | ( | unsigned int | size | ) | [inline] |
void osg::DisplaySettings::setMinimumNumAccumBits | ( | unsigned int | red, |
unsigned int | green, | ||
unsigned int | blue, | ||
unsigned int | alpha | ||
) |
void osg::DisplaySettings::setMinimumNumAlphaBits | ( | unsigned int | bits | ) | [inline] |
void osg::DisplaySettings::setMinimumNumStencilBits | ( | unsigned int | bits | ) | [inline] |
void osg::DisplaySettings::setNumMultiSamples | ( | unsigned int | samples | ) | [inline] |
void osg::DisplaySettings::setNumOfDatabaseThreadsHint | ( | unsigned int | numThreads | ) | [inline] |
Set the hint for the total number of threads in the DatbasePager set up, inclusive of the number of http dedicated threads.
void osg::DisplaySettings::setNumOfHttpDatabaseThreadsHint | ( | unsigned int | numThreads | ) | [inline] |
Set the hint for number of threads in the DatbasePager to dedicate to reading http requests.
void osg::DisplaySettings::setRGB | ( | bool | flag | ) | [inline] |
void osg::DisplaySettings::setScreenDistance | ( | float | distance | ) | [inline] |
void osg::DisplaySettings::setScreenHeight | ( | float | height | ) | [inline] |
void osg::DisplaySettings::setScreenWidth | ( | float | width | ) | [inline] |
void osg::DisplaySettings::setSerializeDrawDispatch | ( | bool | serializeDrawDispatch | ) | [inline] |
void osg::DisplaySettings::setSplitStereoAutoAdjustAspectRatio | ( | bool | flag | ) | [inline] |
void osg::DisplaySettings::setSplitStereoHorizontalEyeMapping | ( | SplitStereoHorizontalEyeMapping | m | ) | [inline] |
void osg::DisplaySettings::setSplitStereoHorizontalSeparation | ( | int | s | ) | [inline] |
void osg::DisplaySettings::setSplitStereoVerticalEyeMapping | ( | SplitStereoVerticalEyeMapping | m | ) | [inline] |
void osg::DisplaySettings::setSplitStereoVerticalSeparation | ( | int | s | ) | [inline] |
void osg::DisplaySettings::setStereo | ( | bool | on | ) | [inline] |
void osg::DisplaySettings::setStereoMode | ( | StereoMode | mode | ) | [inline] |
void osg::DisplaySettings::setSwapMethod | ( | SwapMethod | swapMethod | ) | [inline] |
Select preferred swap method.
std::string osg::DisplaySettings::_application [protected] |
bool osg::DisplaySettings::_compileContextsHint [protected] |
bool osg::DisplaySettings::_depthBuffer [protected] |
DisplayType osg::DisplaySettings::_displayType [protected] |
bool osg::DisplaySettings::_doubleBuffer [protected] |
float osg::DisplaySettings::_eyeSeparation [protected] |
unsigned int osg::DisplaySettings::_glContextFlags [protected] |
unsigned int osg::DisplaySettings::_glContextProfileMask [protected] |
std::string osg::DisplaySettings::_glContextVersion [protected] |
unsigned int osg::DisplaySettings::_maxBufferObjectPoolSize [protected] |
unsigned int osg::DisplaySettings::_maxNumOfGraphicsContexts [protected] |
unsigned int osg::DisplaySettings::_maxTexturePoolSize [protected] |
unsigned int osg::DisplaySettings::_minimumNumberAccumAlphaBits [protected] |
unsigned int osg::DisplaySettings::_minimumNumberAccumBlueBits [protected] |
unsigned int osg::DisplaySettings::_minimumNumberAccumGreenBits [protected] |
unsigned int osg::DisplaySettings::_minimumNumberAccumRedBits [protected] |
unsigned int osg::DisplaySettings::_minimumNumberAlphaBits [protected] |
unsigned int osg::DisplaySettings::_minimumNumberStencilBits [protected] |
unsigned int osg::DisplaySettings::_numDatabaseThreadsHint [protected] |
unsigned int osg::DisplaySettings::_numHttpDatabaseThreadsHint [protected] |
unsigned int osg::DisplaySettings::_numMultiSamples [protected] |
bool osg::DisplaySettings::_RGB [protected] |
float osg::DisplaySettings::_screenDistance [protected] |
float osg::DisplaySettings::_screenHeight [protected] |
float osg::DisplaySettings::_screenWidth [protected] |
bool osg::DisplaySettings::_serializeDrawDispatch [protected] |
bool osg::DisplaySettings::_splitStereoAutoAdjustAspectRatio [protected] |
int osg::DisplaySettings::_splitStereoHorizontalSeparation [protected] |
int osg::DisplaySettings::_splitStereoVerticalSeparation [protected] |
bool osg::DisplaySettings::_stereo [protected] |
StereoMode osg::DisplaySettings::_stereoMode [protected] |
SwapMethod osg::DisplaySettings::_swapMethod [protected] |
![]() | Generated at Mon Oct 3 2011 12:39:41 for the OpenSceneGraph by doxygen 1.7.5. |