Visualization Library 2.0.0

A lightweight C++ OpenGL middleware for 2D/3D graphics

VL     Star     Watch     Fork     Issue

[Download] [Tutorials] [All Classes] [Grouped Classes]
Public Member Functions | Protected Attributes | List of all members
vl::OpenGLContextFormat Class Reference

The OpenGLContextFormat class encapsulates the settings of an OpenGL rendering context. More...

#include <OpenGLContext.hpp>

Public Member Functions

 OpenGLContextFormat ()
 
void setRGBABits (int r, int g, int b, int a)
 
void setAccumRGBABits (int r, int g, int b, int a)
 
void setDoubleBuffer (bool double_buffer_on)
 
void setDepthBufferBits (int bits)
 
void setStencilBufferBits (int bits)
 
void setMultisample (bool multisample_on)
 
void setMultisampleSamples (int samples)
 
void setStereo (bool stereo_on)
 
void setFullscreen (bool fullscreent)
 
void setVSync (bool vsync_on)
 
void setContextClientVersion (int version)
 Used by EGLWindow to initialize either GLES 1.x or GLES 2.x contexts. More...
 
const ivec4rgbaBits () const
 
const ivec4accumRGBABits () const
 
bool doubleBuffer () const
 
int depthBufferBits () const
 
int stencilBufferBits () const
 
bool multisample () const
 
int multisampleSamples () const
 
bool stereo () const
 
bool fullscreen () const
 
bool vSync () const
 
int contextClientVersion () const
 Used by EGLWindow to initialize either GLES 1.x or GLES 2.x contexts. More...
 
int bitsPerPixel () const
 Returns rgbaBits().r() + rgbaBits().g() + rgbaBits().b() + rgbaBits().a() More...
 
void setOpenGLProfile (EOpenGLProfile p)
 The OpenGL profile you'd like to access. More...
 
EOpenGLProfile openGLProfile () const
 
void setVersion (int majv, int minv)
 Sets the OpenGL version you want to access when using vl::GLP_Compatibility or vl::GLP_Core profiles (default is 3.3 which will yield also any compatible higher version). More...
 
int majVersion () const
 
int minVersion () const
 

Protected Attributes

ivec4 mRGBABits
 
ivec4 mAccumRGBABits
 
int mZBufferBits
 
int mStencilBufferBits
 
int mMultisampleSamples
 
int mContextClientVersion
 
int mMajVersion
 
int mMinVersion
 
bool mHasDoubleBuffer
 
bool mHasMultisample
 
bool mStereo
 
bool mFullscreen
 
bool mVSync
 
EOpenGLProfile mProfile
 

Detailed Description

The OpenGLContextFormat class encapsulates the settings of an OpenGL rendering context.

Definition at line 56 of file OpenGLContext.hpp.

Constructor & Destructor Documentation

◆ OpenGLContextFormat()

vl::OpenGLContextFormat::OpenGLContextFormat ( )
inline

Definition at line 59 of file OpenGLContext.hpp.

Member Function Documentation

◆ accumRGBABits()

const ivec4& vl::OpenGLContextFormat::accumRGBABits ( ) const
inline

◆ bitsPerPixel()

int vl::OpenGLContextFormat::bitsPerPixel ( ) const
inline

◆ contextClientVersion()

int vl::OpenGLContextFormat::contextClientVersion ( ) const
inline

Used by EGLWindow to initialize either GLES 1.x or GLES 2.x contexts.

Definition at line 99 of file OpenGLContext.hpp.

References mContextClientVersion.

Referenced by vlEGL::EGLWindow::initEGLWindow().

◆ depthBufferBits()

int vl::OpenGLContextFormat::depthBufferBits ( ) const
inline

◆ doubleBuffer()

bool vl::OpenGLContextFormat::doubleBuffer ( ) const
inline

◆ fullscreen()

bool vl::OpenGLContextFormat::fullscreen ( ) const
inline

◆ majVersion()

int vl::OpenGLContextFormat::majVersion ( ) const
inline

◆ minVersion()

int vl::OpenGLContextFormat::minVersion ( ) const
inline

◆ multisample()

bool vl::OpenGLContextFormat::multisample ( ) const
inline

◆ multisampleSamples()

int vl::OpenGLContextFormat::multisampleSamples ( ) const
inline

◆ openGLProfile()

EOpenGLProfile vl::OpenGLContextFormat::openGLProfile ( ) const
inline

◆ rgbaBits()

const ivec4& vl::OpenGLContextFormat::rgbaBits ( ) const
inline

◆ setAccumRGBABits()

void vl::OpenGLContextFormat::setAccumRGBABits ( int  r,
int  g,
int  b,
int  a 
)
inline

Definition at line 76 of file OpenGLContext.hpp.

References mAccumRGBABits.

◆ setContextClientVersion()

void vl::OpenGLContextFormat::setContextClientVersion ( int  version)
inline

Used by EGLWindow to initialize either GLES 1.x or GLES 2.x contexts.

Definition at line 86 of file OpenGLContext.hpp.

References mContextClientVersion.

◆ setDepthBufferBits()

void vl::OpenGLContextFormat::setDepthBufferBits ( int  bits)
inline

Definition at line 78 of file OpenGLContext.hpp.

References mZBufferBits.

◆ setDoubleBuffer()

void vl::OpenGLContextFormat::setDoubleBuffer ( bool  double_buffer_on)
inline

