add tests

This commit is contained in:
Ryan Oldenburg 2022-07-23 20:13:57 -05:00
parent b1bd568015
commit d0ebc4f58d
3 changed files with 22 additions and 0 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

View file

@ -132,3 +132,25 @@ block:
let image = newImage(100, 100)
image.fillPath(heartShape, paint)
image.xray("tests/paths/gradientAngularOpacity.png")
block:
let paint = newPaint(ImagePaint)
paint.image = readImage("tests/fileformats/png/mandrill.png")
paint.imageMat = scale(vec2(0.2, 0.2))
paint.opacity = 0.5
let image = newImage(128, 128)
image.fill(rgbx(0, 255, 0, 255))
image.fill(paint)
image.xray("tests/paths/fillImagePaint.png")
block:
let paint = newPaint(TiledImagePaint)
paint.image = readImage("tests/fileformats/png/mandrill.png")
paint.imageMat = scale(vec2(0.1, 0.1))
paint.opacity = 0.5
let image = newImage(128, 128)
image.fill(rgbx(0, 255, 0, 255))
image.fill(paint)
image.xray("tests/paths/fillTiledImagePaint.png")