Open Inventor Release 2024.1.2
 
Loading...
Searching...
No Matches
SoGLDeviceSettings Class Referenceabstract

VSG extension Device settings management class More...

#include <Inventor/devices/SoGLDeviceSettings.h>

Public Member Functions

virtual int getParameterCount () const =0
 Returns number of parameters in current setting.
 
virtual SbString getParameterIdbyIndex (const unsigned int index) const =0
 Returns the name of the parameter with the specified index in the current setting.
 
virtual SbString getParameter (const SbString &pParameterId) const =0
 Returns current value of specified parameter in current setting.
 
virtual bool setParameter (const SbString &pParameterId, const SbString &pParameterValue)=0
 Set the value of a parameter in the current setting.
 
virtual SbString getSettingName () const =0
 Returns the name of the current setting (vendor defined list of parameters).
 
virtual bool setSettingName (const SbString &pPredefinedSettingName)=0
 Set a setting (vendor defined list of parameters) by name.
 
virtual int getSettingsCount () const =0
 Returns the number of vendor defined settings.
 
virtual SbString getSettingNameByIndex (const unsigned int index) const =0
 Returns the name of the specified setting.
 
virtual bool applySettings () const =0
 Apply changes to the setting and/or parameters.
 

Static Public Member Functions

static void initClass ()
 Initializes SoDeviceSettings.
 
static void exitClass ()
 Cleans SoDeviceSettings.
 

Friends

std::ostream & operator<< (std::ostream &os, const SoGLDeviceSettings &profile)
 Prints information about the device settings.
 

Detailed Description

VSG extension Device settings management class

This class provides functions to query and modify information about OpenGL device settings. A setting is a vendor defined collection of device dependent parameters like "Stereo - Enable", "Antialiasing ? Mode" or "Vertical Sync". NVIDIA calls this a "driver profile". Parameters can be set as a group using setSettingName(), with a predefined name, or one by one using setParameter().

Applications should only create an SoDeviceSettings object using the SoGLDevice method getDeviceSettings() (see below).

Device settings should be changed before any rendering is done, i.e. before the OpenGL render context is created.

Setting and parameter changes do not take effect until applySettings() is called.

Changes should only affect the current running application (but this may depend on the graphics board vendor and driver installed).

The settings and parameters that can be queried through this interface may not correspond to the parameters displayed by the graphics board vendor's "control panel" application. This depends on the vendor and the driver installed.

EXAMPLE

SEE ALSO

SoGLDevice

Definition at line 97 of file SoGLDeviceSettings.h.

Member Function Documentation

◆ applySettings()

virtual bool SoGLDeviceSettings::applySettings ( ) const
pure virtual

Apply changes to the setting and/or parameters.

◆ exitClass()

static void SoGLDeviceSettings::exitClass ( )
static

Cleans SoDeviceSettings.

◆ getParameter()

virtual SbString SoGLDeviceSettings::getParameter ( const SbString pParameterId) const
pure virtual

Returns current value of specified parameter in current setting.

The value is converted to a string.

◆ getParameterCount()

virtual int SoGLDeviceSettings::getParameterCount ( ) const
pure virtual

Returns number of parameters in current setting.

◆ getParameterIdbyIndex()

virtual SbString SoGLDeviceSettings::getParameterIdbyIndex ( const unsigned int  index) const
pure virtual

Returns the name of the parameter with the specified index in the current setting.

Use getParameterCount() to get the number of parameters in the current setting. For example "Ambient Occlusion", "Anisotropic filtering mode", "Anisotropic filtering setting", "Antialiasing - Behavior Flags", "Preferred OpenGL GPU", etc.

◆ getSettingName()

virtual SbString SoGLDeviceSettings::getSettingName ( ) const
pure virtual

Returns the name of the current setting (vendor defined list of parameters).

◆ getSettingNameByIndex()

virtual SbString SoGLDeviceSettings::getSettingNameByIndex ( const unsigned int  index) const
pure virtual

Returns the name of the specified setting.

See getSettingsCount to get the number of settings available.

◆ getSettingsCount()

virtual int SoGLDeviceSettings::getSettingsCount ( ) const
pure virtual

Returns the number of vendor defined settings.

Depends on the graphics board and driver version.

◆ initClass()

static void SoGLDeviceSettings::initClass ( )
static

Initializes SoDeviceSettings.

◆ setParameter()

virtual bool SoGLDeviceSettings::setParameter ( const SbString pParameterId,
const SbString pParameterValue 
)
pure virtual

Set the value of a parameter in the current setting.

Returns
TRUE if success, FALSE otherwise

◆ setSettingName()

virtual bool SoGLDeviceSettings::setSettingName ( const SbString pPredefinedSettingName)
pure virtual

Set a setting (vendor defined list of parameters) by name.

See getSettingsCount and getSettingNameByIndex to retrieved predefined list of settings.

Returns
TRUE if success, FALSE otherwise

Friends And Related Symbol Documentation

◆ operator<<

std::ostream & operator<< ( std::ostream &  os,
const SoGLDeviceSettings profile 
)
friend

Prints information about the device settings.


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