---
name: Color
lang: cpp
domain: core
version: "0.1.0"
algebraic: product
definition: "struct Color { float r, g, b, a; }"
description: "Color RGBA en floats normalizados [0,1]. Helpers para presets (white/black/transparent), construccion desde u8 (rgba(r,g,b,a)) o desde packed hex (hex(0xRRGGBBAA))."
tags: [gamedev, color, primitive]
uses_types: []
file_path: "cpp/functions/core/math2d.h"
examples: |
  Color tint = Color::white();
  Color red  = Color::rgba(255, 0, 0);
  Color cyan = Color::hex(0x00FFFFFF);
notes: |
  - RGBA en floats por defecto — aceptado por sokol_gfx.
  - alpha default 1.0 para builders.
  - Sin gamma correction implicito; el shader decide.
---

# Color

Color RGBA float usado por sprite_batch (tint), pass clear, debug draw.
