Create encoder-decoder of preview images so that there is no need to rely on an external file to create `.photon` files