Convert is a command from the ImageMagick software package that allows you to convert files between graphical formats like this:
convert scan1*.png text1.ps