So, if I have an image in BMP file format being 1024 x 768 and 8 bits (bit depth), I can get the size of the image: 1024 x 768 x 8 = 6,291,456; 6,291,456 / 8 x 1024 = 768 Kb, which is correct when I right click on an image and see its size.
Now, if I do the same thing with a JPG or PNG image, I don't get the same file size because JPG and PNG are compressed formats and thus have smaller file sizes.
Is there a way that I can find how much are those JPG and PNG images compressed? Like a percentage value maybe?