pixie/tests/benchmark_blends.nim

17 lines
295 B
Nim
Raw Normal View History

import benchy, chroma, pixie, vmath
2020-12-09 07:18:57 +00:00
2020-12-09 07:25:48 +00:00
let
a = newImage(1000, 1000)
b = newImage(1000, 1000)
b.fill(rgba(127, 127, 127, 255))
2020-12-09 07:18:57 +00:00
timeIt "bmNormal":
a.draw(b, vec2(0, 0), bmNormal)
2020-12-09 07:18:57 +00:00
timeIt "bmDarken":
a.draw(b, vec2(0, 0), bmDarken)
2020-12-09 07:18:57 +00:00
timeIt "bmMultiply":
a.draw(b, vec2(0, 0), bmMultiply)