* WIP
* Introduce `Raster` enum and plumb texture injection to vello
* Use correct texture formas for usage in vello
* Add missing cache implementations
* Update vello image override api
* Use git version of vello
* Fix type for upload texture node
* Improve crash resiliance
* Fix warnings
* Remove unused node impls
* Test out wasm unwinding
* Implement panic catching for native targets
* Hack in support for recovering panics in wasm
* Keep debug info in release builds
* Check for DynAnyNode in Backtrace because that can't be inlined as well
* Improve error dialog
* Use a mutex for storing the frontend state instead of a RefCell
* Code review
* Update crash text
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Start integrating vello into render pipeline
Cache vello render creation
Implement viewport navigation
Close vello path
Add transform parameter to vello render pass
* Fix render node types
* Fix a bunch of bugs in the path translation
* Avoid panic on empty document
* Fix rendering of holes
* Implement image rendering
* Implement graph recompilation afer editor api change
* Implement preferences toggle for using vello as the renderer
* Make surface creation optional
* Feature gate vello usages
* Implement skeleton for radial gradient
* Rename vello preference
* Fix some gradients
* Only update monitor nodes on graph recompile
* Fix warnings + remove dead code
* Update everything except for thumbnails after a node graph evaluation
* Fix missing click targets for Image frames
* Improve perfamance by removing unecessary widget updates
* Fix node graph paning
* Fix thumbnail loading
* Implement proper hash for vector modification
* Fix test and warnings
* Code review
* Fix dep
* Remove warning
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* fix a lot of clippy warnings
* fix more clippy warnings
* fix yet more clippy warnings
* bump msrv to 1.70.0 to silence warnings
* fix a lot of clippy warnings
* fix more clippy warnings
* fix yet more clippy warnings
* fix a few more warnings
* fix a clippy warning
* remove a commented out line
* silense too many arguments error
* fix more clippy warnings
* prefix underscore to unused vars/functions to fix warnings
* use filter instead of map
* move raw-rs-tests feature flat to module level to fix unused imports warnings
* fix a couple of unused result warnings
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Click node using click targets based
* Display graph transform based on state stored in Rust, fix zoom and pan.
* Migrate node selection logic
* Move click targets and transform to NodeNetwork
* Keep click targets in sync with changes to node shape
* Click targets for import/export, add dragging
* Basic wire dragging
* complete wire dragging
* Add node selection box when dragging
* Fix zoom operations and dragging nodes
* Remove click targets from serialized data, fix EnterNestedNetwork
* WIP: Auto connect node when dragged on wire
* Finish auto connect node when dragged on wire
* Add context menus
* Improve layer width calculations and state
* Improve context menu state, various other improvements
* Close menu on escape
* Cleanup Graph.svelte
* Fix lock/hide tool tip shortcuts
* Clean up editor_api.rs, fix lock/hide layers
* Start transferring network and node metadata from NodeNetwork to the editor
* Transfer click targets to NodeGraphMessageHandler
* Fix infinite canvas
* Fix undo/redo, scrollbars, and fix warnings
* Unicode-3.0 license and code cleanup
* License fix
* formatting issue
* Enable DomRect
* Fix layer move crash
* Remove tests
* Ignore test
* formatting
* remove white dot
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Breadcrumb visualization, nested network consistency, create definitions for Merge internal nodes
* Add index to network inputs, remove imports usage from flatten network
* Replace NodeOutput with NodeInput::Node
* Fully remove imports field, remove unnecessary identity nodes, move Output node to encapsulating network
* Replace previous_outputs with root_node, fix adding artboard/layer to empty network
* Import/Export UI nodes
* Display input/output types dynamically from compiled network
* Add LayerNodeIdentifer::ROOT_PARENT
* Prevent .to_node() on ROOT_PARENT
* Separate NodeGraphMessage and GraphOperationMessage
* General bug fixes with nested networks
* Change layer color, various bug fixes and improvements
* Fix disconnect and set node input for proto nodes and UI export node
* Dashed line to export for previewed node
* Fix deleting proto nodes and nodes that feed into export
* Allow modifications to nodes outside of nested network
* Get network from Node Id parameter
* Change root_node to previous_root_node
* Get TaggedValue from proto node implementation type when disconnecting
* Improve preview functionality and state
* Artboard position and delete children fix
* Name inputs/outputs based on DocumentNodeDefinition or type, fix new artboard/layer insertion
* replace "Link" with "Wire", adjust previewing
* Various bug fixes and improvements
* Modify Sample and Poisson-Disk points, fix incorrect input index and deleting currently viewed node
* Open demo artwork
* Fix opening already upgraded documents and refactor FrontendGraphDataType usages
* Fix deleting within network and other bugs
* Get default node input from compiled network when copying, fix previews, tests, demo artwork
* Code cleanup
* Hide EditorApi and add a comment describing unresolved Import node input types
* Code review
* Replace placeholder ROOT_PARENT NodeId with std::u64::MAX
* Breadcrumb padding
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Add locking layer feature
* Update locked state data to adjust the refactor
* Make the locked layer cannot be selected using pointer and select all key
* Make locked layer cannot be moved and disable bounding box
* Add locked status selected node on CopyBuffer
* Make locked layer cannot be selected when selected all layers, and disabled GRS and nudging operation on locked layer
* Add refresh document metadata before update button on visible and locked
* Updated from master
* Fix icon logic on panel locked layer
* Make the child locked when the parent is locked, and the child cannot be unlocked if the parent is locked
* Revert "Make the child locked when the parent is locked, and the child cannot be unlocked if the parent is locked"
This reverts commit 7c93259bc2.
* Revert "Fix icon logic on panel locked layer"
This reverts commit 33939f2e84.
* Delete Make Lock button in the node graph top bar
* Add ToggleSelectedLocked to action_with_node_graph_open
* Fix parent and child locking behavior icon on panel
* Fix boolean operator on icon button locking layer
* Make bolean logic more readable in icon button locking layer
* Fix locking layer can be moved or resizing when selected with unlocking layer, disabled pivot widget on locking layer, disable all action on pivot point, alignment, flipping, and boolean operation for locking layer
* Fix axis align drag crash
---------
Co-authored-by: 0hypercube <0hypercube@gmail.com>
* Add code to shift viewport if mouse is beyond edge
* Allow shifting viewport if mouse is stationary too
* Group all modifier keys into SelectToolPointerKeys
* Cleanup message ordering to remove shifting during resize
* Slow down shifting by half
* Clamp speed; code review cleanup
---------
Co-authored-by: 0hypercube <0hypercube@gmail.com>
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Add auto saving
* Fix autosave dispatching message but not saving document
* Clamp set_timeout delay
* Auto save all documents instead of only the active
* Add with_editor to simplify code
* Update consts
* Simplify some more
* Fix typo
* Code review
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Allow generic node input for type inference
* Make imaginate resolution picking depend on the image resolution instead of the transform
* Remove dead code
* Fix console spam after crash
* Fix crash when disconnecting Imaginate node input
* Update Imaginate tool tooltip
---------
Co-authored-by: Dennis Kobert <dennis@kobert.dev>
* Refactor Graphite dependency management
* Remove deprecated future executor
* Code review nits
* Remove unused dependencies
* Update dependencies and make compile with all features
* Replace use of future_executor with wasm-bindgen-futures
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* Hide and collapse layers
* Reorder imports
* Fix Ctrl+H shortcut advertized action and hotkey tooltip; improve graph top right of options bar
---------
Co-authored-by: Keavon Chambers <keavon@keavon.com>
* A few minor lints and docs
* Added required packages to compile on Debian-style linux
* Inlined some format args, and removed some `&` in args (they cause about 6% slowdown that compiler cannot inline)
* a few spelling mistakes
* fix fmt
Changes:
Graph is evaluated on every viewport change
move all navigation logic into the viewport
reduce the number of js roundtrips
add canvas rendering
enable image pasting
various cleanups
Fix cache nodes being reset every evaluation