You can understand why I\'m trying to find the dominant color in an image if you use Windows 7. When your mouse over a program in the taskbar, the background of that partic
Loop through all the pixel's color data and average the color values, ignore anything that is a shade of grey or transparent. I believe that is what Microsoft does in Windows 7 based on a recent blog post.
edit
The blog post: http://blogs.msdn.com/b/oldnewthing/archive/2011/12/06/10244432.aspx
This link showing how Chrome picks the dominant color may also be helpful. http://www.quora.com/Google-Chrome/How-does-Chrome-pick-the-color-for-the-stripes-on-the-Most-visited-page-thumbnails