cranpose-render-common 0.0.36

Common rendering contracts for Cranpose
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# Cranpose Render Common

The common abstraction layer for Cranpose rendering backends.

## When to Use

This crate defines the `Renderer` trait and the `RenderOp` enum. You should use this crate only if you are implementing a custom rendering backend (e.g., a pure terminal renderer or a specific game engine integration).

## Key Concepts

-   **`RenderOp`**: Represents a high-level drawing command (e.g., `DrawRect`, `DrawText`, `PushTransform`).
-   **`RenderScene`**: A unified list of operations generated by the UI layout phase.
-   **`Renderer` Trait**: The interface that a backend must implement to consume a `RenderScene` and produce pixels on a surface.

## Architecture

This crate decouples the UI framework from specific graphics APIs, allowing `cranpose-ui` to be renderer-agnostic.