loaders/image_r: cleanup image type detection code
loaders/tiff: autodetect and save transparent images
loaders: gif support (read only, no transparency)