fromComponent

fun DynamicShaders.fromComponent(component: Component, componentSizeDp: Float, checkeredArrangement: Boolean = true, tileXMode: Shader.TileMode = Shader.TileMode.REPEAT, tileYMode: Shader.TileMode = tileXMode): ComponentShader

Creates a ComponentShader out of the provided component.

Parameters

component

used as a pattern in the Shader.

componentSizeDp

the size of the component (in dp).

checkeredArrangement

whether the component should be arranged in a checkered pattern.

tileXMode

the horizontal tiling mode for the component.

tileYMode

the vertical tiling mode for the component.