I'm building a gooey effect as in gif below by combining PathEffect
s but as far as i know PathEffect can be applied to Stroke style only. Is there a Compose way to apply PathEffect while filling circles?
val discretePathEffect = DiscretePathEffect(pathMeasure.length / segmentCount, 0f)
val cornerPathEffect = PathEffect.cornerPathEffect(50f)
val chainPathEffect = PathEffect.chainPathEffect(
outer = cornerPathEffect,
inner = discretePathEffect.toComposePathEffect()
)
pathLeft.op(pathLeft, pathRight, PathOperation.Union)
pathMeasure.setPath(pathLeft, true)
drawPath(
path = pathLeft,
brush = brush,
style = Stroke(
4.dp.toPx(),
pathEffect = chainPathEffect
)
)
I need filled circles instead of stroke
I solved this using Compose paint
and drawing with
full implementation