Vireo  0.0
Vireo 3D Rendering Hardware Interface
The submission queue

Most operations performed with graphics API, like draw commands and memory operations, are asynchronously executed by submitting them to a SubmitQueue. Queues are allocated from CommandType, where each type supports a specific set of operations in its queues. For example, there could be separate queue families for graphics, compute and memory transfer operations.

Add a submission queue field to your application :

private:
std::shared_ptr<vireo::SubmitQueue> graphicQueue;

This queue will be used for all graphics commands and for presenting the result in the window.

Create it in the onInit() method :

void MyApp::onInit() {
graphicQueue = vireo->createSubmitQueue(vireo::CommandType::GRAPHIC);
}

and in the onDestroy() method add the code to wait for all the submitted commands to finish before closing the application :

void MyApp::onDestroy() {
graphicQueue->waitIdle();
}

Next : The swap chain


Related manual page : Submission queues