Looping color on canvas
Interest in canvas (, as well as to mobile applications, leads to the revival of the former art school of eight-bit images. Effect Games ' Joe Huckaby played around with color loops, which led to somewhat stunning results .
Does anyone remember the color loop in the nineties? This technology was often used by eight-bit video games of that era to achieve interesting spectacular effects using the loop color shift method. At that time, video cards could only show 256 colors at a time, so a palette of selected colors was used. But the programmer could change this palette at his discretion, and the colors on the screen immediately changed, adjusting to it. This happened quickly, and literally did not require any additional memory.Skillful optimization also takes place here - instead of clearing and redrawing the entire scene in each frame, Joe only updates the pixels that change:
In order to achieve a quick frame change in the browser, I had to arrange a slightly crazy optimization of the engine. Display a 640x480 image with indexed color on thirty-two