Visualization LibraryA lightweight C++ OpenGL middleware for 2D/3D graphics |
[Home] [Tutorials] [All Classes] [Grouped Classes] |
#include <Win32Context.hpp>

Public Member Functions | |
| Win32Context () | |
| Win32Context (int w, int h) | |
| virtual HWND | hwnd () const =0 |
| HDC | hdc () const |
| HGLRC | hglrc () const |
| void | shareOpenGLResources (HGLRC hGLRC) |
| Use this function when you want two OpenGL contexts to share their resources (display lists, textures, shader objects, buffer objects etc. | |
| void | makeCurrent () |
| void | update () |
| void | swapBuffers () |
| void | setWindowTitle (const vl::String &title) |
| void | show () |
| void | hide () |
| void | getFocus () |
| void | setMouseVisible (bool visible) |
| void | setMousePosition (int x, int y) |
| void | setPosition (int x, int y) |
| vl::ivec2 | position () const |
| void | setSize (int w, int h) |
| The actual size of the OpenGL context, i.e. | |
| vl::ivec2 | size () const |
| The actual size of the OpenGL context, i.e. the client area if this is a window. | |
| void | setWindowSize (int w, int h) |
| Sets the size of the window. Note that if this Win32Window has window decorations the actual OpenGL context will be smaller than the given w and h parameters. | |
| vl::ivec2 | windowSize () const |
| Returns the size of the window and not the client area. | |
| bool | setFullscreen (bool fullscreen_on) |
| void | quitApplication () |
| Calls the PostQuitMessage(0) function (Win32 API). | |
Protected Member Functions | |
| bool | init (HGLRC share_context, const vl::String &title, const vl::OpenGLContextFormat &fmt, int x, int y, int width, int height) |
Protected Attributes | |
| HDC | mHDC |
| HGLRC | mHGLRC |
| vl::ivec2 | mNormPosit |
| vl::ivec2 | mNormSize |
| unsigned | mNormFlags |
| vlWin32::Win32Context::Win32Context | ( | ) | [inline] |
| vlWin32::Win32Context::Win32Context | ( | int | w, | |
| int | h | |||
| ) | [inline] |
| virtual HWND vlWin32::Win32Context::hwnd | ( | ) | const [pure virtual] |
Implemented in vlWin32::Win32Window, and vlMFC::MFCWindow.
| HDC vlWin32::Win32Context::hdc | ( | ) | const [inline] |
| HGLRC vlWin32::Win32Context::hglrc | ( | ) | const [inline] |
| void Win32Context::shareOpenGLResources | ( | HGLRC | hGLRC | ) |
Use this function when you want two OpenGL contexts to share their resources (display lists, textures, shader objects, buffer objects etc.
) Equivalent to wglShareLists(this->hglrc(), hGLRC)
| void Win32Context::makeCurrent | ( | ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::update | ( | ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::swapBuffers | ( | ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::setWindowTitle | ( | const vl::String & | title | ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::show | ( | ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::hide | ( | ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::getFocus | ( | ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::setMouseVisible | ( | bool | visible | ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::setMousePosition | ( | int | x, | |
| int | y | |||
| ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::setPosition | ( | int | x, | |
| int | y | |||
| ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| vl::ivec2 Win32Context::position | ( | ) | const [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::setSize | ( | int | w, | |
| int | h | |||
| ) | [virtual] |
The actual size of the OpenGL context, i.e.
the client area if this is a window. Note that if this Win32Window has window decorations the actual window size will be bigger than the given w and h parameters.
Reimplemented from vl::OpenGLContext.
| vl::ivec2 Win32Context::size | ( | ) | const [virtual] |
The actual size of the OpenGL context, i.e. the client area if this is a window.
Reimplemented from vl::OpenGLContext.
| void Win32Context::setWindowSize | ( | int | w, | |
| int | h | |||
| ) |
Sets the size of the window. Note that if this Win32Window has window decorations the actual OpenGL context will be smaller than the given w and h parameters.
| vl::ivec2 Win32Context::windowSize | ( | ) | const |
Returns the size of the window and not the client area.
Use the size() method if you need the size of the actual OpenGL rendering context.
| bool Win32Context::setFullscreen | ( | bool | fullscreen_on | ) | [virtual] |
Reimplemented from vl::OpenGLContext.
| void Win32Context::quitApplication | ( | ) | [virtual] |
| bool Win32Context::init | ( | HGLRC | share_context, | |
| const vl::String & | title, | |||
| const vl::OpenGLContextFormat & | fmt, | |||
| int | x, | |||
| int | y, | |||
| int | width, | |||
| int | height | |||
| ) | [protected] |
HDC vlWin32::Win32Context::mHDC [protected] |
HGLRC vlWin32::Win32Context::mHGLRC [protected] |
vl::ivec2 vlWin32::Win32Context::mNormPosit [protected] |
vl::ivec2 vlWin32::Win32Context::mNormSize [protected] |
unsigned vlWin32::Win32Context::mNormFlags [protected] |