Off topic-ish: There was a trick you could use on the Atari ST to display more than the allowed number of colours - you reloaded the palette data on each horizontal interrupt. Could this have been used on the C64 also?
You could do this on the Amstrad CPC (and many people did, mostly but not exclusively demo coders). The CPC had a palette of 27 possible colours, of which 16, 4, or 2 could be shown at once, depending on screen resolution (160px, 320px, 640px respectively, all x 200px). By reprogramming the palette selection on the fly, using two successive writes to output port &7F00, you could change the palette as the electron beam moved down the screen. You could even do it mid-screen row if your timing was good!
Talking of the Atari ST, there was an excellent example of this colour-switching in an ST software utility called Photochrome, which could use overscan effects, multiple palette switches per line, plus the colour switching technique in this article to greatly increase the number of perceived colours. It's the best example of this colour switching technique I've seen with barely any noticeable flicker (on a CRT-TV anyway). Seeing what was effectively a 'true colour' image coming from a machine that's only supposed to be capable of 16 indexed colours was a very impressive feat.
But you could interrupt the CPU from the graphics chip based on scan line (just in case that's the part GP was interested in), for instance to do a classical graphics/text screen split or replicate sprites.
"Raster bar" type graphics were a specialty of the Atari 2600 and 800, and the Commodore Amiga(all Jay Miner-led designs), and starting with the 800, they had programmable "display list interrupts" built into their graphics chips which would let you switch between the various graphics modes and scroll, as well as change the palette. This effect is used all over the place to make nice sky and horizon gradients, to make text and objects look shiny, or to do fades.
The C64 missed out on some of this programmability, but had other goodies to compensate(more sophisticated sprite hardware, a really solid default palette).
Absolutely. The c64 had a bunch of things that was global, but could be changed per scanline, like graphics mode, border color, background color, sprite positions/bitmaps/colors, character offset, etc.
You could actually change them mid scanline too, but it was tricky to get the timing right, so the exact pixel of the change would be a bit random.