4 ms·
This might have been because your VGA card didn't use dual ported RAM. I don't think all cards used it since it was more expensive. The safest way to ensure you
by bananaboy 11y ago
This might have been because your VGA card didn't use dual ported RAM. I don't think all cards used it since it was more expensive. The safest way to ensure you don't get snow across a wide variety of cards is to wait for the vertical retrace period before updating the palette registers. This way you update while the CRT beam is returning to the top of the screen, instead of while it is drawing in some random part of the screen and potentially reading from the palette while you are in the middle of updating it.
Also it's possible that the vertical retrace period isn't long enough to update the entire palette (i.e. you're still updating it and vertical retrace has finished, and the video card has already started redrawing the screen). This kind of depends on a number of factors - VLB/ISA/CPU speed/video card speed. You can work around it by updating smaller sections of the palette at a time (e.g. 32 colours at a time).