TachyonUI 1.1.0
High-performance UI for building tools.
Loading...
Searching...
No Matches
tachyon::metal::MetalSceneRender Struct Reference

What GraphicsContext::RenderScene's record gets on Metal (ScenePayload::As): the window frame's command buffer and a render command encoder on the scene's color and depth textures (color cleared to the scene's clear color, depth to 1), with the viewport set to all of it. More...

#include <gui_core/graphics/metal/metal_graphics_context.h>

Public Attributes

void * commandBuffer = nullptr
 id<MTLCommandBuffer>
void * encoder = nullptr
 id<MTLRenderCommandEncoder>
void * colorTexture = nullptr
 id<MTLTexture>
void * depthTexture = nullptr
 id<MTLTexture>
uint32_t colorFormat = 0
 MTLPixelFormat: MTLPixelFormatRGBA8Unorm.
uint32_t depthFormat = 0
 MTLPixelFormat: MTLPixelFormatDepth32Float.
uint2 extent {}

Static Public Attributes

static constexpr GraphicsAPI kAPI = GraphicsAPI::Metal

Detailed Description

What GraphicsContext::RenderScene's record gets on Metal (ScenePayload::As): the window frame's command buffer and a render command encoder on the scene's color and depth textures (color cleared to the scene's clear color, depth to 1), with the viewport set to all of it.

Draw with your own pipeline and depth state, and don't end the encoder: the backend ends it, and the UI samples the color texture after.

Member Data Documentation

◆ kAPI

GraphicsAPI tachyon::metal::MetalSceneRender::kAPI = GraphicsAPI::Metal
staticconstexpr

◆ commandBuffer

void* tachyon::metal::MetalSceneRender::commandBuffer = nullptr

id<MTLCommandBuffer>

◆ encoder

void* tachyon::metal::MetalSceneRender::encoder = nullptr

id<MTLRenderCommandEncoder>

◆ colorTexture

void* tachyon::metal::MetalSceneRender::colorTexture = nullptr

id<MTLTexture>

◆ depthTexture

void* tachyon::metal::MetalSceneRender::depthTexture = nullptr

id<MTLTexture>

◆ colorFormat

uint32_t tachyon::metal::MetalSceneRender::colorFormat = 0

MTLPixelFormat: MTLPixelFormatRGBA8Unorm.

◆ depthFormat

uint32_t tachyon::metal::MetalSceneRender::depthFormat = 0

MTLPixelFormat: MTLPixelFormatDepth32Float.

◆ extent

uint2 tachyon::metal::MetalSceneRender::extent {}

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