For Your Inspection: Source Code For Photoshop 1.0
gbooch writes "With the permission of Adobe Systems, the Computer History Museum has made available the source code for Photoshop version 1.0.1, comprising about 128,000 lines of code within 179 files, most of which is in Pascal, the remainder in 68000 assembly language. This the kind of code I aspire to write. The Computer History Museum has earlier made available the source code to MacPaint."
I'll just compile and run it to see.
Well, it doesn't seem to show anythALL HAIL STEVE JOBS! STEVE JOBS IS MY MASTER!
503 Service Unavailable
No server is available to handle this request.
At least they still have servers available to tell us that they don't have servers available.
Better known as 318230.
Here, I'll post it here to save you time:
503 Service Unavailable
No server is available to handle this request.
Not sure what language that's in.
Do you have ESP?
Turbo Pascal was pretty much the first decent IDE for Windows AFAIR.
Korma: Good
...and good. I miss those times.
I miss stuff which opened instantly and worked quickly. Where a faster PC actually meant things getting done quicker, rather than an opportunity to shim in another layer of crapware designed by a 3rd party half way across the world to find its way into your ever-less-steady stack of shit.
Windows 95 on a PC from 2000 runs way faster than XP on a 2010 PC, and both are faster than Windows Vista/7/8 on a modern PC. Why don't people make that effort any more? It's not as if using shitty pre-built components saves development time: learning all their quirks and bugs is often more time-consuming than just rewriting from scratch. Is it just that Twenty-First Century Capitalism thing where every useless leech has to take a cut, so it would be Unholy to properly develop in-house and on-shore?
Photoshop 1 was only available on a Mac. I remember receiving the first "public beta" (Photoshop 0.9) some time in 1990 or so and it was awesome - jawdroppping awesome...
In any case, you would use MPW (Macintosh Programmer's Workshop) those days, which I think is still one of the best team-development tools. And the language-of-choice (well, in fact, nearly the only choice) for developing on a Mac at those days was Pascal + Assembler.
So, it makes sense that this code is Pascal.
Interestingly this code is supposedly in there. (According to the comments on the page). Somebody should check the Adobe code...
According to this version table CMYK arrived at 2.0
http://en.wikipedia.org/wiki/Adobe_Photoshop_version_history
Shouldn't be too much of a stretch since this was written using Free Pascal.
Hopefully the Gimp folks can make some use of this.
Some kind soul put up this mirror on GitHub.
Any sufficiently advanced bug is indistinguishable from a feature.
Apple made the choice. Pascal was the standard development language for Lisa and MacOS.
Do you even lift?
These aren't the 'roids you're looking for.
No. Photoshop was long ago rewritten into C++. That's not to say that some of the current code might not have some basis on the original code, but it's doubtful it's that much.
Seems to be a few mirrors on pirate bay, too.
Do you even lift?
These aren't the 'roids you're looking for.
Highly unlikely. Photoshop 1.0 was 1990 and it was an application. That's like expecting Windows 3.0 to be using the same code as Windows 8 - sure there might be some similarity but most of Windows 3.0 and its features don't even exist in Windows any more (and haven't for many, many years).
With an application, it's also much easier to just rewrite every version - the only "compatibility" you have to worry about is that you can read the old files generated by the program (writing new file formats is common practice, but you need to be able to read the previous ones back in even if just for a one-time conversion). Think the very first Word for Windows versus Word 2013 / 365. The program itself doesn't even open files that old any more (compatibility only goes back to Word 97/2000 at best nowadays), so the likelihood of any code being more than vaguely similar is almost zero.
Plus, given that the original is in Pascal and 68k assembler, the chance is basically zero. At the point that it had to be rewritten for newer languages / platforms (even if they ran 68k code, it's unlikely to be perfectly compatible), the old code would be ditched and used - at best - as a reference to how the program used to work.
Code evolves or dies. This code-drop is pretty ancient in computing terms and won't be of any practical use any more - like when they released the original Prince of Persia source in assembler. At best, you could use it as a reference to make a pixel-for-pixel identical version by rewriting it in a sensible language and making sure it is equivalent to the old code, but that's about the only use of it.
Have a look here:
http://creativebits.org/the_first_version_of_photoshop
You could just about put some text into it. It's like looking at the source code to Word for DOS 5 and saying "Is this any good to anyone?" No. Not really. Maybe 20 years ago, but now it's so obsolete we don't even use the program itself, let alone the code that makes it, and haven't for 15 years.
Has anybody run it in a 68k Mac emulator? It would be interesting to see a performance comparison between modern PhotoShop running natively and version 1 running on an emulator.
The world is made by those who show up for the job.
Actually it's pretty close (UCSD dialect) until you get to the OBJECT keyword. Apple made full use of their Memory Manager for Object Pascal, which had a linear address space and supported relocatable objects, while Borland had a horrible memory allocator and was stuck with the 80x86 real-mode memory model and 640k limit. So they implemented "Object Pascal" as some kind of horrible C++ish hack. It was really and truly awful compared to the Object Pascal that Apple had already produced, though I hear they filed down some of the worst warts by the time of Delphi.
Oddly, this code didn't make use of the Pascal UNIT system for its own code, instead using multiple levels of include files, with the main code for a unit in "foo.inc1.p". This was probably done to make it work well with makefiles. Back in the day it took long enough to compile that you really didn't want to re-compile anything you didn't have to, and if you did things the "proper" way, code and headers would be in the same file, causing a lot of unnecessary recompilation.
#naabhaprzrag, #sverubfr-000, #agi-fcbafberq, negvpyr[pynff*=' negvpyr-ary-'] { qvfcynl: abar !vzcbegnag; }
I love tapioca!
Yeah, C++, C#, VB.NET and F# are ALL dying languages. Fucking moron.
F# ? I agree it's not dying, but only because it never lived.
More Twoson than Cupertino
Note that Photoshop 1.0 was a one-man app...and Knoll still works on Lightroom.
People today don't realize how mind-blowing Photoshop was back in the day. Nobody in real life did image editing - it was all airbrushing, paste-up, etc.
Anyway, good reading:
http://www.theverge.com/2013/2/13/3959868/photoshop-is-a-city-for-everyone-how-adobe-endlessly-rebuilds-its
You could just about put some text into it. It's like looking at the source code to Word for DOS 5 and saying "Is this any good to anyone?" No. Not really. Maybe 20 years ago, but now it's so obsolete we don't even use the program itself, let alone the code that makes it, and haven't for 15 years.
But wouldn't it be educational for someone who was going to write a word processor to see what you could achieve with 640K RAM and 720K floppy disk storage limits?
To have a right to do a thing is not at all the same as to be right in doing it
Supposedly it's in macpaint...according to the comments section of the story.
A smart programmer. It's a shame that language-wise things have gone so far downhill since then.
Actually, that was Delphi. Turbo Pascal was one of the first IDEs for DOS.
Turbo Pascal rocked. Ignoring all the "it's pascal so it must suck" idiocy being posted, Turbo Pascal changed PC programming. The only compilers besides MASM were too expensive for a college student to touch and slower than Christmas to compile, but TP was $99 and screaming fast. I got a copy and that started a 25 year career in programming, almost exclusively using Borland products and building just about everything you can imagine with them. I get it that Photoshop was first written to run on Apple, but TP was more than just a hobby compiler, and really the best choice at the time for doing any serious work on a PC.
*** *** You're just jealous 'cause the voices talk to me... ***