Add support for TIFF images in image upload process
Opened this issue · 7 comments
Images that are uploaded in the TIFF format should be converted (with transparency to the user) to PNG format for storage and later use.
Turns out only safari supports tiff images, and maybe not even officially! (https://developer.mozilla.org/en-US/docs/Web/Media/Formats/Image_types#tiff_tagged_image_file_format)
Since I don't think it makes sense for VIM to support an image format that a good chunk of potential user's browsers won't, closing this issue.
Ideally, contributors should be able to upload any image file format on any popular browsers.
We should convert all images to PNG (on the fly), unless the original was in JPEG, in which case, we can keep it in JPEG. We should do this transparently to the contributors and only let them know if we do not support the file format (e.g., text files and video files). We should allow video file uploads, but let's think about that later.
Create separate issues for uploading each file format. Start with PNG and JPEG then TIFF, etc.
As I mentioned to @Monalisa98927 there should be a second set of these images for initial display on the web page (in smaller JPEG files) for fast loading of the images. The original higher-resolution files can be displayed when the user clicks on the image. There should be a separate issue for this.
We should convert all images to PNG (on the fly), unless the original was in JPEG, in which case, we can keep it in JPEG.
What do you mean by on-the-fly here? At request time?
No, when the contributor is uploading to our website.
For example, if the contributor is uploading a TIFF file, we convert it to PNG and not keep the TIFF file.
Ok, UMIL does not currently have any infrastructure for storing images, so that's probably a first order problem (no point in converting stored images if we don't store them anywhere)?
I think we can probably hold off on dealing with our existing TIFF images until that is done?
Ok, UMIL does not currently have any infrastructure for storing images, so that's probably a first order problem (no point in converting stored images if we don't store them anywhere)?
Correct. We need the "Contribute New Instrument" page.
I think we can probably hold off on dealing with our existing TIFF images until that is done?
Yes.