3 ms·
Let's say you already have image X saved, and you want to also store image Y, which is mostly similar. Take all of the pixels which are the same in both X and Y
by klodolph 9y ago
Let's say you already have image X saved, and you want to also store image Y, which is mostly similar. Take all of the pixels which are the same in both X and Y and set them to RGBA (0,0,0,0). Instead of using the Windows image viewer, write a web viewer in JavaScript. The viewer takes image X and image Y, composites them in a Canvas, converts that into an image, and then displays the result.
The extra steps with compositing in a Canvas first will prevent you from getting artifacts from scaling the images, but the artifacts may not be particularly visible.
If you are comfortable with NumPy this whole process should be fairly easy and painless. I have done something similar in the past, but it was for making animated GIFs.
If you are particularly adventurous, you could remove large chunks of the VN foreground by taking the per-pixel median value from a large stack of images that share a background. You could then use this as a base image.
- nitrogen 9y agoThis is basically how GIF works. If you have a GIF viewer that can pause and advance frame by frame, you could use GIF without the canvas needs.
- solidr53 9y agoBut the compression in GIF is so terrible that it will possibly be way bigger than individual JPEG or WEBP. I would say, go with WEBM and a mobile frame-by-frame player, there are dozens.
- Splines 9y agoAppreciate the ideas - I'll look into this. Thanks!