import React from 'react'; import type {CubicBezierHandle} from '@shopify/react-native-skia'; import {Line, Paint, Circle} from '@shopify/react-native-skia'; import type {SharedValue} from 'react-native-reanimated'; import {useDerivedValue} from 'react-native-reanimated'; import {symmetric} from './Math'; interface CubicProps { mesh: SharedValue; index: number; color: string; } export const Cubic = ({mesh, index, color}: CubicProps) => { const c1 = useDerivedValue(() => mesh.value[index].c1, [mesh]); const c1S = useDerivedValue( () => symmetric(mesh.value[index].c1, mesh.value[index].pos), [mesh], ); const c2 = useDerivedValue(() => mesh.value[index].c2, [mesh]); const c2S = useDerivedValue( () => symmetric(mesh.value[index].c2, mesh.value[index].pos), [mesh], ); const pos = useDerivedValue(() => mesh.value[index].pos, [mesh]); return ( <> ); };