Script Summary: Change page's color scheme to optimize for watching videos. Can toggle on/off with a hotkey
This script changes the color scheme of video pages at YouTube, Vimeo, and any other sites you want. You can adjust the color parameters to whatever you like in the source code. The default is a black background with dark purple text, which provides nice viewing contrast and text that is readable but non-distracting.
You can always toggle to/from the original color scheme with the hotkey. By default the key is F2.
This code was derived from the Tired Eyes script by Ben Lee. Ben made a general-purpose script, but I modified it quite a bit to tailor it for watching videos. For general-purpose color toggling I recommend the Color Toggle Firefox add-on because it has several advantages over Tired Eyes:
1) It's persistent, so 1 press will keep the new color scheme until you toggle again, whereas all Greasemonkey scripts operate on a page-by-page basis.
2) It does a more precise job of preserving page elements that shouldn't be blackened out, like search boxes.
3) It toggles the color scheme even when page styles are disabled. (I sometimes disable page styles for readability using the Read Easily add-on.)