How to display tiff images?


#1

Is anyone displaying tiff images in Electron?
I want to allow users to open an image from their computer, including tiff, but Chromium doesn’t support them so I can’t just use <img src={yourTiff}>.

The way I see it my options are:

  1. Use something like ImageMagick to convert the file and store in temp: convert ~/my.tif /tmp/display.jpg.
  2. Use something like TiffViewer, which seems to load the tiff data into a canvas.
  3. Use something else within JS to convert to a jpg in memory and display in an <img> tag

Does anyone have any insight into the best option?
Thanks