Render Anything Engine: tell your AI what to make. Videos, motion graphics, 3D and games as React and TypeScript, rendered on your own GPU. Rust + Bevy, macOS, Linux and Windows.
TypeScript 3dagent-skillsai-agentsai-videobevyclaude-codegame-enginegpulinuxmacosmotion-designmotion-graphicsreactrusttypescriptvideo-editingvideo-renderingwgpuwindows
// Copyright 2024 the Parley Authors
// SPDX-License-Identifier: Apache-2.0 OR MIT
use peniko::Color;
pub(crate) mod asserts;
pub(crate) mod fonts;
#[derive(Clone, Copy, Debug, PartialEq)]
pub(crate) struct ColorBrush {
pub(crate) color: Color,
}
impl ColorBrush {
pub(crate) fn new(color: Color) -> Self {
let rgba8 = color.to_rgba8();
Self {
color: Color::from_rgba8(rgba8.r, rgba8.g, rgba8.b, rgba8.a),
}
}
}
impl Default for ColorBrush {
fn default() -> Self {
Self {
color: Color::BLACK,
}
}
}