Function

MorphPolygonShape

Creates a Shape that morphs between start and end as progress moves from 0f to 1f.

MorphPolygonShape

Source set: Common
public fun MorphPolygonShape(start: PolygonShape, end: PolygonShape, progress: () -> Float): Shape

Creates a Shape that morphs between start and end as progress moves from 0f to 1f.

Reads progress each time the outline is resolved. Values at or below 0f resolve to start; values at or above 1f resolve to end. Create a separate instance for each morphing element.

Parameters

start starting shape of the morph
end ending shape of the morph
progress returns the current morph progress
Jetpack Compose beyond MaterialFree components, screens and templates for apps that don’t look like Google’s. Copy them into your app, or let your coding agent add them.Browse for free

Content updated: