23 #include <eq/client/types.h>
24 #include <eq/client/visitorResult.h>
26 #include <eq/util/bitmapFont.h>
27 #include <eq/fabric/renderContext.h>
28 #include <eq/fabric/window.h>
80 EQ_API co::CommandQueue* getPipeThreadQueue();
81 EQ_API co::CommandQueue* getCommandThreadQueue();
82 EQ_API uint32_t getCurrentFrame()
const;
106 bool isRunning()
const {
return (_state == STATE_RUNNING); }
112 bool isStopped()
const {
return (_state == STATE_STOPPED); }
124 RenderContext& context )
const;
138 { _sharedContextWindow = sharedContextWindow; }
145 {
return _sharedContextWindow; }
194 EQ_API
const GLEWContext* getTransferGlewContext();
201 EQ_API uint32_t getColorFormat()
const;
213 EQ_API
virtual void flush()
const;
222 EQ_API
virtual void finish()
const;
242 EQ_API
virtual void makeCurrent(
const bool cache =
true )
const;
247 void makeCurrentTransfer(
const bool cache =
true )
const;
250 EQ_API
virtual void bindFrameBuffer()
const;
253 EQ_API
virtual void notifyViewportChanged();
282 bool createTransferWindow();
285 void deleteTransferSystemWindow();
313 EQ_API
virtual void attach(
const UUID&
id,
const uint32_t instanceID );
323 EQ_API
void startFrame(
const uint32_t frameNumber );
355 EQ_API
virtual bool configInit(
const uint128_t& initID );
373 EQ_API
virtual bool configInitGL(
const uint128_t& initID );
394 EQ_API
virtual void frameStart(
const uint128_t& frameID,
395 const uint32_t frameNumber );
410 EQ_API
virtual void frameFinish(
const uint128_t& frameID,
411 const uint32_t frameNumber );
424 const uint32_t frameNumber );
437 Window* _sharedContextWindow;
440 SystemWindow* _transferWindow;
443 SystemWindow* _systemWindow;
458 std::vector< RenderContext > _renderContexts[2];
466 int64_t _lastSwapTime;
475 void _addRenderContext(
const RenderContext& context );
476 friend class Channel;
479 Channels _getEventChannels(
const PointerEvent& event );
482 void _setupObjectManager();
484 void _releaseObjectManager();
490 void _enterBarrier( co::ObjectVersion barrier );
493 bool _cmdCreateChannel( co::ICommand& command );
494 bool _cmdDestroyChannel(co::ICommand& command );
495 bool _cmdConfigInit( co::ICommand& command );
496 bool _cmdConfigExit( co::ICommand& command );
497 bool _cmdFrameStart( co::ICommand& command );
498 bool _cmdFrameFinish( co::ICommand& command );
499 bool _cmdThrottleFramerate( co::ICommand& command );
500 bool _cmdFlush( co::ICommand& command );
501 bool _cmdFinish( co::ICommand& command );
502 bool _cmdBarrier( co::ICommand& command );
503 bool _cmdNVBarrier( co::ICommand& command );
504 bool _cmdSwap( co::ICommand& command );
505 bool _cmdFrameDrawFinish( co::ICommand& command );
507 LB_TS_VAR( _pipeThread );
511 #endif // EQ_WINDOW_H
A configuration is a visualization session driven by an application.
virtual void frameFinish(const uint128_t &frameID, const uint32_t frameNumber)
Finish rendering a frame.
Event structure to report window system and other events.
virtual void finish() const
Finish outstanding rendering requests.
Base data transport class for windows.
virtual bool configExitGL()
De-initialize the OpenGL state for this window.
void setSystemWindow(SystemWindow *window)
Set the OS-specific window.
std::vector< C * > Channels
A vector of pointers to channels.
const Font * getMediumFont()
A Window represents an on-screen or off-screen drawable.
void releaseFrame(const uint32_t frameNumber)
Signal the completion of a frame to the parent.
SystemWindow * getSystemWindow()
void releaseFrameLocal(const uint32_t frameNumber)
Signal the release of the local synchronization to the parent.
const ObjectManager * getObjectManager() const
BitmapFont Font
Fonts used for overlays.
virtual bool configExit()
Exit this window.
void startFrame(const uint32_t frameNumber)
Start a frame by unlocking all child resources.
A wrapper around AGL, WGL and GLX bitmap fonts.
A Node represents a single computer in the cluster.
Window * getSharedContextWindow()
A facility class to manage OpenGL objects across shared contexts.
A Pipe represents a graphics card (GPU) on a Node.
lunchbox::RefPtr< Server > ServerPtr
A reference-counted pointer to an eq::Server.
const Window * getSharedContextWindow() const
virtual bool configInitSystemWindow(const uint128_t &initID)
Initialize the OS-specific window.
bool getRenderContext(const int32_t x, const int32_t y, RenderContext &context) const
Get the last rendering context at the x, y position.
virtual bool configInit(const uint128_t &initID)
Initialize this window.
lunchbox::RefPtr< Client > ClientPtr
A reference-counted pointer to an eq::Client.
The interface definition for system-specific GPU handling.
virtual void flush() const
Flush outstanding rendering requests.
const Node * getNode() const
ObjectManager * getObjectManager()
void setSharedContextWindow(Window *sharedContextWindow)
Set the window with which this window shares the OpenGL context.
The interface definition for system-specific windowing code.
virtual void makeCurrent(const bool cache=true) const
Make the window's drawable and context current.
const Config * getConfig() const
virtual bool configInitGL(const uint128_t &initID)
Initialize the OpenGL state for this window.
virtual bool configExitSystemWindow()
De-initialize the OS-specific window.
const SystemPipe * getSystemPipe() const
const Font * getSmallFont()
eq::ObjectManager ObjectManager
The per-window OpenGL object manager.
Window(Pipe *parent)
Construct a new window.
virtual void drawFPS()
Render the current framerate as on overlay.
virtual bool processEvent(const Event &event)
Process a received event.
virtual void swapBuffers()
Swap the front and back buffer of the window.
const SystemWindow * getSystemWindow() const
virtual void frameStart(const uint128_t &frameID, const uint32_t frameNumber)
Start rendering a frame.
const GLEWContext * glewGetContext() const
Get the GLEW context for this window.
virtual void frameDrawFinish(const uint128_t &frameID, const uint32_t frameNumber)
Finish drawing.
virtual ~Window()
Destruct the window.