alenxa_classic: (Default)
[personal profile] alenxa_classic
When cropping my userpics, I make sure they're under 40k in "pixel size" as Photoshop interprets it. The photographic ones usually end up about 29k. However, when they're saved, the computer gives their size as anywhere from 29k to 92k. What baffles me about this is that LJ allows me to upload them every time, no matter what the final file size actually is. Granted, I've never tried to upload a huge file I know oversteps the limits in some way, so I don't know how the gatekeeper routines work here. It just seems odd.

Date: 2004-08-04 09:29 am (UTC)
From: [identity profile] maldis.livejournal.com
Right there with you.

Date: 2004-08-04 10:32 am (UTC)
From: [identity profile] kelson.livejournal.com
One thing I've always found frustrating about the Macintosh is that reported file sizes rarely have anything to do with what's actually in the file. For instance, a page of plain text, completely raw, no formatting at all, is about 2.5 to 3 kilobytes. So I was surprised when you told me about SimpleText files being a minimum of 10 kb or 20 kb or whatever it was.

I think it's a combination of block size[1] and the resource fork. Since the resource fork is unique to the Macintosh, any cross-platform file format is going to be all in the data fork, with the exception of icons, thumbnails, etc. Photoshop usually does save thumbnails, although I have no idea how either a thumbnail or block sizing could change a 40 kb file into a 90 kb file.

[1] Block size: think of a disk as a collection of buckets, and map kilobytes to some liquid measurement (I'll use gallons). If each bucket holds 5 gallons, and you have a 10-gallon file, you split it across two buckets. But if your file is only one gallon, you don't want to mix it with anything else, so it still takes up a 5-gallon bucket.[2] Unix, and as a result DOS and Windows, tells you how much is actually in the buckets (this file contains 6 gallons), but it wouldn't surprise me if Mac OS reported based on how many buckets it fills (this file uses two 5-gallon buckets, so it takes up 10 gallons).

Which is "correct?" Both. One's more useful if you're comparing files, or if you need to estimate download/upload time. The other is more useful if you're trying to figure out how much space is left on your disk.

[2] An interesting side effect of this is that it takes more space to store a thousand 1 kb files than one 1000 kb file.

Profile

alenxa_classic: (Default)
alenxa_classic

November 2014

S M T W T F S
      1
2345678
9 101112131415
16171819202122
23242526272829
30      

Most Popular Tags

Style Credit

Expand Cut Tags

No cut tags
Page generated Jan. 13th, 2026 09:53 am
Powered by Dreamwidth Studios