I'm not very hopeful that this is actually even possible because JPG is a lossy compression format, but I'll ask anyway.
I have some incomplete metadata about an image, and need to figure out the dimensions without loading the file into memory, or using command-line tools like imagemagick.
This is what I know:
- file format is JPG (JPG is an 8-bit image format).
- total file size is 96284 bytes.
- image width is 600 pixels.
Assuming the height could be variable, is there a mathematical equation I can use to calculate the height predictably?