Add more advanced math nodes (#1383)

Added nodes for the following operations:

* Floor
* Ceil
* Round
* Absolute Value
* Logarithm
* Natural Logarithm
* sin
* cos
* tan
This commit is contained in:
isiko 2023-08-14 15:43:17 +02:00 committed by GitHub
parent 2412a3def6
commit 7558088727
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
4 changed files with 176 additions and 0 deletions

View file

@ -227,6 +227,15 @@ fn node_registry() -> HashMap<NodeIdentifier, HashMap<NodeIOTypes, NodeConstruct
register_node!(graphene_core::ops::ExponentParameterNode<_>, input: f32, params: [f32]),
register_node!(graphene_core::ops::ExponentParameterNode<_>, input: &f32, params: [f32]),
register_node!(graphene_core::ops::ExponentParameterNode<_>, input: f32, params: [&f32]),
register_node!(graphene_core::ops::FloorNode, input: f32, params: []),
register_node!(graphene_core::ops::CeilNode, input: f32, params: []),
register_node!(graphene_core::ops::RoundNode, input: f32, params: []),
register_node!(graphene_core::ops::AbsoluteNode, input: f32, params: []),
register_node!(graphene_core::ops::LogParameterNode<_>, input: f32, params: [f32]),
register_node!(graphene_core::ops::NaturalLogNode, input: f32, params: []),
register_node!(graphene_core::ops::SineNode, input: f32, params: []),
register_node!(graphene_core::ops::CosineNode, input: f32, params: []),
register_node!(graphene_core::ops::TangentNode, input: f32, params: []),
register_node!(graphene_core::ops::MaxParameterNode<_>, input: u32, params: [u32]),
register_node!(graphene_core::ops::MaxParameterNode<_>, input: f32, params: [f32]),
register_node!(graphene_core::ops::MinParameterNode<_>, input: u32, params: [u32]),