From 644ef8d18964f8c21fb2e82913762350c80a5253 Mon Sep 17 00:00:00 2001 From: Kurt Hutten Date: Tue, 17 Aug 2021 05:13:30 +1000 Subject: [PATCH] EdgeSplit not flushing out old geometry Mostly effecting CQ, changing the script and updating leaves a ghost of the old geometry in the viewer Resolves #459 --- app/web/src/helpers/hooks/useEdegeSplit.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/app/web/src/helpers/hooks/useEdegeSplit.ts b/app/web/src/helpers/hooks/useEdegeSplit.ts index 3e047b5..22a7839 100644 --- a/app/web/src/helpers/hooks/useEdegeSplit.ts +++ b/app/web/src/helpers/hooks/useEdegeSplit.ts @@ -19,6 +19,11 @@ export function useEdgeSplit( original.current = ref.current.geometry.clone() modifier.current = new EdgeSplitModifier() } + }, []) + + React.useEffect(() => { + original.current = dependantGeometry.clone() + modifier.current = new EdgeSplitModifier() }, [dependantGeometry]) React.useEffect(() => {