Update #[min/max] node macro attributes to #[soft/hard]_[min/max] and make them clamp their input data (#2464)

* Fix min and max macro not enforcing limits when data flows

* Use trait based clamping

* Remove min/max from testing

* cargo fmt

* Resolve into min, and hard_min

* cargo fmt

* fix traits

* cargo fmt

* fix tests

* rename as soft_x

* Add validation code

* Clean up (not compiling because of DVec2 clamping)

* Avoid needing to add trait bounds to node definitions

* Code review

---------

Co-authored-by: Dennis Kobert <dennis@kobert.dev>
Co-authored-by: Keavon Chambers <keavon@keavon.com>
This commit is contained in:
mTvare
2025-04-30 23:52:27 -07:00
committed by GitHub
co-authored by Dennis Kobert Keavon Chambers
parent 2fc4896d01
commit 9303953cf8
13 changed files with 259 additions and 46 deletions
+2
View File
@@ -9,6 +9,7 @@ use core::future::Future;
#[cfg(feature = "log")]
extern crate log;
pub use crate as graphene_core;
pub use num_traits;
#[cfg(feature = "reflections")]
pub use ctor;
@@ -19,6 +20,7 @@ pub mod context;
pub mod generic;
pub mod instances;
pub mod logic;
pub mod misc;
pub mod ops;
pub mod structural;
#[cfg(feature = "std")]