Support image mask in ColorHistogram

![screenshot from 2014-12-14 16 48 15](https://cloud.githubusercontent.com/assets/40454/5426773/2866fd44-83b1-11e4-8003-9d6e98ed4e1f.png)