This strategy copies the canvas into a buffer after the draw call, and draws the buffer into the canvas at the beginning of the draw call. The buffer is drawn with 99% alpha, which results in a smooth fade out.. But only in Firefox!
Chrome and Safari still exhibit the ugly gray trails..
I thought of modifying the canvas' imageData to achieve a smooth fade, but my fps is tanking just thinking about it ๐
=> More informations about this toot | View the thread
Anyone got ideas on how to fade out a canvas - slowly?
The simple method is to โ instead of clearing the canvas between draw calls, filling it with a transparent black rectangle. But with very low opacity settings, this leaves dark gray color areas instead of eventually fading to black.
It just looks ugly, so I tried another strategy here:
https://codepen.io/thykka/full/emOdrBB
(continued ๐งต...)
[#]canvas #canvasapi #generativeart #creativecoding
=> More informations about this toot | View the thread
=> This profile with reblog | Go to CFDS@vis.social account This content has been proxied by September (ba2dc).Proxy Information
text/gemini