Added option to use imagemagick as well as graphicsmagick for conversions based on environment variable