Use f64 not f32 throughout graph; add Vector2 value node (#1618)

* Use doubles in graph

* Format .graphite files onto one line

* Rename new node to Vector2

* No primary input

---------

Co-authored-by: Keavon Chambers <keavon@keavon.com>
This commit is contained in:
0HyperCube
2024-02-18 22:16:37 +00:00
committed by GitHub
co-authored by Keavon Chambers
parent 0e0e347435
commit 229b5dbb20
24 changed files with 477 additions and 445 deletions
+1 -1
View File
@@ -15,7 +15,7 @@ pub struct TextGeneratorNode<Text, FontName, Size> {
}
#[node_fn(TextGeneratorNode)]
fn generate_text<'a: 'input, T>(editor: EditorApi<'a, T>, text: String, font_name: Font, font_size: f32) -> crate::vector::VectorData {
fn generate_text<'a: 'input, T>(editor: EditorApi<'a, T>, text: String, font_name: Font, font_size: f64) -> crate::vector::VectorData {
let buzz_face = editor.font_cache.get(&font_name).map(|data| load_face(data));
crate::vector::VectorData::from_subpaths(to_path(&text, buzz_face, font_size as f64, None))
}