add support for binary pbm/pgm/ppm

Signed-off-by: niql <niqingliangl2003@gmail.com>
Merge pull request #1 from walkthetalk/master

add support for binary pbm/pgm/ppm