-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Cache Vello render output as stitchable textures #3722
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
b2b7094
0565d9c
022ef88
802c337
2d71b9a
0ca9931
1c16d8c
c90c8a3
cb60740
3a01d79
3850398
e14e91f
951dc05
22264bc
0001c18
d9c71ba
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -5,4 +5,5 @@ use crate::messages::prelude::*; | |
| pub enum PreferencesDialogMessage { | ||
| MayRequireRestart, | ||
| Confirm, | ||
| Update, | ||
| } | ||
| Original file line number | Diff line number | Diff line change | ||
|---|---|---|---|---|
|
|
@@ -369,6 +369,7 @@ impl NodeRuntime { | |||
|
|
||||
| executor.context.queue.submit([encoder.finish()]); | ||||
| surface_texture.present(); | ||||
| // image_texture.texture.destroy(); | ||||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Suggested change
|
||||
|
|
||||
| let frame = graphene_std::application_io::SurfaceFrame { | ||||
| surface_id: surface.window_id, | ||||
|
|
||||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -28,15 +28,15 @@ pub fn wrap_network_in_scope(mut network: NodeNetwork, editor_api: Arc<WasmEdito | |
| let render_node = DocumentNode { | ||
| inputs: vec![NodeInput::node(NodeId(0), 0)], | ||
| implementation: DocumentNodeImplementation::Network(NodeNetwork { | ||
| exports: vec![NodeInput::node(NodeId(2), 0)], | ||
| exports: vec![NodeInput::node(NodeId(3), 0)], | ||
| nodes: [ | ||
| DocumentNode { | ||
| call_argument: concrete!(Context), | ||
| inputs: vec![NodeInput::import(core_types::Type::Fn(Box::new(concrete!(Context)), Box::new(generic!(T))), 0)], | ||
| implementation: DocumentNodeImplementation::ProtoNode(graphene_std::render_node::render_intermediate::IDENTIFIER), | ||
| context_features: graphene_std::ContextDependencies { | ||
| extract: ContextFeatures::VARARGS, | ||
| inject: ContextFeatures::empty(), | ||
| inject: ContextFeatures::INDEX, | ||
| }, | ||
| ..Default::default() | ||
| }, | ||
|
|
@@ -51,12 +51,23 @@ pub fn wrap_network_in_scope(mut network: NodeNetwork, editor_api: Arc<WasmEdito | |
| }, | ||
| ..Default::default() | ||
| }, | ||
| DocumentNode { | ||
| call_argument: concrete!(Context), | ||
| inputs: vec![NodeInput::scope("editor-api"), NodeInput::node(NodeId(1), 0)], | ||
| implementation: DocumentNodeImplementation::ProtoNode(graphene_std::render_cache::render_output_cache::IDENTIFIER), | ||
| context_features: graphene_std::ContextDependencies { | ||
| extract: ContextFeatures::FOOTPRINT | ContextFeatures::VARARGS, | ||
| inject: ContextFeatures::VARARGS, | ||
| }, | ||
| ..Default::default() | ||
| }, | ||
| DocumentNode { | ||
| call_argument: concrete!(graphene_std::application_io::RenderConfig), | ||
| inputs: vec![NodeInput::node(NodeId(1), 0)], | ||
| inputs: vec![NodeInput::node(NodeId(2), 0)], | ||
| implementation: DocumentNodeImplementation::ProtoNode(graphene_std::render_node::create_context::IDENTIFIER), | ||
| context_features: graphene_std::ContextDependencies { | ||
| extract: ContextFeatures::empty(), | ||
| // We add the extract index annotation here to force the compiler to add a context nullification node before this node so the render context is properly nullified so the render cache node can do its's work | ||
| extract: ContextFeatures::INDEX, | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. could we add a separate ContextFeature for this purpose? |
||
| inject: ContextFeatures::REAL_TIME | ContextFeatures::ANIMATION_TIME | ContextFeatures::POINTER_POSITION | ContextFeatures::FOOTPRINT | ContextFeatures::VARARGS, | ||
| }, | ||
| ..Default::default() | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can we split this explanation in two parts, first explaining for non technical users and a second part going deeper and explaining the exact effect?