The RenderContext class provides a rendering context for a graphical application.
More...
#include <candlewick/core/RenderContext.h>
The RenderContext class provides a rendering context for a graphical application.
- See also
- Scene
-
Device
-
Mesh
◆ RenderContext() [1/3]
candlewick::RenderContext::RenderContext |
( |
NoInitT | | ) |
|
|
inline |
◆ RenderContext() [2/3]
candlewick::RenderContext::RenderContext |
( |
Device && | device, |
|
|
Window && | window ) |
Constructor without a depth format.
◆ RenderContext() [3/3]
candlewick::RenderContext::RenderContext |
( |
Device && | device, |
|
|
Window && | window, |
|
|
SDL_GPUTextureFormat | suggested_depth_format ) |
Constructor with a depth format. This will create a depth texture.
◆ ~RenderContext()
candlewick::RenderContext::~RenderContext |
( |
| ) |
|
|
noexcept |
◆ acquireCommandBuffer()
CommandBuffer candlewick::RenderContext::acquireCommandBuffer |
( |
| ) |
const |
|
inline |
Acquire the command buffer, starting a frame.
◆ acquireSwapchain()
bool candlewick::RenderContext::acquireSwapchain |
( |
CommandBuffer & | command_buffer | ) |
|
Acquire GPU swapchain.
- Warning
- This can only be called from the main thread (see SDL docs for the meaning of "main thread").
◆ createDepthTexture()
void candlewick::RenderContext::createDepthTexture |
( |
SDL_GPUTextureFormat | suggested_depth_format | ) |
|
◆ depthFormat()
SDL_GPUTextureFormat candlewick::RenderContext::depthFormat |
( |
| ) |
const |
|
inline |
◆ destroy()
void candlewick::RenderContext::destroy |
( |
| ) |
|
|
inlinenoexcept |
◆ getSwapchainTextureFormat()
SDL_GPUTextureFormat candlewick::RenderContext::getSwapchainTextureFormat |
( |
| ) |
const |
|
inline |
◆ hasDepthTexture()
bool candlewick::RenderContext::hasDepthTexture |
( |
| ) |
const |
|
inline |
Check if a depth texture was created.
◆ initialized()
bool candlewick::RenderContext::initialized |
( |
| ) |
const |
|
inline |
◆ waitAndAcquireSwapchain()
bool candlewick::RenderContext::waitAndAcquireSwapchain |
( |
CommandBuffer & | command_buffer | ) |
|
◆ waitForSwapchain()
bool candlewick::RenderContext::waitForSwapchain |
( |
| ) |
|
|
inline |
◆ depth_texture
◆ device
Device candlewick::RenderContext::device |
◆ swapchain
SDL_GPUTexture* candlewick::RenderContext::swapchain |
◆ window
Window candlewick::RenderContext::window |
The documentation for this struct was generated from the following file: