It could very well be the cables, but where are the artifacts located on the screen? That is a huge determinant. The edges of a screen are generally warmer and so it may not be a related symptom.
But that aside, the answer you're looking for has many possibilities. My belief is simply that you have dying/near dead pixels.
TLDR: My fix was using a much shorter and better quality cable.
I managed to find a solution to this not that long ago on a brand new monitor that required me to buy a cheap 5m DVI to HDMI cable (I couldn't get anything else quickly).
Like you the problem was highly dependant on what was on screen and seemed more prevalent with darker images. When moving windows around they seemed to "push" the flickering pixels around which I found aggravating.
I tried a number of things including changing screen resolution, refresh rate, colour space (sRGB/CMYK as my graphics card supported both) and nothing at all would stop the flickering pixels.
Eventually in frustration I purchased a simple DVI to HDMI adaptor and combined with a 1.5m HDMI cable and appeared to fix the problem for me. I can only assume that due to the age of my graphics card and the questionable nature of the long cable that data signals for darker areas were somehow corrupted, perhaps something about weak signals and the 8/10b encoding. I'm not completely sure why, but this completely got rid of my flickering pixels.
-=EDIT=-
I've tried to look into what might have been causing this issue for me and so here's my disclaimer for the next bit: Here be dragons and wild guesses as to what is failing.
DVI (and HDMI) use TMDS. TDMS, according to wikipedia, uses "current mode logic (CML), DC coupled and terminated to 3.3 Volts" The effective signal path between transmitter and receiver looks something like this:
My wild guess is that due to the DC coupling at the destination the source must effectively "sink" the current out of the wire in order to produce a valid "0" on the line. A longer (and lower quality) cable will have a higer resistance and thus mean that the source must work marginally harder to pull the line low.
This is where my "weak graphics card" hypothesis comes into play. If the source is unable to completely and consistantly sink the current in the wire then by the time the destination is reading the bit pattern it may be that it reads a 1 where there should be a 0, causing a bit error. Too many bit errors lead to a pixel error and thus the pixel gets the wrong value and appears to be the wrong colour. Now the kicker is that these errors will not be completely consistant due to the source sometimes managing the job and sometimes failing.
I have a suspicion that the somewhat non-random nature of the problem is somehow also related to the 8/10b encoding which tries to achieve DC balance in the signalling protocol. My flickering was worse in particular areas, with there seeming to be some correlation between a group of dark and light mixtures making a "flicker" more likely to happen. I do not understand enough about it to form a firm idea of why it might cause the problem.
Of course, it could have just been a dodgy connector in the cable (I tried both graphics card outputs so nada there...)
Best Answer
If you can capture the effect using a screen shot program then it is likely a graphics card problem, if that doesn't work and you have to use a camera then it is likely a problem with the monitor.
I have a monitor that overheats and causes a strange collection of visual artifacts and the first step for me was to work out if it was the computer or monitor that was causing the problem. The problem is similar to yours in that the type of artifacts vary depending on what the monitor is displaying, ranging from full screen stuttering to white lines to half the screen appearing "dead" and changing the picture on screen by going between applications would recover from one set of artifacts to a different set.
In my case cooling the monitor using a desk fan pointed at the monitor eliminates the problem and has allowed me to continue to use it while I find a replacement.
Monitors do have complicated digital signal processors in them and this could be a sign that the monitor is starting to fail but in your case you still need to work out whether it is in fact the monitor or graphics card causing the problem. I would not expect it to be the graphics card, but you need to be sure.