Do one memset for left and right padding.
Remove dead code.
Remove pixel_size in rotate_pixel().

It is now specialized for PGM format.