Friday, April 24, 2009

Photoshop's File Format (PSD)

N.B. I'll get back to politics in a bit: I'm just a bit busy and feeling a bit jaded with politics at present.

Via Daring Fireball, the gentleman who constructed Xee, an open source image editor for Mac OS X, wins the prize for one of the most acerbic source code notations ever.
// At this point, I'd like to take a moment to speak to you about the Adobe PSD format.

//PSD is not a good format. PSD is not even a bad format. Calling it such would be an insult to other bad formats, such as PCX or JPEG. No, PSD is an abysmal format. Having worked on this code for several weeks now, my hate for PSD has grown to a raging fire that burns with the fierce passion of a million suns.

//If there are two different ways of doing something, PSD will do both, in different places. It will then make up three more ways no sane human would think of, and do those too. PSD makes inconsistency an art form. Why, for instance, did it suddenly decide that *these* particular chunks should be aligned to four bytes, and that this alignement should *not* be included in the size? Other chunks in other places are either unaligned, or aligned with the alignment included in the size. Here, though, it is not included.

//Either one of these three behaviours would be fine. A sane format would pick one. PSD, of course, uses all three, and more. Trying to get data out of a PSD file is like trying to find something in the attic of your eccentric old uncle who died in a freak freshwater shark attack on his 58th birthday. That last detail may not be important for the purposes of the simile, but at this point I am spending a lot of time imagining amusing fates for the people responsible for this Rube Goldberg of a file format.

//Earlier, I tried to get a hold of the latest specs for the PSD file format. To do this, I had to apply to them for permission to apply to them to have them consider sending me this sacred tome. This would have involved faxing them a copy of some document or other, probably signed in blood. I can only imagine that they make this process so difficult because they are intensely ashamed of having created this abomination. I was naturally not gullible enough to go through with this procedure, but if I had done so, I would have printed out every single page of the spec, and set them all on fire. Were it within my power, I would gather every single copy of those specs, and launch them on a spaceship directly into the sun.

//PSD is not my favourite file format.

No shit...

Incidentally, it seems that Adobe is coming in for a lot of stick, with the user interface in the latest version of its application bundle, Creative Suite 4, getting a sustained, comprehensive and continuing monstering over at Adobe UI Gripes.
Me moaning about shoddy UI inconsistencies and mistakes in Adobe products and how they get shittier with every release.

One of the earliest pieces posted at The Kitchen was on the theme of Adobe's purchase of its only significant competitor in the creative software industry, Macromedia, and why it was not a good move as far as users were concerned. Monopolies are never a good thing, and Adobe's subsequent progress has only served to underline this fact.

On the Mac platform, as I pointed out in a recent post, there are competitors coming through—Pixelmator and Acorn are both good and cheap—but nothing quite covers the whole Photoshop feature set. But then again, neither of those applications costs £500—more like £50.

Users—and Adobe itself—desperately need some competition, so more power to the small Mac developers: the end result will be better applications for us all.

UPDATE: Adobe's John Knack replies, and rebuts, some of the allegations about the file format, pointing out that it alows a considerable amount of backwards compatibility. He also points out, as did your humble Devil, that its growth has very much been organic.

16 comments:

Sue said...

I hate Adobe Products. I still use the last Macromedia release of Studio. It does everything I need and it's not too taxing for my laptop.

RobW said...

I like using an old version of Fireworks. It works for me and that is all I care about.

Roger Thornhill said...

And of course, sorry to politicise, is unlike the Government monopolies, Adobe at least cannot force us all to use their formats, outlaw competitors* and/or make us pay for them regardless of if we use it or not.

It is a de facto monopoly nonetheless and is behaving like one. And when you consider the power over us the State has, the fact that when it decides to extend its reach, to carve a new enclosure in our socio-economic landscape, we Libertarians scream blue murder.



* or at least force competitiors to use their formats, explain why not in great detail or have to certify those products after proving they will do x or not do y after 5 years of continuous use etc.

Stu said...

An awesome comment.

I use Pixelmator and VectorDesigner and almost manage to get away with it, though I'm no professional by any standard.

HOWEVER, you have to give Adobe a little credit for Dear Adobe, the site they set up for people to rant at them (and let them respond) and also John Knack's blog which both serve as really good resources for unhappy customers to actually talk to the company.

