Convert the remaining nodes and mark genuine async sources

This commit is contained in:
Dennis Kobert
2026-07-26 22:58:40 +00:00
parent 28d37d30d0
commit 28d9e3cbe3
17 changed files with 398 additions and 114 deletions

View File

@@ -8,7 +8,7 @@ use raster_types::{CPU, Raster};
use std::cmp::{max, min};
#[node_macro::node(category("Raster: Filter"))]
async fn dehaze(_: impl Ctx, image_frame: List<Raster<CPU>>, strength: Percentage) -> List<Raster<CPU>> {
fn dehaze(_: impl Ctx, image_frame: List<Raster<CPU>>, strength: Percentage) -> List<Raster<CPU>> {
image_frame
.into_iter()
.map(|mut row| {

View File

@@ -87,7 +87,7 @@ fn unpremultiply_gamma_to_linear(buffer: Image<PremultipliedGammaPixel>) -> Imag
/// Blurs the image with a Gaussian or box blur kernel filter.
#[node_macro::node(category("Raster: Filter"))]
async fn blur(
fn blur(
_: impl Ctx,
/// The image to be blurred.
image_frame: List<Raster<CPU>>,
@@ -124,7 +124,7 @@ async fn blur(
/// Applies a median filter to reduce noise while preserving edges.
#[node_macro::node(category("Raster: Filter"))]
async fn median_filter(
fn median_filter(
_: impl Ctx,
/// The image to be filtered.
image_frame: List<Raster<CPU>>,

View File

@@ -10,7 +10,7 @@ use vector_types::GradientStops;
// https://www.adobe.com/devnet-apps/photoshop/fileformatashtml/#:~:text=%27grdm%27%20%3D%20Gradient%20Map
// https://www.adobe.com/devnet-apps/photoshop/fileformatashtml/#:~:text=Gradient%20settings%20(Photoshop%206.0)
#[node_macro::node(category("Raster: Adjustment"))]
async fn gradient_map<T: Adjust<Color>>(
fn gradient_map<T: Adjust<Color>>(
_: impl Ctx,
#[implementations(
List<Raster<CPU>>,

View File

@@ -4,7 +4,7 @@ use core_types::list::{Item, List};
use raster_types::{CPU, Raster};
#[node_macro::node(category("Color"))]
async fn image_color_palette(
fn image_color_palette(
_: impl Ctx,
image: List<Raster<CPU>>,
#[default(4)]