OGRE-Next  4.0.0unstable
Object-Oriented Graphics Rendering Engine
Ogre::ParallelHlmsCompileQueue Class Reference

#include <OgreRenderQueue.h>

Classes

struct  Request
 

Public Member Functions

 ParallelHlmsCompileQueue ()
 
void fireWarmUpParallel (SceneManager *sceneManager)
 Similar to start() and stopAndWait() at the same time: It assumes all work has already been gathered in mRequests via pushWarmUpRequest() (instead of gather it as we go) and fires all threads to compile the shaders and PSOs in parallel. More...
 
void pushRequest (const Request &&request)
 
void pushWarmUpRequest (const Request &&request)
 
void start (SceneManager *sceneManager)
 Starts worker threads (job queue) so they start accepting work every time pushRequest() gets called and will keep compiling those shaders until stopAndWait() is called. More...
 
void stopAndWait (SceneManager *sceneManager)
 Signals worker threads we won't be submitting more work, so they should stop once they're done compiling all pending shaders / PSOs. More...
 
void updateThread (size_t threadIdx, HlmsManager *hlmsManager)
 The actual work done by the job queues. More...
 
void updateWarmUpThread (size_t threadIdx, HlmsManager *hlmsManager, const HlmsCache *passCaches)
 The actual work done by fireWarmUpParallel(). More...
 
void warmUpSerial (HlmsManager *hlmsManager, const HlmsCache *passCaches)
 Serial alternative of fireWarmUpParallel() + updateWarmUpThread() for when RenderSystem::supportsMultithreadedShaderCompliation is false. More...
 

Constructor & Destructor Documentation

◆ ParallelHlmsCompileQueue()

Ogre::ParallelHlmsCompileQueue::ParallelHlmsCompileQueue ( )

Member Function Documentation

◆ fireWarmUpParallel()

void Ogre::ParallelHlmsCompileQueue::fireWarmUpParallel ( SceneManager sceneManager)

Similar to start() and stopAndWait() at the same time: It assumes all work has already been gathered in mRequests via pushWarmUpRequest() (instead of gather it as we go) and fires all threads to compile the shaders and PSOs in parallel.

It will wait until all threads are done.

◆ pushRequest()

void Ogre::ParallelHlmsCompileQueue::pushRequest ( const Request &&  request)
inline

◆ pushWarmUpRequest()

void Ogre::ParallelHlmsCompileQueue::pushWarmUpRequest ( const Request &&  request)
inline

◆ start()

void Ogre::ParallelHlmsCompileQueue::start ( SceneManager sceneManager)

Starts worker threads (job queue) so they start accepting work every time pushRequest() gets called and will keep compiling those shaders until stopAndWait() is called.

The work is done in updateThread() and is in charge of compiling shaders AND generating PSOs.

Remarks
This function must not be called if RenderSystem::supportsMultithreadedShaderCompliation is false.
Parameters
sceneManager

◆ stopAndWait()

void Ogre::ParallelHlmsCompileQueue::stopAndWait ( SceneManager sceneManager)

Signals worker threads we won't be submitting more work, so they should stop once they're done compiling all pending shaders / PSOs.

Will wait until all shaders are done.

Parameters
sceneManager

◆ updateThread()

void Ogre::ParallelHlmsCompileQueue::updateThread ( size_t  threadIdx,
HlmsManager hlmsManager 
)

The actual work done by the job queues.

◆ updateWarmUpThread()

void Ogre::ParallelHlmsCompileQueue::updateWarmUpThread ( size_t  threadIdx,
HlmsManager hlmsManager,
const HlmsCache passCaches 
)

The actual work done by fireWarmUpParallel().

◆ warmUpSerial()

void Ogre::ParallelHlmsCompileQueue::warmUpSerial ( HlmsManager hlmsManager,
const HlmsCache passCaches 
)

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