diff options
Diffstat (limited to 'examples/noc/test/additive_blending.script')
| -rw-r--r-- | examples/noc/test/additive_blending.script | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/examples/noc/test/additive_blending.script b/examples/noc/test/additive_blending.script new file mode 100644 index 0000000..9c0dc6a --- /dev/null +++ b/examples/noc/test/additive_blending.script @@ -0,0 +1,18 @@ +# The pointer at three quarters of the width: a wind of 0.1 to the right. +move 480 200 +frames 120 +expect wind 0.1 ~0.000001 +# Three particles a step, each living 41 steps. +expect particles.len 123 +expect particles.buffer[0].lifespan 0 +expect particles.buffer[0].position[0] 401.646 ~0.01 +screenshot .zig-cache/e2e/additive_blending.png +frames 1 +# Added up, the particles saturate to white where they crowd (4.8's +# smoke, blended over, stays gray there: 244), and glow magenta +# (255, 100, 255 at each particle's lifespan) where they thin out. +expect-pixel .zig-cache/e2e/additive_blending.png 320 285 255 255 255 255 +expect-pixel .zig-cache/e2e/additive_blending.png 344 252 255 119 255 255 3 +expect-pixel .zig-cache/e2e/additive_blending.png 100 100 0 0 0 255 +# The arrow is added too: white on black either way. +expect-pixel .zig-cache/e2e/additive_blending.png 340 49 127 127 127 255 2 |
