#include <glXWindow.h>


Definition at line 31 of file glXWindow.h.
Data Access | |
| virtual void | setXDrawable (XID drawable) |
| Set the X11 drawable ID for this window. | |
| virtual void | setGLXContext (GLXContext context) |
| Set the GLX rendering context for this window. | |
Public Member Functions | |
| GLXWindow (Window *parent) | |
| virtual void | configExit () |
| virtual void | makeCurrent () const |
| virtual void | swapBuffers () |
| virtual bool | configInit () |
| Initialize this window for the GLX window system. | |
| virtual GLXContext | getGLXContext () const |
| virtual XID | getXDrawable () const |
Protected Member Functions | |
| virtual XVisualInfo * | chooseXVisualInfo () |
| Choose a X11 visual based on the window's attributes. | |
| virtual GLXContext | createGLXContext (XVisualInfo *visualInfo) |
| Create a GLX context. | |
| virtual bool | configInitGLXDrawable (XVisualInfo *visualInfo) |
| Initialize the window's drawable (fullscreen, pbuffer or window) and bind the GLX context. | |
| virtual bool | configInitGLXWindow (XVisualInfo *visualInfo) |
| Initialize the window with a window and bind the GLX context. | |
| virtual bool | configInitGLXPBuffer (XVisualInfo *visualInfo) |
| Initialize the window with a PBuffer and bind the GLX context. | |
| bool eq::GLXWindow::configInit | ( | ) | [virtual] |
Initialize this window for the GLX window system.
This method first call chooseXVisualInfo(), then createGLXContext() with the chosen visual, and finally creates a drawable using configInitGLXDrawable().
Implements eq::OSWindow.
Definition at line 34 of file glXWindow.cpp.
References eq::OSWindow::_window, chooseXVisualInfo(), configInitGLXDrawable(), createGLXContext(), eq::Window::setErrorMessage(), and setGLXContext().

| virtual GLXContext eq::GLXWindow::getGLXContext | ( | ) | const [inline, virtual] |
Implements eq::GLXWindowIF.
Definition at line 57 of file glXWindow.h.
Referenced by createGLXContext().

| virtual XID eq::GLXWindow::getXDrawable | ( | ) | const [inline, virtual] |
| XVisualInfo * eq::GLXWindow::chooseXVisualInfo | ( | ) | [protected, virtual] |
Choose a X11 visual based on the window's attributes.
The returned XVisualInfo has to be freed using XFree().
Definition at line 61 of file glXWindow.cpp.
References eq::OSWindow::_window, eq::Pipe::getXDisplay(), eq::Window::IATTR_HINT_DOUBLEBUFFER, eq::Window::IATTR_HINT_DRAWABLE, eq::Window::IATTR_HINT_STEREO, eq::Window::IATTR_PLANES_ACCUM, eq::Window::IATTR_PLANES_ACCUM_ALPHA, eq::Window::IATTR_PLANES_ALPHA, eq::Window::IATTR_PLANES_COLOR, eq::Window::IATTR_PLANES_DEPTH, eq::Window::IATTR_PLANES_SAMPLES, eq::Window::IATTR_PLANES_STENCIL, and eq::Window::setErrorMessage().
Referenced by configInit().


| GLXContext eq::GLXWindow::createGLXContext | ( | XVisualInfo * | visualInfo | ) | [protected, virtual] |
Create a GLX context.
This method does not set the window's GLX context.
| visualInfo | the visual info for the context. |
Definition at line 197 of file glXWindow.cpp.
References eq::OSWindow::_window, getGLXContext(), eq::Window::getOSWindow(), eq::Window::getSharedContextWindow(), eq::Pipe::getXDisplay(), and eq::Window::setErrorMessage().
Referenced by configInit().


| bool eq::GLXWindow::configInitGLXDrawable | ( | XVisualInfo * | visualInfo | ) | [protected, virtual] |
Initialize the window's drawable (fullscreen, pbuffer or window) and bind the GLX context.
Sets the window's X11 drawable on success
| visualInfo | the visual info for the context. |
Definition at line 236 of file glXWindow.cpp.
References configInitGLXPBuffer(), configInitGLXWindow(), and eq::Window::IATTR_HINT_DRAWABLE.
Referenced by configInit().


| bool eq::GLXWindow::configInitGLXWindow | ( | XVisualInfo * | visualInfo | ) | [protected, virtual] |
Initialize the window with a window and bind the GLX context.
Sets the window's X11 drawable on success
| visualInfo | the visual info for the context. |
Definition at line 254 of file glXWindow.cpp.
References eq::OSWindow::_window, eq::Window::getName(), eq::Window::getPixelViewport(), eq::Pipe::getXDisplay(), eq::PixelViewport::h, eq::Window::IATTR_HINT_DECORATION, eq::Window::IATTR_HINT_DRAWABLE, eq::Window::IATTR_HINT_FULLSCREEN, eq::Window::setErrorMessage(), eq::Window::setPixelViewport(), setXDrawable(), eq::PixelViewport::w, eq::PixelViewport::x, and eq::PixelViewport::y.
Referenced by configInitGLXDrawable().


| bool eq::GLXWindow::configInitGLXPBuffer | ( | XVisualInfo * | visualInfo | ) | [protected, virtual] |
Initialize the window with a PBuffer and bind the GLX context.
Sets the window's X11 drawable on success
| visualInfo | the visual info for the context. |
Definition at line 354 of file glXWindow.cpp.
References eq::OSWindow::_window, eq::Window::getPixelViewport(), eq::Pipe::getXDisplay(), eq::PixelViewport::h, eq::Window::IATTR_HINT_DRAWABLE, eq::Window::setErrorMessage(), setXDrawable(), and eq::PixelViewport::w.
Referenced by configInitGLXDrawable().


| void eq::GLXWindow::setXDrawable | ( | XID | drawable | ) | [protected, virtual] |
Set the X11 drawable ID for this window.
This function should only be called from configInit() or configExit().
| drawable | the X11 drawable ID. |
Definition at line 438 of file glXWindow.cpp.
References eq::OSWindow::_window, eq::Pipe::getXDisplay(), eq::PixelViewport::h, eq::Window::IATTR_HINT_DRAWABLE, eq::Window::setPixelViewport(), eq::PixelViewport::w, eq::PixelViewport::x, and eq::PixelViewport::y.
Referenced by configInitGLXPBuffer(), and configInitGLXWindow().


| void eq::GLXWindow::setGLXContext | ( | GLXContext | context | ) | [protected, virtual] |
Set the GLX rendering context for this window.
This function should only be called from configInit() or configExit(). The context has to be set to 0 before it is destroyed.
| context | the GLX rendering context. |
Definition at line 496 of file glXWindow.cpp.
Referenced by configInit().

0.6 by
1.5.5