mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-15 22:28:10 +08:00
Add license information for node_graph crates
This commit is contained in:
1319
node-graph/gstd/Cargo.lock
generated
1319
node-graph/gstd/Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@@ -4,12 +4,11 @@ version = "0.1.0"
|
||||
edition = "2021"
|
||||
description = "Graphene standard library"
|
||||
authors = ["Graphite Authors <contact@graphite.rs>"]
|
||||
license = "MIT OR Apache-2.0"
|
||||
|
||||
# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html
|
||||
|
||||
[features]
|
||||
rust_analyzer = ["ide", "ide_db"]
|
||||
caching = ["storage-map", "lock_api", "parking_lot"]
|
||||
derive = ["graph-proc-macros"]
|
||||
memoization = ["once_cell"]
|
||||
default = ["derive", "memoization"]
|
||||
@@ -21,11 +20,6 @@ borrow_stack = {path = "../borrow_stack"}
|
||||
dyn-any = {path = "../../libraries/dyn-any", features = ["derive"]}
|
||||
graph-proc-macros = {path = "../proc-macro", optional = true}
|
||||
once_cell = {version= "1.10", optional = true}
|
||||
ide = { version = "*", package = "ra_ap_ide", optional = true }
|
||||
ide_db = { version = "*", package = "ra_ap_ide_db", optional = true }
|
||||
storage-map = { version = "*", optional = true }
|
||||
lock_api = { version= "*", optional = true }
|
||||
parking_lot = { version = "*", optional = true }
|
||||
#pretty-token-stream = {path = "../../pretty-token-stream"}
|
||||
syn = {version = "1.0", default-features = false, features = ["parsing", "printing"]}
|
||||
proc-macro2 = {version = "1.0", default-features = false, features = ["proc-macro"]}
|
||||
|
||||
22
node-graph/gstd/file.rs
Normal file
22
node-graph/gstd/file.rs
Normal file
@@ -0,0 +1,22 @@
|
||||
# [cfg (target_arch = "spirv")]pub mod gpu {
|
||||
# [repr (C )]pub struct PushConsts {
|
||||
n : u32 , node : u32 ,
|
||||
}
|
||||
use super :: * ;
|
||||
use spirv_std :: glam :: UVec3 ;
|
||||
# [allow (unused )]# [spirv (compute (threads (64)))]pub fn "add"(# [spirv (global_invocation_id )]global_id : UVec3 , # [spirv (storage_buffer , descriptor_set = 0, binding = 0)]a : & [u32 ], # [spirv (storage_buffer , descriptor_set = 0, binding = 1)]y : & mut [u32 ], # [spirv (push_constant )]push_consts : & PushConsts , ){
|
||||
fn node_graph (input : u32 )-> u32 {
|
||||
let n0 = graphene_core :: value :: ValueNode :: new (input );
|
||||
let n1 = graphene_core :: value :: ValueNode :: new (1u32);
|
||||
let n2 = graphene_core :: ops :: AddNode :: new ((& n0 , & n1 ));
|
||||
n2 . eval ()
|
||||
}
|
||||
let gid = global_id . x as usize ;
|
||||
if global_id . x < push_consts . n {
|
||||
y [gid ]= node_graph (a [gid ]);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,8 +1,6 @@
|
||||
pub mod value;
|
||||
pub use graphene_core::{generic, ops /*, structural*/};
|
||||
|
||||
#[cfg(feature = "caching")]
|
||||
pub mod cache;
|
||||
#[cfg(feature = "memoization")]
|
||||
pub mod memo;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user