|
Flint Engine
Modular C++20 2D game engine powered by SDL3
|
Alpha-blended pipeline for rendering UI elements (text, panels, icons). More...
#include <flint/graphics/pipelines/ui-pipeline.h>
Inheritance diagram for Flint::UIPipeline:
Collaboration diagram for Flint::UIPipeline:Public Member Functions | |
| UIPipeline (const UIPipeline &)=delete | |
| UIPipeline & | operator= (const UIPipeline &)=delete |
| bool | initialize (SDL_GPUDevice *device, ShaderFormat shaderFormat, SDL_GPUTextureFormat swapchainFormat) |
| Create the GPU graphics pipeline with alpha blending enabled. | |
| void | cleanup () |
| Release the pipeline and its shader. | |
Public Member Functions inherited from Flint::Pipeline | |
| Pipeline (SDL_GPUDevice *device) | |
Construct a pipeline bound to device. | |
| virtual bool | initialize (Shader *shader, const PipelineConfig &config) |
| Create the underlying SDL GPU graphics pipeline. | |
| void | bind (SDL_GPURenderPass *renderPass) |
| Bind this pipeline to the active render pass. | |
| SDL_GPUGraphicsPipeline * | getPipeline () const |
| Return the raw SDL GPU graphics pipeline handle. | |
| Shader * | getShader () const |
| Return the shader associated with this pipeline. | |
Static Public Member Functions | |
| static void | setVertexUniforms (SDL_GPUCommandBuffer *commandBuffer, const UIVertexUniforms &uniforms) |
| Upload vertex uniforms (screen size and offset) to the vertex stage. | |
| static void | setFragmentUniforms (SDL_GPUCommandBuffer *commandBuffer, const UIFragmentUniforms &uniforms) |
| Upload fragment uniforms (tint color) to the fragment stage. | |
| static UIVertexUniforms | buildVertexUniforms (float screenWidth, float screenHeight, float offsetX=0.0f, float offsetY=0.0f) |
| Build a UIVertexUniforms value. | |
| static UIFragmentUniforms | buildFragmentUniforms (float r, float g, float b, float a) |
| Build a UIFragmentUniforms value. | |
Additional Inherited Members | |
Protected Member Functions inherited from Flint::Pipeline | |
| virtual bool | configurePipeline (SDL_GPUGraphicsPipelineCreateInfo &pipelineInfo) |
| Subclass hook to customize the pipeline create-info before submission. | |
Protected Attributes inherited from Flint::Pipeline | |
| SDL_GPUDevice * | m_device = nullptr |
| SDL_GPUGraphicsPipeline * | m_pipeline = nullptr |
| Shader * | m_shader = nullptr |
Alpha-blended pipeline for rendering UI elements (text, panels, icons).
Vertex buffer layout:
Definition at line 36 of file ui-pipeline.h.