Flint Engine
Modular C++20 2D game engine powered by SDL3
Loading...
Searching...
No Matches
batch-vertex.h
1// SPDX-License-Identifier: MIT
2// SPDX-FileCopyrightText: 2025-2026 Manuel Osorio
3#pragma once
4#include "flint/graphics/types/color.h"
5#include "flint/math/types.h"
6
7namespace Flint {
8
34
35 static_assert(sizeof(BatchVertex) == 28,
36 "BatchVertex layout drifted — BatchPipeline declares a 28-byte stride");
37
48 float pos[2];
49 float color[4];
50 };
51
52}
Color color
RGBA color tint applied to vertex.
Vec2f uv
Normalized texture coordinates in range [0, 1].
Vec2f position
World-space 2-D vertex coordinates.
Vec2f shapeParams
Dual-purpose SDF parameters ({radius, innerRadius} or {0, 0}).
Vertex structure for the primary geometry quad pipeline.
RGBA color with 8-bit unsigned components.
Definition color.h:13
float color[4]
Normalized RGBA color channels in range [0.0, 1.0].
float pos[2]
Normalized device coordinates (NDC) in range [-1, 1].
Internal vertex structure sent directly to line/point primitive shaders.