It would be nice if other companies were so willing to admit that they have unhappy customers as well as happy ones *cough*Microsoft*cough*Apple*cough* (although I suppose Adobe don't really have a choice on that any more)

microdave said...

My only connection with Adobe is to open
PDF files.

However I heard about Foxit Reader which I tried. It takes up a fraction of the space, and opens far quicker than Adobe Reader. Suffice to say the latter no longer resides on my hard drive...

_Felix said...

Unenforced monopolies are fine, because they aren't stable. Enforced competition, on the other hand, sucks balls. The competition commission attacking supermarkets, as it regularly does, is just an indirect way of demanding that they lower prices. Sometimes it's rational for there to be competition within a certain context, and sometimes it isn't, like when lots of companies which would like to merge are all selling virtually the same thing but putting on a show of competing in order to avoid being fined.

I rather think that Adobe buying Macromedia ought to be a match made in heaven, as far as the latest versions of the Flash authoring software go, because Flash is a brilliant format with a terrible editor, and Photoshop is a brilliant editor with feeble vector graphics tools. Haven't tried it, though, so I wouldn't know.

Ian B said...

Adobe are a successful company. I don't see any particular evidence that they're a state supported cartel. They appear to have got where they are on the strength of their products and business acumen. What is the problem here? If the moaning guy in the quote doesn't like their file format, he's not obligated to do anything to do with it. He's free to go write other code, or be a cabbage farmer or something. Nobody's forcing him.

The rant is typical coder-purist stuff, the same kind of people who want everyone to use Linux because of its purer codebase, rather than use systems like windows or the mac which they prefer for other reasons. It's focussing on one element of a product and ignoring others, like telling people they should buy a greener washing machine and ignore the fact that it doesn't get their clothes clean, because greeniness is all that counts.

I use Photoshop, day in, day out. I use it because I actually did try and use other products, including, for years, a now dead product called Picture Publisher, but ended up concluding that Photoshop was actually the best product, just as years ago I gave up on Star Office because MSOffice was just plain better for my usage. There is actually an annoying fact that mitherers tend to ignore- that market leaders often become market leaders because more of the market actually likes the damned product, and most of the market think that whatever parameter the mitherers are obsessing about just doesn't matter to them.

That is how free markets work. Each individual makes a choice in the marketplace, and their choice is the right choice for them.

Computing seems to be particularly afflicted with a foaming hatred of market leaders. The hysteria regarding Microsoft, for instance, such that a large number of nerds have devoted millions of man hours to creating another browser (and making Mozilla rich in the process) just to beat Microsoft. Mac users endlessly squeal about how the rest of the world are stupid for not appreciating their ugly, fisher price computers. People don't want to buy your damned iComputers with their "what we tell you is what you want" philosophy. We want beige boxes we can take to bits and fiddle with. Get over it.

So anyway, Photoshop has a file format. They invented it. They're entitled to fill it with whatever they like. They can swap big endian for little endian every 14 bytes and XOR every 3rd chunk with the text of Hamlet if they want to. It's their business. Literally. If people want to compete, they need to stop moaning about imaginary "monopolies" and create a better product- which, for most graphics professionals, no other company has even come close- not least for the reason that people writing stuff like the Gimp generally have no consideration for professional graphics users and all sit around their little Linux table in the pub with their halves of cider and black moaning about how everybody ought to appreciate the programming purity of their codebase, instead of concentrating on the likes of CYMK proofing.

/rant

Devil's Kitchen said...

Ian B,

"Adobe are a successful company."No one's denying that.

"I don't see any particular evidence that they're a state supported cartel."Nor did I advance any. They are, at present, an effective monopoly.

The point that I tried to make in the referenced post is that it is good for companies to have competition because it gives them an incentive to make better products. Adobe has no effective competition. Yet.

They appear to have got where they are on the strength of their products and business acumen. What is the problem here?From my point of view, the problem is that Adobe's products have become hideously bloated: code-purism is not always a bad thing.

Photoshop has gone from being a 40MB application to a 400MB application, for instance (and yes, other "big" software has also bloated).

"If the moaning guy in the quote doesn't like their file format, he's not obligated to do anything to do with it."Yes, unless he wishes his application -- a competitor -- to be able to parse said file format.

But so what: he can have a rant if he likes. Just as I can have a rant about the disgusting things that I have to do to my HTML/CSS to get IE6 to render a page even vaguely properly.

"I use Photoshop, day in, day out."As do I.

"The hysteria regarding Microsoft, for instance, such that a large number of nerds have devoted millions of man hours to creating another browser (and making Mozilla rich in the process) just to beat Microsoft."I don't really care about their motivation: the rise of standards-based browsers is a very, very good thing.

"People don't want to buy your damned iComputers with their "what we tell you is what you want" philosophy."I have pointed out before that this is a silly -- and wrong -- attitude to take.

"We want beige boxes we can take to bits and fiddle with."You want beige boxes that you want to fiddle with. The vast majority of people, on whatever OS, don't.

"So anyway, Photoshop has a file format. They invented it...They probably didn't actually. Well, not all of it. I imagine that much of the format is inherited from when Adobe bought Photoshop from Aldus (which is probably why it's such a mess).

"... which, for most graphics professionals, no other company has even come close..."I'm sorry, but my entire point is that Macromedia was very close. In fact, they were considerably stronger in some areas, e.g. vector editing.

"... not least for the reason that people writing stuff like the Gimp generally have no consideration for professional graphics users and all sit around their little Linux table in the pub with their halves of cider and black moaning about how everybody ought to appreciate the programming purity of their codebase, instead of concentrating on the likes of CYMK proofing."Ah, well, I'm absolutely with you on that point. The Gimp is a horrible piece of software.

(And, actually, where most of these Linux purists fall down is on the UI. Because they don't actually want non-purists using their products. Or, at least, I can only imagine that that is the reason.)

DK

/rant

Anonymous said...

"feeling a bit jaded with politics at present" - When are you not jaded with politics DK?

Ian B said...

I doubt anyone will make a serious competitor to Photoshop in the foreseeable future, DK. There probably isn't much of a market for one. The dangers of "monopoly" are overrated.

Once a market stabilises around a leader, so long as that leader produces a reasonable product at a reasonable price, it can hold its market dominance. The major market force in place isn't competition, it's customers getting too pissed off. That'll generally be enough to preserve the market. Thre's nothing particularly wrong with market dominance; the US government famously dragged the aluminium producers ALCOA through the courts for being a "monopoly", but the fact was they'd done nothing wrong; their product had got steadily cheaper and better, and customers were happy with it. What's the problem? Terror of monopoly leads us to demand a competitor (and then demand the government enforce competition and penalise successful companies) but the desire just to preserve the market is enough to ensure a decent product. They can't sell a product that doesn't do the job, or that is too expensive, because then they do risk being beaten by a competitor. So, it's no biggie really.

Photoshop, like any market leader, has to be a jack of all trades and appeal to millions of customers. Because it can't be a custom product for each customer, every customer will have some gripes, whether major or minor. That creates an illusion that it's not a good product, and some competitor needs to come in.

But as a compromise product, any other competitor will just be seeeking a different compromise. No product is going to please everybody. Anyone's product will have things missing some people want, and "bloat" that others don't want. It's certainly true that another product could supply a different feature set, a different compromise. But whether there's a better compromise that can take the market by storm is unlikely. Adobe have zillions of dollars, vast resources and put considerable effort into tuning their product with customer feedback, market research, ergonomics testing and so on. It's going to be hard for somebody else to produce something that millions of people are happier with.

Photoshop is basically good enough at a reasonable enough price. Unless they screw up big time, that Photoshop killer isn't going to arise, because there probably isn't something that much better than Photoshop, in terms of customer choice, that can be made. Niche applications, yes. But not another Photoshop.

the rise of standards-based browsers is a very, very good thing.I don't really agree with you there, either. Why it's better for a committee of crats to decide what everyone's product should do, rather than manufacturers presenting the market with alternatives, is beyond me, and it's certainly not the least libertarian. The slavish adherence to the idea that whatever Timbo says we should do is inherently a Good Thing depresses me. Perhaps if his little quango-in-waiting hadn't invented such a profoundly broken paradigm as CSS in the first place, you wouldn't be having so many problems trying to design web pages. If Microsoft had inflicted abominations like Float and Border Collapsing and DOM inheritance on us, they'd be pelted with well deserved rotten eggs.

assegai mike said...

As a humble Photoshop user of some 15 years, I'm still pretty happy with it (recently upped to CS4). Like most Photoshop users, I'm not that concerned about showing off how "techy" I am, rather more concerned to show my clients I'm doing a good job.

I would agree it is a tad pricy.

As for the monopoly thing and Flash (smart move), it's comforting to know that Microsoft can't have its own way in *every" sphere.

I wasn't aware that Adobe bought Photoshop from Aldus. Pagemaker certainly. Wikipedia tells us Photoshop was bought by Adobe very soon after it was invented in 1988.

I'm very grateful for Adobe introducing InDesign and showing Quark (now *there's* an arrogant, lazy vendor with an overpriced product that treats its customers like shit)where to get off.

Someone above mentioned .pdf, a format that everyone takes for granted. Invented by Adobe, open-sourced by them to the benefit of all, thus allowing many superior PDF editors and readers to spring up, eg Bluebeam PDF Revu, my own favourite. So let's give them *some* credit, eh.

And then there's John Warnock, one of my IT heroes...

Rab C. Nesbitt said...

I have not the faintest idea what you are all talking about! I did a cartwheel when I succesfully managed to cut and paste on the wife's computer last week! (No joke).

_Felix said...

Why it's better for a committee of crats to decide what everyone's product should do, rather than manufacturers presenting the market with alternatives, is beyond me, and it's certainly not the least libertarian.Most of the manufacturers are members of the committee, aren't they? And many of them make non-standard-compliant offerings at the same time as being members and debating what the standards should be. And a committee could potentially solve some kind of tragedy-of-the-commons type of problem, and nobody's compelling manufacturers to follow the standards (even if the manufacturers in question are members of the W3C), so it could very well be libertarian.

It's good to have both standards and alternative products, at the same time, quite possibly from the same companies. IE, though, makes a vague slosh in the direction of the standards without managing to be either interestingly different or properly compatible. Box model bugs, missing features and the arcane and secret haslayout rule are not innovations. Following standards properly would be better than that. (Possibly they've managed to do it by now, I haven't been paying attention.)

Tim Berners-Lee is still a cock, of course.

Anonymous said...

The hysteria regarding Microsoft, for instance, such that a large number of nerds have devoted millions of man hours to creating another browser (and making Mozilla rich in the process) just to beat Microsoft.

It's probably because IE sucked so badly at the time, and only nerds were able to do anything about it, not because they particularly hate Microsoft. After all, a lot of them still use Windows.

If you don't like what the W3C House of Commons is doing (members being ZanuMicrosoft, web conservatives and some liberal companies only used on the fringes of society), why don't you start your own Libertarian browser? How far do you think DK would get if elected to parliament and every party had its own speaker, only took questions from its own MPs and had different procedures for voting?

Standards probably allow better competition since there is a benchmark to compare products or at least one aspect of them. Just imagine if every electronics manufacturer used different plugs and sockets or printer manufacturers used different paper sizes. Incidentally, this is why DK and his buddies will need to work much harder than Ian B's "nerds" if the LPUK is going to be as successful as Firefox. (By the way, I don't use firefox and I don't approve of the things mozilla corporation are doing.)

Anonymous said...

"I don't see any particular evidence that they're a state supported cartel."

Hint: what do you think copyright is, other than a monopoly granted by the state?

FlipC said...

Ian B - And yet a market monopoly has many facets. It can lead to stagnation as why should any company alter the product by any degree larger than that needed to persuade customers to upgrade.

Any competition faces an uphill battle unless the monopoly product is flawed (with no to little competition being present) or the competing product is much better than it.

Likewise monopolies can move to quash competition. If the competing product has to have a similar price-point in order to cover initial R&D costs then the monopoly can offer limited time price incentives to force it off the market and live off the reserves built-up or still coming in from other products.

They can take the position that a short-term loss will reap a long-term gain; in such a spirit they may simply try to buy the company outright.

If the product is both better and cheaper than the monopoly's and the company is not for sale; they can plan for the future by integrating all their products.

At the same time they can use a default system that is highly complex and almost guarantees that no competitor can boast 100% compatibility.

From the competitor's point of view they need to make a product that is better, cheaper, boasts a similar UI (to prevent retraining costs) and is both 100% compatibility with all the old files their potential customers have stored and 100% compatibility with all the integrated products the monopoly produces.

Otherwise why would anyone go to the trouble of buying it over a product they know is going to work?