It would be great if Hyperion could automatically resize images as appropriate. We would like the following capabilities:

  • Hyperion.resizeImage is a message that takes image data (as returned by Aeon) and a size and returns the same image resized. Ideally, we would cache the resized image somewhere so we don't have to constantly resize it.
  • We probably need a HEXM directive to return an URL to a resized image given a local URL to a static image.
  • Ultimately, of course, we would want other kinds of basic processing on the image (grayscale, etc.).

Progress

  • 2019-02-26: Finished implementing the cache and image resize. End-to-end path works on http://multiverse.benedict.com/imageList.hexm. Need to test cache use; need to add cache stats and diagnostics; need to deploy to multiverse.kronosaur.com.
  • 2019-02-25: JPEG library can save images (see X5 project). Hyperion has a cache and can currently respond to Hyperion.resizeImage but returns a full-sized image. Need to add code to resize the image. We also still need to add code to invalidate the cache.