665bfac0b339
common.rs
use super::{EffectSpec, ParamUi, Value, slider};
pub(super) fn spec(id: &'static str, name: &'static str, params: Vec<crate::ParamSpec>, render: crate::RenderFn) -> EffectSpec {
EffectSpec { id, name, category: "Generate", params, render, gpu: false, float: true }
}
pub(super) fn pt(x: f64, y: f64) -> Value {
Value::Vec2([x, y])
}
pub(super) fn pct() -> ParamUi {
slider(0.0, 100.0, 0.0, 100.0, 1)
}
No file is open. Choose one in the tree, or press Ctrl+O (⌘O on a Mac) to find one by name.
Syntax highlighting could not load. The unmodified read-only text remains available above.