This is a port of virtual dub's histogram equalization filter by Donald A. Graft. Based on the work by Jérémy Tran <tran.jeremy.av@gmail.com>, done for SOCIS 2012.