97
franck
3y

Found this gem on GitHub:

// 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.

Ref : https://github.com/zepouet/...

Comments
  • 6
    My belief, that Adobe sucks, is reinforced.

    https://devrant.com/rants/1204321/...
  • 1
    I've used there products for a long time and from a user point of view they are really good, perhaps they don't want people reading there proprietary file format so they did something to obfuscate them and that's why you're having such a hard time? If it really is as non sensicl as the post would have us believe, I can't imagine it wasn't done intentionally on Adobe's end? Besides if you needed to read the files couldn't you just make a macro using the built in macro engine to export the files/ layers to a more standard format?
  • 11
    Invite him to DevRant. He will be very happy to find his lost Homeland.
  • 2
    I don't understand what a dev has to do with psd?
    Also for Web development there are better tools out today as for example sketch or zeplin.
  • 3
    @hexc As far as I know (or at least in my case) the Adobe-hate is mostly due to them basically having a monopoly in graphic design software (yeah, there's GIMP and stuff, but everybody who does professional graphic design works with Adobe products). The problem is that they KNOW their customers absolutely depend on them and proceed to fuck them over repeatedly. So was Adobe afaik one of the first to have subscription-only products (and not cheap...), they force you to use their Adobe Cloud (and pay for it) and have proprietary file formats which are incompatible with pretty much everything except their own products. Just my two cents...
  • 4
    You could say they have PSD PTSD.
  • 3
    @Dollique I think he is trying to read or write to the file with a script, not designing stuff
  • 1
    @gathurian do you know that we can replace Adobe with any of the big corporate names?
  • 4
    that's what you get when 20 years of backwards compatibility is a requirement.
  • 1
    @commanderkeen why should someone have to do this? We should push using standards for the Web and not try to implement shit that won't work anyway
  • 1
    @Dollique not everything is web, I don't know - eh top of my head, maybe he is making a script that generates a mockup psd for users to download and reupload to a tshirt printing service. That seems like a real world scenario where this could be handy.
  • 1
    @commanderkeen sure, but there are a lot of better supported ways of doing this instead of using psd. Well it's most possibly a company restriction or so.
  • 0
    @Dollique but a lot of end users use psd. Personally I am a illustrator fanboy for design (specially for web)
  • 1
    @commanderkeen I see your point but it's still not optimal. But you're right there is possibly no easier solution that fits all needs atm.
  • 4
    @Dollique If you had checked the link, you'd seen its the source for Xee, an image viewer for Mac OS and iOS. Its also more than years since it was touched, so it might very well be that there were no libraries to read PSD files at that time, thus they had to develop it themselves.
  • 1
    I mean, if you compress a 1gb psd file you get a 200mb file. So yeah, I kinda gathered that this was the case.
Add Comment