mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-22 01:08:12 +08:00
Shaders: add gcore-shaders and make graster-nodes no-std (#2925)
* gcore-shaders: add crate, move `color` and `blending` from gcore * gcore-shaders: move `AsU32` * gcore-shaders: move `ChoiceType`, switch `Cow` for `&str`, adjust node macro * gcore-shaders: move `registry::types` * gcore-shaders: move `context::Ctx` * raster-nodes: make it `no_std` with `std` feature * gcore-shaders: fix doctest
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
pub mod types {
|
||||
/// 0% - 100%
|
||||
pub type Percentage = f64;
|
||||
/// -100% - 100%
|
||||
pub type SignedPercentage = f64;
|
||||
/// -180° - 180°
|
||||
pub type Angle = f64;
|
||||
/// Ends in the unit of x
|
||||
pub type Multiplier = f64;
|
||||
/// Non-negative integer with px unit
|
||||
pub type PixelLength = f64;
|
||||
/// Non-negative
|
||||
pub type Length = f64;
|
||||
/// 0 to 1
|
||||
pub type Fraction = f64;
|
||||
/// Unsigned integer
|
||||
pub type IntegerCount = u32;
|
||||
/// Unsigned integer to be used for random seeds
|
||||
pub type SeedValue = u32;
|
||||
/// DVec2 with px unit
|
||||
pub type PixelSize = glam::DVec2;
|
||||
/// String with one or more than one line
|
||||
pub type TextArea = String;
|
||||
}
|
||||
Reference in New Issue
Block a user