mirror of
https://github.com/GraphiteEditor/Graphite.git
synced 2026-09-17 07:18:04 +08:00
Make the node system use ImageFrame more extensively (#1055)
This commit is contained in:
committed by
Keavon Chambers
parent
02d4565b0c
commit
0b813805d2
@@ -291,6 +291,7 @@ mod image {
|
||||
use super::{Color, ImageSlice};
|
||||
use crate::Node;
|
||||
use alloc::vec::Vec;
|
||||
use core::hash::{Hash, Hasher};
|
||||
use dyn_any::{DynAny, StaticType};
|
||||
use glam::DAffine2;
|
||||
|
||||
@@ -389,6 +390,13 @@ mod image {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
impl Hash for ImageFrame {
|
||||
fn hash<H: Hasher>(&self, state: &mut H) {
|
||||
self.image.hash(state);
|
||||
self.transform.to_cols_array().iter().for_each(|x| x.to_bits().hash(state))
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
#[cfg(test)]
|
||||
|
||||
Reference in New Issue
Block a user