pixie/tests/test_images.nim

12 lines
273 B
Nim
Raw Normal View History

2020-11-20 06:12:44 +00:00
import pixie, chroma
block:
var image = newImage(10, 10)
image[0, 0] = rgba(255, 255, 255, 255)
doAssert image[0, 0] == rgba(255, 255, 255, 255)
block:
var image = newImage(10, 10)
image.fill(rgba(255, 0, 0, 255))
doAssert image[0, 0] == rgba(255, 0, 0, 255)