From 839beb52f372c90ae258ae4a9496c5a854351be2 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Tue, 31 Mar 2020 19:10:08 +0200 Subject: Base: Tweak the canvas demo page to stop using fractional RGB values This is a hack to workaround missing support for fractional values in "rgb(r,g,b)" color parsing. --- Base/home/anon/www/demo.html | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Base/home/anon/www') diff --git a/Base/home/anon/www/demo.html b/Base/home/anon/www/demo.html index 8dce42375b..6fb53719e1 100644 --- a/Base/home/anon/www/demo.html +++ b/Base/home/anon/www/demo.html @@ -38,7 +38,7 @@ function update() { var r = Math.random() * 255; var g = Math.random() * 255; var b = Math.random() * 255; - var color = "rgb(" + r + "," + g + "," + b + ")"; + var color = "rgb(" + ~~r + "," + ~~g + "," + ~~b + ")"; ctx.fillStyle = color; const spread = 35; var x = mouseX + (Math.random() * spread) - (spread / 2); -- cgit v1.2.3