Equalizer  1.7.3
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Pages
eq::SystemWindow Class Referenceabstract

The interface definition for system-specific windowing code. More...

#include <systemWindow.h>

+ Inheritance diagram for eq::SystemWindow:
+ Collaboration diagram for eq::SystemWindow:

Public Member Functions

EQ_API SystemWindow (NotifierInterface &parent, const WindowSettings &settings)
 Create a new SystemWindow for the given eq::Window. More...
 
virtual EQ_API ~SystemWindow ()
 Destroy the SystemWindow. More...
 
virtual EQ_API void queryDrawableConfig (DrawableConfig &dc)=0
 Set up the given drawable based on the current context. More...
 
virtual const GLEWContext * glewGetContext () const
 Get the GLEW context for this window. More...
 
EQ_API EventOCommand sendError (const uint32_t error)
 Send a window error event to the application node. More...
 
virtual EQ_API bool processEvent (const Event &event)
 Process an event. More...
 
EQ_API void setPixelViewport (const PixelViewport &pvp)
 Set the window's pixel viewport wrt its parent pipe. More...
 
EQ_API const PixelViewport & getPixelViewport () const
 
EQ_API uint32_t getColorFormat () const
 
EQ_API void setName (const std::string &name)
 Set the window's name. More...
 
EQ_API const std::string & getName () const
 
EQ_API int32_t getIAttribute (const WindowSettings::IAttribute attr) const
 
EQ_API const SystemWindowgetSharedContextWindow () const
 
Methods forwarded from eq::Window
virtual EQ_API bool configInit ()=0
 Initialize this system window. More...
 
virtual EQ_API void configExit ()=0
 De-initialize this system window. More...
 
virtual EQ_API void makeCurrent (const bool cache=true) const =0
 Make the system window rendering context and drawable current. More...
 
virtual EQ_API void bindFrameBuffer () const =0
 Bind the window's FBO, if it uses an FBO drawable. More...
 
virtual EQ_API void swapBuffers ()=0
 Swap the front and back buffer. More...
 
virtual EQ_API void flush ()=0
 Flush all command buffers. More...
 
virtual EQ_API void finish ()=0
 Finish execution of all commands. More...
 
virtual EQ_API void joinNVSwapBarrier (const uint32_t group, const uint32_t barrier)=0
 Join a NV_swap_group. More...
 
Frame Buffer Object support.
virtual const
util::FrameBufferObject
getFrameBufferObject () const
 

Detailed Description

The interface definition for system-specific windowing code.

The system window abstracts all window system specific code and facilitates porting to new windowing systems. Each eq::Window uses one eq::SystemWindow, which is created and initialized in Window::configInitSystemWindow.

Definition at line 35 of file systemWindow.h.

Constructor & Destructor Documentation

EQ_API eq::SystemWindow::SystemWindow ( NotifierInterface parent,
const WindowSettings settings 
)

Create a new SystemWindow for the given eq::Window.

Version
1.7.2
virtual EQ_API eq::SystemWindow::~SystemWindow ( )
virtual

Destroy the SystemWindow.

Version
1.0

Member Function Documentation

virtual EQ_API void eq::SystemWindow::bindFrameBuffer ( ) const
pure virtual

Bind the window's FBO, if it uses an FBO drawable.

Version
1.0

Implemented in eq::GLWindow.

virtual EQ_API void eq::SystemWindow::configExit ( )
pure virtual

De-initialize this system window.

This function might be called on partially or uninitialized system windows, and the implemenation has therefore be tolerant enough to handle this case.

Version
1.0

Implemented in eq::wgl::Window, and eq::glx::Window.

virtual EQ_API bool eq::SystemWindow::configInit ( )
pure virtual

Initialize this system window.

This method should take into account all attributes of the parent Window.

Returns
true if the window was correctly initialized, false on any error.
Version
1.0

Implemented in eq::wgl::Window, and eq::glx::Window.

virtual EQ_API void eq::SystemWindow::finish ( )
pure virtual

Finish execution of all commands.

Version
1.5.2

Implemented in eq::GLWindow.

virtual EQ_API void eq::SystemWindow::flush ( )
pure virtual

Flush all command buffers.

Version
1.5.2

Implemented in eq::GLWindow.

virtual const util::FrameBufferObject* eq::SystemWindow::getFrameBufferObject ( ) const
inlinevirtual
Returns
the FBO of this window, or 0.
Version
1.0

Reimplemented in eq::GLWindow.

Definition at line 106 of file systemWindow.h.

EQ_API int32_t eq::SystemWindow::getIAttribute ( const WindowSettings::IAttribute  attr) const
Returns
the value of an integer attribute.
Version
1.7.2
EQ_API const std::string& eq::SystemWindow::getName ( ) const
Returns
the window's name.
Version
1.7.2
EQ_API const PixelViewport& eq::SystemWindow::getPixelViewport ( ) const
Returns
the window's pixel viewport wrt the parent pipe.
Version
1.7.2
EQ_API const SystemWindow* eq::SystemWindow::getSharedContextWindow ( ) const
Returns
the window with which this window shares the GL context.
Version
1.7.2
virtual const GLEWContext* eq::SystemWindow::glewGetContext ( ) const
inlinevirtual

Get the GLEW context for this window.

The glew context is initialized during window initialization, and provides access to OpenGL extensions. This function does not follow the Equalizer naming conventions, since GLEW uses a function of this name to automatically resolve OpenGL function entry points. Therefore, any supported GL function can be called directly from an initialized SystemWindow.

Returns
the extended OpenGL function table for the window's OpenGL context.
Version
1.0

Reimplemented in eq::GLWindow.

Definition at line 130 of file systemWindow.h.

virtual EQ_API void eq::SystemWindow::joinNVSwapBarrier ( const uint32_t  group,
const uint32_t  barrier 
)
pure virtual

Join a NV_swap_group.

See WGL or GLX implementation and OpenGL extension for details on how to implement this function.

Parameters
groupthe swap group name.
barrierthe swap barrier name.
Version
1.0

Implemented in eq::wgl::Window, and eq::glx::Window.

virtual EQ_API void eq::SystemWindow::makeCurrent ( const bool  cache = true) const
pure virtual

Make the system window rendering context and drawable current.

This function invalidates the pipe's make current cache. If this function is not called, Pipe::setCurrent() has to be called appropriately.

Version
1.0

Implemented in eq::wgl::Window, eq::glx::Window, and eq::GLWindow.

virtual EQ_API bool eq::SystemWindow::processEvent ( const Event event)
virtual

Process an event.

Version
1.0
virtual EQ_API void eq::SystemWindow::queryDrawableConfig ( DrawableConfig &  dc)
pure virtual

Set up the given drawable based on the current context.

Version
1.0

Implemented in eq::GLWindow.

EQ_API EventOCommand eq::SystemWindow::sendError ( const uint32_t  error)

Send a window error event to the application node.

Parameters
errorthe error code.
Version
1.7.1
EQ_API void eq::SystemWindow::setName ( const std::string &  name)

Set the window's name.

Version
1.7.2
EQ_API void eq::SystemWindow::setPixelViewport ( const PixelViewport &  pvp)

Set the window's pixel viewport wrt its parent pipe.

Parameters
pvpthe viewport in pixels.
Version
1.7.2
virtual EQ_API void eq::SystemWindow::swapBuffers ( )
pure virtual

Swap the front and back buffer.

Version
1.0

Implemented in eq::wgl::Window, and eq::glx::Window.


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