Definition at line 77 of file OpenGLContext.hpp.

References mHasDoubleBuffer.

◆ setFullscreen()

void vl::OpenGLContextFormat::setFullscreen ( bool  fullscreent)
inline

Definition at line 83 of file OpenGLContext.hpp.

References mFullscreen.

◆ setMultisample()

void vl::OpenGLContextFormat::setMultisample ( bool  multisample_on)
inline

Definition at line 80 of file OpenGLContext.hpp.

References mHasMultisample.

◆ setMultisampleSamples()

void vl::OpenGLContextFormat::setMultisampleSamples ( int  samples)
inline

Definition at line 81 of file OpenGLContext.hpp.

References mMultisampleSamples.

◆ setOpenGLProfile()

void vl::OpenGLContextFormat::setOpenGLProfile ( EOpenGLProfile  p)
inline

The OpenGL profile you'd like to access.

When using vl::GLP_Compatibility or vl::GLP_Core you must also specify a min/maj version using setVersion() which defaults to 3.3 or a compatible higher version.

Definition at line 106 of file OpenGLContext.hpp.

References mProfile.

◆ setRGBABits()

void vl::OpenGLContextFormat::setRGBABits ( int  r,
int  g,
int  b,
int  a 
)
inline

Definition at line 75 of file OpenGLContext.hpp.

References mRGBABits.

◆ setStencilBufferBits()

void vl::OpenGLContextFormat::setStencilBufferBits ( int  bits)
inline

Definition at line 79 of file OpenGLContext.hpp.

References mStencilBufferBits.

◆ setStereo()

void vl::OpenGLContextFormat::setStereo ( bool  stereo_on)
inline

Definition at line 82 of file OpenGLContext.hpp.

References mStereo.

◆ setVersion()

void vl::OpenGLContextFormat::setVersion ( int  majv,
int  minv 
)
inline

Sets the OpenGL version you want to access when using vl::GLP_Compatibility or vl::GLP_Core profiles (default is 3.3 which will yield also any compatible higher version).

Definition at line 110 of file OpenGLContext.hpp.

References mMajVersion, and mMinVersion.

◆ setVSync()

void vl::OpenGLContextFormat::setVSync ( bool  vsync_on)
inline

Definition at line 84 of file OpenGLContext.hpp.

References mVSync.

◆ stencilBufferBits()

int vl::OpenGLContextFormat::stencilBufferBits ( ) const
inline

◆ stereo()

bool vl::OpenGLContextFormat::stereo ( ) const
inline

◆ vSync()

bool vl::OpenGLContextFormat::vSync ( ) const
inline

Member Data Documentation

◆ mAccumRGBABits

ivec4 vl::OpenGLContextFormat::mAccumRGBABits
protected

Definition at line 116 of file OpenGLContext.hpp.

Referenced by accumRGBABits(), and setAccumRGBABits().

◆ mContextClientVersion

int vl::OpenGLContextFormat::mContextClientVersion
protected

Definition at line 120 of file OpenGLContext.hpp.

Referenced by contextClientVersion(), and setContextClientVersion().

◆ mFullscreen

bool vl::OpenGLContextFormat::mFullscreen
protected

◆ mHasDoubleBuffer

bool vl::OpenGLContextFormat::mHasDoubleBuffer
protected

◆ mHasMultisample

bool vl::OpenGLContextFormat::mHasMultisample
protected

Definition at line 124 of file OpenGLContext.hpp.

Referenced by multisample(), and setMultisample().

◆ mMajVersion

int vl::OpenGLContextFormat::mMajVersion
protected

Definition at line 121 of file OpenGLContext.hpp.

Referenced by majVersion(), and setVersion().

◆ mMinVersion

int vl::OpenGLContextFormat::mMinVersion
protected

Definition at line 122 of file OpenGLContext.hpp.

Referenced by minVersion(), and setVersion().

◆ mMultisampleSamples

int vl::OpenGLContextFormat::mMultisampleSamples
protected

Definition at line 119 of file OpenGLContext.hpp.

Referenced by multisampleSamples(), and setMultisampleSamples().

◆ mProfile

EOpenGLProfile vl::OpenGLContextFormat::mProfile
protected

Definition at line 128 of file OpenGLContext.hpp.

Referenced by openGLProfile(), and setOpenGLProfile().

◆ mRGBABits

ivec4 vl::OpenGLContextFormat::mRGBABits
protected

Definition at line 115 of file OpenGLContext.hpp.

Referenced by rgbaBits(), and setRGBABits().

◆ mStencilBufferBits

int vl::OpenGLContextFormat::mStencilBufferBits
protected

Definition at line 118 of file OpenGLContext.hpp.

Referenced by setStencilBufferBits(), and stencilBufferBits().

◆ mStereo

bool vl::OpenGLContextFormat::mStereo
protected

Definition at line 125 of file OpenGLContext.hpp.

Referenced by setStereo(), and stereo().

◆ mVSync

bool vl::OpenGLContextFormat::mVSync
protected

Definition at line 127 of file OpenGLContext.hpp.

Referenced by setVSync(), and vSync().

◆ mZBufferBits

int vl::OpenGLContextFormat::mZBufferBits
protected

Definition at line 117 of file OpenGLContext.hpp.

Referenced by depthBufferBits(), and setDepthBufferBits().


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