fill

fun Image.fill(color: Color)(source)

Sets every pixel to color.

Samples

val image = Image(2, 2)
image.fill(Color.WHITE)
assertPrints(image[0, 0], "Color(#ffffffff)")
assertPrints(image[1, 1], "Color(#ffffffff)")