Best Little Emulator Ever Made! - part 1/3
CC Attribution 2.0 Belgium:
You are free to use, adapt and copy, distribute and transmit the work or content in adapted or unchanged form for any legal purpose as long as the work is attributed to the author in the manner specified by the author or licensor.
Linden, Randal
Abdelghany, Mahmoud
In this interview/conversation, acclaimed emulator programmer Randal Linden takes us on a journey down the depths of reverse engineering and emulator development. Rather than editing this conversation to fit a smaller time-slot, it is split across 3 parts, with a Live Q&A at the end of part 3. Part 1 highlights: Doom FX for the SNES Bleem! Reverse engineering the MIPS R3000 The Sega Dreamcast
 Computer, it says recording, so I'm guessing it's recording. So for the people watching, so welcome to this very, very interesting thing, interview I guess for Fosdam, but I have this one with Abdul Radi, I'm the second most interesting person in this interview, and with me here is, how to describe him, well let's just say a legend, and it's my honor and privilege and extreme, extreme pleasure because I'm a huge fan to introduce Mr. Rand Lindum. Thank you very much, that's quite an introduction, I'm very, very flattered. Yeah, I've been rehearsing it for like a week, but excellent. No, it's good, it's very flattering, I've been very, very fortunate and very, very lucky. I got my start when I was very young, I had my very first program published when I was 13 on the Commodore 64, it was the Centipede clone, because back then arcade games were the in thing, and I made a Centipede clone on the Commodore 64, and it was all done in 6502 assembly language, because back then there wasn't really a C compiler, the language hadn't really come into its own yet, and so everything that you wrote on the Commodore 64 was either written in basic, or it was written in 6502, and so I've been a programmer now for as of two weeks ago, 38 years. Congratulations, I would say. Thank you, I've worked on Commodore 64, Commodore 128, I've worked on the Amiga, I've worked on PCs, I've worked on Macintosh, I worked on Nokia Symbian phones, I've worked on Android, I've worked on iOS, I've worked on Amazon Fire devices, I've worked on embedded systems, and I've written a wide range of software, I've written some video games a while ago, one of the most famous things that I've written, which is what we'll talk about today, is called Gleam, but I also wrote the very first full screen color, streamed live from disk animated game on a home computer called Dragonslayer, and I did an Amiga version of that, and it was originally on a laser disk, and the whole program fits into 8K of 68,000 codes, so the entire program for Dragonslayer is this tiny, tiny, tiny little program. This is just the code without the assets, of course. That's correct, just the code without the assets. Back then, the assets, all the original source material, the digitized material fit onto a massively huge 40 megabyte hard drive. That was the data, back then, I think it was a Conner drive, was enormous, and these days, the laptop that I'm talking to you on right now has 8 terabytes of storage, and compared to the 40 megabyte hard drive, it's minuscule, but coming from the Commodore 64 and the Commodore 128, one of the things that I learned very early on was how to keep things nice and compact and optimized, and I think that that really helped sort of direct the projects that I've worked on, and in particular, it was very helpful with BLEEM to make it possible to do some of the stuff that it did. The Centipede clone, was that like in a magazine back then? That was the way to go? No, actually it wasn't. It was actually sold, and it was sold on, if we weren't in the time of COVID, I would be talking to you from Seattle, and I would actually be able to hold up and show you the floppy disk, the 5.25 inch floppy disk, and cassette tape that Bubbles was sold on because the Commodore 64 had a 1541 disk drive, and it had a cassette tape drive as well. So it was actually a real commercial where you could go into a store back then. The only stores left these days are like EB games, but back then on every corner there was a store that had usually Commodore 64s or Amigas, and you could go into one of these stores and actually buy it. And yeah, like I said, that was a long time ago, almost 35, 45 years, long time ago. Good times, good times. So yeah, I don't know. Like I said before the video, I'm still a bit nervous, but I'll get over it a little. No, don't be nervous. But this is amazing. So yeah, so like I mentioned, one of our emails, I'm a big fan of Doom, and you worked, yeah, everybody, not everybody, but most people do, of course, it's amazing, and you worked on the amazing Doom port for the Super Nintendo. Yes. Yes. So I had started the project. I was actually working at a company called Sculptured Software at the time, and I was working on a monster truck rally game, which ended up never seeing the light of day. But it had these huge monster trucks and erased monster trucks. And at the time, the Super FX had just been announced by Nintendo. And we went to a Nintendo developer conference where it was all top secret, and they showed us at the time, Star Fox running. And everybody was so amazed that here was the Super Nintendo doing 3D. It got a standing ovation. And Sculptured had decided to do a game called Dirt Tracks FX, which is a dirt track racing game for the Super FX. And while that was in development, I ended up developing a whole development chain, an assembler, a linker, a source level debugger for the Super FX that was based on a hacked up Star Fox cartridge. We hired an electrical engineer to basically take apart the Star Fox cartridge and replace the ROM with a tiny little boot ROM that was an EEPROM and RAM. And so I then wrote a bootloader that communicated to the development system, which was based on the Amiga, that allowed you to download code to the RAM. And the whole reason all of this was done, all these complicated steps, was because there was no development system available. And the only way to get access to the Super FX chip was through the Star Fox cartridge. Because you could just go to a store and buy one. And so that's pretty much what we did. We went to the store and bought one. And the electrical engineer made this huge breadboard thing with wires and stuff coming all over the place. And all it basically did was replace the ROM with RAM. So you could download to it. And as it turns out, I have recently released, I guess maybe six months now or so, on my GitHub page. Actually, you can go to Randall Linden, R-A-M-D-A-L-L-I-M-D-E-N, all one word, dot com. And it redirects to a link tree page. And one of the links is for GitHub. And on GitHub, you can now download the entire source code for the Super Nintendo version of Doom. And you can also download the Amiga-based tool chain, which runs, if you're familiar with emulators, WinUae for Amiga. And you can actually build Doom for the Super Nintendo. I don't have the assets included because of copyrights and ownership issues. But all of the code is there. And people can take a look at it. Yeah, OK. One thing that really interested me about this particular, we should move to the other thing, the emulator thing a bit. But I can't resist, right? But one thing that really interests me was because Doom was written in C and you rewrote the whole thing in assembly. Right? Yes, yes. I had never seen the code for Doom. But I knew that the Super Effects, based on the technology and the speed and the Super Nintendo, I knew that it would be capable of making Doom. And so I wrote my own engine that did a very similar thing as Doom on the PC does, as far as the way that it internally operates. But it's all written in Super Effects GSU 2A code. And the rest of it is a tiny little bit of 65816 on the Super Nintendo that basically handles joystick input, DMA transfers, starting and stopping the Super Effects. But the game itself is, it's all written in assembly language. And it's all written in the Super Effects assembly language. It's a risk processor. It's very, very cool. It's one of my favorite architectures ever. And I've written on 6502, 68000, DSPs, 65816, 386. I've written for FPUs and GPUs and a whole bunch of other things. And the Super Effects chip design is one of the most elegant, efficient processors that I've ever seen. It's really quite a marvel. And so yes, if you go to GitHub, GitHub analyzes the code and it shows that it's 98% assembly language. And the reason that it's not 100% is because I've also included all the tools. So all the processing tools and all of those were written in C. Okay, okay, okay. Yeah, that was very interesting. So yeah, I have so many questions, but we shouldn't really talk about this, but it's so interesting. So the last thing I'm going to ask about, you know, let's talk about this afterwards. So I've got lots of time. I've allocated the whole afternoon for you. Thank you. Thank you very much. My pleasure. Let's see. Should we move on? Okay, so last question about this. So basically you actually wrote the game from scratch. It wasn't actually a port like many people think. Oh, okay. It was a totally original engine. Totally original technology. I reverse engineered dooms assets. So I saw how all of the artwork fit together. I wrote my own tool chain so that you basically could take doom assets run through the tool chain and it converted it into my format for my engine, which I call the reality engine. But yeah, it's not a port. It's a completely unique original engine that was custom made for the Super Nintendo and the Super effects. And as it turns out, since the source code release, there's there's a couple of message boards that have talked about it. And somebody came up with a brilliant idea that I wish I had thought of back when doom was was released. And that is to use the Super effects mosaic. Basically what it does is it takes pixels and it duplicates the pixels for a mosaic style effect. The doom engine that I wrote can render single pixels. But I ended up doing double pixels because it cost half as many cycles to horizontally double the pixels. And if I had thought about it a little more at the time, I would have used the Super Nintendo mosaic to do the pixel doubling in hardware. And I would have been able to write half as many pixels to RAM and almost doubled the frame rate. Okay. That's interesting. Yeah, it's well, it's it's it's if anything it's proof that no matter how good you think something is, there's always something there's always a different way and unique perspective. There's always, I like to say, always better code out there. I'm pretty pleased with the result because I think it was a technical achievement. But I also recognize that there's lots of room for improvement. And as I said, it wasn't until I released the source code and people were digging through it, and somebody had come up with this really unique idea of, oh, you can use the mosaic on the Super Nintendo hardware and it's like, oh, yeah, I wish I had thought of that. But you know, in retrospect, everything is easier. So exactly, exactly. It took 20 something years to come up with a better way of doing it. So in the big picture, it's not so bad. It's possible. It's possible. But that's amazing. That's amazing. Right. Thank you. Yeah. So this is one of the one of the things I shouldn't really talk about myself a lot. But you know, so one of the things is when I was worrying about this interview, you know, and, you know, we prepare some questions and and and I sent them over and and I was thinking, you know, so every one of these questions, we could talk like two hours about, which is interesting. But, you know, it's, I don't know if, yeah, if, you know, if we can, we can, you know, put that video up in the conference. They won't accept it. But we can start our own conference. So it'll be long that while there's a lot of as it turns out, one of the unique things about about Gleam and the PlayStation. This was back in the day when there was a lot of parts, a lot of pieces to the system. These days you've got your your GPU and you can just send down millions of polygons and textures and all that stuff is just sort of done for you. But back in the days of the Nintendo and the Super Nintendo and then the PlayStation, you really had to orchestrate and organize all of the parts, all of your graphics and your sound and your CD tracks and and your code and it had to be optimized and there's a lot of parts to talk about as far as the actual emulator goes. But then there's the whole topic of emulation in general and and how far things have come. If if anything, I think these days emulators are both easier to write and harder to write because the hardware that's being emulated is so state of the art. But they're easier in some respects, I think, because you can do a lot more high level emulation. The low level emulation is where you're sort of you're emulating the processor and you're emulating certain chips and a higher higher level emulation is is where you you know something about what you're emulating. You know something about the target device that's being emulated like it's sending down a polygon and that's sort of how BLEEM operated BLEEM knew that that when a PlayStation game did a certain sequence of operations, what it was really doing was sending down polygon coordinates to the GTE and so instead of necessarily emulating all of the really low level chip, you know chip based components, large chunks of BLEEM were emulating the intent of the PlayStation rather than the actual underlying operation of the PlayStation and that's why BLEEM could do things like especially shown off in BLEEMcast on the Dreamcast where it could really enhance the game because BLEEM wasn't trying to be a PlayStation. It was trying to do what the PlayStation did but targeted for the platform on which it was running. So on PCs that meant if you've got a 3D graphics card which back then 3D graphics cards were rare this was back in the days when you had I want to say rendition, verite, there was Voodoo, 3DFX, the diamonds, the creative cards, all the good stuff. Back then you had six or eight manufacturers that were all trying to compete in the 3D space as it was developing. Direct 3D from Microsoft was Direct 3D 1.0 and back then it was very rare for a graphics card that had 3D capabilities to do translucency. They were predominantly aimed at throwing lots of polygons at things but they didn't really do translucency and a lot of games on the PlayStation used translucency to get nice glass effects and smooth shaded effects and things like that. And so it depended on the graphics card what your results were when you were running under Blean. Different graphics cards stored internally the textures in different formats sometimes so what I would send to a graphics card would end up taking a lot more space than the PlayStation itself. And so that's why the graphics cards back then if it had 8 megabytes of memory it was enormous and these days graphics cards have gigabytes, gigs upon gigs of memory and hundreds or thousands of processors. But back then the PlayStation was a technical marvel for how they very carefully fit all the pieces together. And so that was one of I think the challenges in Blean to sort of to emulate the game but to enhance it and to take care of all of the components. Yeah but it's a very nice point right so because you mentioned the PlayStation was really a technical marvel but at the time we okay so I at least didn't understand the PlayStation as well but I did understand Blean was a technical marvel and as I you know as I gained more experience and I gained more insight into the PlayStation Blean became even more amazing right because to be able to do that right because Blean I think it ran on Pentium 150's or 160's or something like that right so and nowadays you can't even imagine something like that the PlayStation was I don't remember something like 50 megahertz I think I don't remember. 25. Yeah okay so. 25 and somewhere 33 and yes it was Sony did a brilliant job but it really was an homage to Sony and the genius of the PlayStation it was always intended as to expand the audience for PlayStation games because there was a handful of 3D games on the PC you had well or two and a half D games you had you know Doom and you had Hexen and Heretic and then you had Quake and there was Descent there was Unreal and so you had a handful of 3D games. Flight simulator never forget flight simulator. Flight simulator exactly there was there was a bunch of these but you could hold them you know in your hands whereas on the PlayStation there were hundreds of games that were all 3D that had music that had video this was back when the average CD ROM drive was either a 1X or a 2X CD ROM and to have music and video playing in a game was on the PC it was just unheard of you might have a cutscene or something like that that was umpteen megabytes of compressed video data but the PlayStation could do all that in hardware it had a custom chip called the M-Deck for motion I believe it's motion decompression engine it's it's basically um it's basically sort of like motion jpeg um and it could decode little tiny pixel blocks and when you streamed off of a CD to decode these little pixel blocks you could make full screen video um on a on a CD ROM drive that was running at you know 2X speed whereas on the PC it required multiple thousands of dollars worth of PC hardware to be able to do something like that and and here you could get a PlayStation for I want to say $1.99 or something like that so it was it was quite impressive um the way that they chose all of the components a lot of them weren't were so many components Sony being a semiconductor company had all of these chips like they had a CD ROM chip and they had a sound chip they were the ones who made the sound chip for the super nintendo it was a sony sound chip that was in the super nintendo and so they had experience especially working with nintendo I'm sure that you know the original PlayStation was a super nintendo add-on and then Sony decided to go it on their own and the rest is history as they say um but at the time BLEEM really uh was a project that was intended to bring the games all of those hundreds and hundreds of games to the millions and millions of PC users who like I said after you had your quakes and and your dooms and your flight simulator and and so on you you could play per app of the rapper or you could play ridge racer there just weren't a lot of those kinds of games on the PC and BLEEM sort of opened the door to that absolutely absolutely but it also begs the question right so so it was something very the the idea itself right it was very unique right it's like you you know people make games for computers which is you know we've been used to it for like at that point like late 90s like maybe like 10 20 years I guess right where the where the market really picked up and and and all of a sudden you have this idea I'm gonna make a commercial you know video game emulator for the PlayStation for the PC right it's like I don't know I just how did that come about right so how did it come about I was working on PC software at the time and had seen the PlayStation owned a PlayStation and Ridge racer one of my favorite games that's a very very old school game Ridge racer and and I thought to myself well if a PC is capable of running quake and it's capable of running doom certainly it's capable of running Ridge racer not that Ridge racer is by any stretch a simple game because it actually does some fairly complicated things internally which I didn't know until I was developing BLEEM itself but it just seems like sort of the planet sort of aligned and it said yes this is a good idea that that especially because when I first put the Ridge racer disk into the PC it recognized it I was stunned because there was there was a program there was graphics files there was data and it just seemed like a perfect fit to make it possible to play this game on at the time a low-end PC because most people didn't have high-end PCs but the hardware I knew would be capable of doing it it would just take an awful lot of work to get it done. Right then so this is a very good you know like they call it like a segue right so because when you put the city in the PC right so because I did the exact same thing the only thing is I stopped after that this I was amazed that the PC could read it right I had these I must do. Right like this Sony how can they mix it whatever right there. Well you want to think how can they make such a mistake but it wasn't really a mistake because it was actually brilliant Sony made it possible. It was a regular CD in the PlayStation so that it was a very efficient inexpensive component the Sony CD drives were everywhere and they I'm sure were thinking we've got the PlayStation console and the magic is in the console which it is it's got all of these custom chips that do the sound and the motion decoding and it's got the GTE for doing graphics transformations and rendering and it's got its own VRAM and it's a really sort of a dedicated arcade machine in a box whereas at the time PCs really didn't do that they they you had games on PCs and you had games for many years on PCs but the PC wasn't really targeting gamers the way it sort of turned out in the long run now now if you're a gamer you're either a hardcore console gamer or you're a PC gamer and there's the whole battle there between the two but this was just at the start where you wouldn't see the diversity of games on the PC until years later but there was on Nintendo, Super Nintendo, PlayStation, Sega Genesis, all of these older consoles that the hardware inside them was very simple compared to the PC the technology in PCs was very advanced but it wasn't really designed for graphics it wasn't really most people probably these days don't even think about oh yeah I'm gonna get this particular GPU and especially a sound card back then there was a dozen or so different sound card manufacturers did you have a creative sound blaster did you have the Disney sound plus did you all of them? Oh yeah, Hercules or whatever. Oh no exactly and the graphics ultrasound was another one these days when you buy a PC it sort of comes with all that stuff and unless you're a gamer or you're a hardcore graphics guy you don't really think about gee I want to put this particular graphics card into my machine unless you're building a custom machine but back then PCs you really have to think about it you know do I want a diamond graphics card or a voodoo graphics card or something else from 3DFX and what kind of sound card do I want and do I want a 2x CD-ROM or a 4x CD-ROM and these days CD-ROMs are even fading away because everything is all digital and it's all being streamed. Yeah, that's what I mean. So I remember if I remember correctly at least from a different interview you mentioned the next step after you know you put the CD in you went and to a bookstore and you got a MIPS manual. I did, I went to an actual, it was an actual bookstore because they still had them back then although I think Barnes and Noble is still around these days and they still sell books but it was about this thick and it was an actual MIPS R3000 manual. Okay. And I started looking through the op codes and reading the manual and sure enough when you take a look at the files that are on the disk it's actual code. There was no encryption, there was no obfuscation, nothing? No obfuscation, no encryption, no decryption, no nothing. It was here's an executable and if you looked at the executable and you looked at the op codes you could even see text often. I don't remember specifically which ones but there are a number of games that shipped with debug symbols and bugging information and yes all sorts of stuff like that which for somebody who's trying to reverse engineer a system it's like wow that's a gold mine all that information that's there but yes this was before the days where everything is encrypted and everything is hashed and everything is secure and reverse engineering starts with trying to figure out how on earth you're going to make it read a disk or what public key was used to encrypt and sign the digital manifest of something else and back then it was you know stick the disk into the PCCV wrong drive and wow there's the whole program the magic happens between reading the contents of the disk and making it actually play the game. There's a lot of steps in between the two but yeah I went to the bookstore got the MIPS manual and thankfully as it turns out didn't have to implement everything I implemented BLEEM I sort of described it on an as needed basis literally I would run a program I wrote the initial part of the emulator that it was a an interpretive emulator that basically means that I take each op code and I interpret the op code and when I came across an op code that I hadn't written support for yet I would implement it so I didn't actually write a complete processor there were op codes that didn't get implemented until months into development because no games that I was using for testing and for development and for debugging happened to use those particular op codes and so when the game was running it would just all of a sudden stop and it would in the debugger I used a debugger a very low level debugger called softice yeah it's a very very old school because the whole program was was written in x86 assembly again assembly again yeah for speed yeah and so when I came across an unimplemented op code it would just stop and then I would go ahead and I would write the code to implement the op code and then they would get a little further and get a little further get a little further and the very first time the program didn't stop I knew it was running it didn't crash because I could stop the program and see yes it's still executing code but there wasn't really a visual display that's one of the interesting things about the the PlayStation and a lot of systems that are similar to it you sort of send down a list of polygons to render and you just assume that they're going to get rendered there's there's no interaction back and forth between the the the CPU side of things and the GPU side of things at least back then there there really wasn't so like for example Ridge racers got this really beautiful waving flag beautiful you know 20 plus 30 years ago time frame and they just send down polygons and render things and they assume that the flag is being rendered and displayed yeah very udb like exactly so I was able to get a lot of code operational without having to have a lot of components fully operational and running it allowed me to develop especially the graphics side of things as I figured things out because I there was my first experience with with 3d with 3d math with you know why you would want to take two or three points and triangulate and calculate and you know certain numerical values or why it was important to know that here's the set of points and here's an average of the points because you're trying to do collision or you're trying to do z sorting for example where it's required by the program to render things in the right order and so the the PlayStation didn't have a Z buffer and a Z buffer for people that don't know allows you to specify depth it effectively is for each pixel that you draw how far away from the eye that particular pixel or texture or polygon is supposed to be and so what the PlayStation did is it assumed you would known as painters algorithm or you sorted your polygons so that's why things would sort of very so often flicker they would they would flicker because they got closer or further to the camera than another polygon that was right next to it and in one frame this one would be closer and the other frame this one would be closer and so you would see this little bit of flickering there well part of part of this lack of symbiosis lack of knowledge that yes the graphics are rendering you know with pixel precision is what allowed Bling to enhance the graphics in the first place I know when a game is sending down a polygon and the game doesn't really care most games didn't really care how the polygon actually made it to the screen and so that allowed me to separate out the CPU component from the graphics component and the motion decoding component and the sound component and all of these different things because although they were interrelated they weren't sort of lockstep where there was a lot of dependency some that's one of the flaws of doing emulation the way that game does it certain games won't run under Bling because of for example they know when they're rendering the triangles and the polygons and it's going into to video RAM they're then using the results of that video RAM rendering to do special effects like fogging and blurring and certain things like that and because Bling didn't really emulate VRAM the the same way the PlayStation graphics engine wrote and processed video graphics there are just some things that Bling would never be able to do. I wouldn't say never right. There are there are ways around it there are solutions to it but they're they're complicated and there's a lot of overhead involved and on balance the net result of being able to say here's the game and it was running at 320 by 240 but now it runs at 640 by 480 with you know full screen anti-aliasing and multi-sampled and isotropic filtering and it does all these neat things and oh yes it's running on the Sega Dreamcast instead of on the PlayStation one there's a lot to be said for for the magic of being able to take a disk from one platform and and run it on another platform and have the enhancements to it. It really yeah okay yeah I've always you know and I mentioned this I think in the questions as well but I've always wanted to ask about this is so so right why did you choose to do Blingcast instead of like Bling to you know the PlayStation 2 version right because around the same time the PlayStation 2 I think it came out I don't remember exactly 2002 2000 2001 something like that right yep yep and you being you right you know loving your technical challenges you know so yes that's true that that is very true I I love a technical challenge that's really what drives me when it comes to a project I like I like being able to do the things that people say oh this is not not possible this can't be done and then go ahead and accomplish it and the PlayStation 2 had just been announced and the Sega Dreamcast was already available and it was actually my business partner his name was David Herpelsheimer who suggested Blingcast in the first place and he just thought that that we both thought that the Dreamcast was a perfect machine it was very very well designed it it reminded me sort of of an advanced PlayStation and so I did some research into the processor and some of the technology behind the Dreamcast and decided that yes it had all of the components and hardware necessary to make Bling operational on a totally different it was to my knowledge it was one of the very first times that game console game was playable with enhancements on a competitors console at the same time that the original console was still available and in the market it I think was was unique especially definitely definitely don't get me wrong I love the Dreamcast it was it's one of my favorite consoles of all time it's actually my only the only Sega console I own and it's only and the reason for that is also the only Sega console I love and I was very you know sad to see it not gain as much success as we do yeah right so and there's a funny story so not about me but about you right so in one of the interviews as well you mentioned that you guys were actually invited to Sega right we were we were invited to Sega this is amazing but sorry yeah no no and I I I regret declining the invitation David went and Scott I think Scott Carol who is one of our attorneys he went to Sega and they flew them to Japan and they met with all of the top brass at Sega and and said effectively this is what we want to do and it was a tremendous opportunity and a tremendous honor and Sega ultimately said well we we can't really support you officially we can't really let you publish you know on on on the Dreamcast but here's a development system and here's some low level documentation and here's the phone numbers and email addresses of technical people in case you happen to have any questions but we can't really support what you're going to do and by the way there's this thing called mill CD that was only available in Japan at the time and we'll let you figure out what that means and so I reverse engineered the Sega Dreamcast because the it was called Katana the hardware system that we got on loan from Sega didn't have the mill CD support now for people that don't know what mill CD is mill CD is a regular CD wrong that was intended for like Japanese karaoke it was mill stands for I want to say multimedia interactive something and it was basically a regular CD that the Dreamcast could boot so there was this way of making manufactured discs that could run software on the Dreamcast that didn't have to be officially licensed approved or manufactured by Sega and so it was because of that the Dreamcast came into be we David made a little piece of hardware to dump the wrong from the Sega retail console because the Dreamcast development kit didn't support mill CD in fact they removed all the code that had to support reading regular CD wrong discs from the development systems they they removed it all so nobody had any idea that the Dreamcast could read regular CD wrongs and run games on them well it's sort of this is where sort of history branches at the same time that we realized that the code had to be in the retail version of the boot ROM another group in Europe called Utopia got a hold of a Sega development software kit and one of the programs that was in the software kit was a scrambler it was effectively a little tiny tool that took a program and jumbled it up in a particular order so that when you looked at the program it was all mixed up that if you put the program in this mixed up order onto a regular CD wrong the Dreamcast would boot it that was the piece of code that was missing from the Katana hardware development kits given out to all the developers so when we showed up at E3 with the bleeding cast running on the Sega Dreamcast people thought that Sega was supporting us but in fact they weren't we had reverse engineered their development system and their retail consoles and at the same time this other group of hackers reverse engineered and figured out the same kind of thing and it's sort of it was sort of bittersweet because while MilCD allowed BLEEM and BLEEMcast to exist it also opened the door for piracy on the Dreamcast which ultimately was one of the things I think that killed the platform. Yeah maybe I don't know I don't know is that I do remember that and I do remember partaking in that but those were different types but we were younger we had less money and a lot of things it's no excuse of course but. Well it is what it is I vaguely recall that and I don't remember the exact numbers but the original BLEEM on the PC was on a copy protected disc and the copy protection was broken within a day or less of it being released and the intention was because the software emulation was a work in progress the intention was that you would download the latest version from our website you put the BLEEM disc in the two would talk to each other and then you would put in a PlayStation disc and so this allowed us to update the software often and frequently I remember looking one day and wondering about piracy and BLEEM and how many pirated copies of BLEEM were out there because there were certain things that BLEEM did if it detected that it was running a pirated version and one of the technical support questions that our technical super people asked was a way of finding out were they running a real version of BLEEM or were they running a pirated version and I vaguely remember that we had 30 times the number of downloads compared to how many discs were actually sold so if we sold a thousand discs we ended up having 30,000 downloads of the BLEEM software even though we really should have only had a thousand so it sort of opened my eyes to piracy and as I said on the Dreamcast where you could get most any game and duplicate it on a regular CD-ROM it was the very same technology that made BLEEM, BLEEMcast possible but it also helped I think hurry along SEGA's demise they just couldn't compete. Yeah but instead Sony got mad at you not SEGA. Sony got mad at SEGA at D3 SEGA at their keynote mentioned BLEEM and BLEEM got a standing ovation from everybody who was attending SEGA's keynote Sony was not happy. They were not thrilled and I think partially it's because the licensing the way that games are licensed it's what's known as the Razors and Blades model where you buy a razor and the razor is inexpensive but you have to keep buying blades well the razor is the PlayStation console or the Xbox console and the blades that you have to keep buying are the games. Well if you could just go to a store and rent a game and play it on something other than the original hardware then it meant that the original hardware wasn't needed anymore and like I said I think one of the reasons that Sony was not happy with us was because people would be playing games on the PC and they'd be playing the games enhanced compared to playing it on a PlayStation. Yeah okay I'll try not to talk too much about Sony about this particular part. I have the greatest respect for Sony. Certain areas yes not this one in certain areas yes they could have come up with a better solution I think but. I think so too I wish that I wish they had seen the possibilities. I think and I don't know how the two companies are doing I think Sega saw that they could be a better software company than a hardware company and so Sega's still around today and they make great games and their games are playable on all sorts of platforms rather than on just one platform. I think especially with streaming services I think we're going to be seeing a shift where the home console isn't really a thing in the future. You subscribe to a service and the service can afford to have racks upon racks upon racks of really really really really high end hardware and the throughput the internet throughput is so high that it's just like you're playing it on a console that's that's sitting in your living room but instead of costing five or six hundred dollars to buy the console and then sixty dollars a game you're you're paying your monthly subscription fee. I think that's that's the model of where things are going who it is that ends up making the hardware I think there's probably going to be a shake out there's only going to be one or two companies that end up doing that but it would certainly put an end to console wars and things like that right now there's three or four different contenders for that market space and I still think there's a long way to go but I but I think that it's sort of ultimately the next evolution of where gaming is going to be where emulation is emulation is less critical because the hardware is more ubiquitous if that sort of makes sense. Sort of everywhere just like you get apps and you've either got an iPhone you've got an Android phone but apps these days they run on both phones and it doesn't matter what phone you've got you can still not not that the games are spectacular on either phones frankly but I think Sega I think Sega saw the writing on the wall and realized hey you know what we've we've got some great intellectual property some great characters some really great video games and and we're better as a software company than we are as a hardware company and I don't know if Microsoft and Sony and are there quite yet Google I think is going in the opposite direction where they are sort of got their hardware their Google branded hardware but then they've got their Stadia service. Yeah. This is sort of off topic from emulation. No but and about Microsoft I think Microsoft is actually like moving backwards I mean they are they're a software company and they got into the hardware game late and then they're competing the same way the other hardware companies are competing well that's nuts. It works for them and I mean they make a lot of money so they should be they are right and I'm wrong probably but you know. No you never know. I worked at Microsoft for almost 10 years. I worked on the Xbox 360. I was in the software development group. So I worked on what was called the XDK the development kit for the Xbox 360. I worked I was on a team that helped develop Kinect. Love it. I'm very sad and to see Kinect not doing as well as but I love Kinect. It has a love it had a lot of potential and I still use it or my kids use it but sorry carry on carry on sorry. No no no I think that I vaguely remember something like hearing that when Kinect came out it was the most popular accessory hardware accessory for a game console ever and it was very unique technology but I worked on Kinect. I also worked on Microsoft Band. That was the think Fitbit from Microsoft. It was a health and fitness band that did all sorts of things way way ahead of its time but Microsoft decided that that really wasn't the area they wanted to get into and so they closed down the Microsoft Band group and they offered a severance package and I said yes I'll take the severance package and take some time off and go back to my roots and that's when I developed Cyboyd. It's a 3D think Quake basically running on low end on Amazon, Fire TV stick, Fire tablets, Android devices and now working on.
 Computer, it says recording, so I'm guessing it's recording.  So for the people watching, so welcome to this very, very interesting thing, interview  I guess for Fosdam, but I have this one with Abdul Radi, I'm the second most interesting  person in this interview, and with me here is, how to describe him, well let's just say  a legend, and it's my honor and privilege and extreme, extreme pleasure because I'm  a huge fan to introduce Mr. Rand Lindum.  Thank you very much, that's quite an introduction, I'm very, very flattered.  Yeah, I've been rehearsing it for like a week, but excellent.  No, it's good, it's very flattering, I've been very, very fortunate and very, very lucky.  I got my start when I was very young, I had my very first program published when I was  13 on the Commodore 64, it was the Centipede clone, because back then arcade games were  the in thing, and I made a Centipede clone on the Commodore 64, and it was all done  in 6502 assembly language, because back then there wasn't really a C compiler, the language  hadn't really come into its own yet, and so everything that you wrote on the Commodore  64 was either written in basic, or it was written in 6502, and so I've been a programmer  now for as of two weeks ago, 38 years.  Congratulations, I would say.  Thank you, I've worked on Commodore 64, Commodore 128, I've worked on the Amiga,  I've worked on PCs, I've worked on Macintosh, I worked on Nokia Symbian phones, I've worked  on Android, I've worked on iOS, I've worked on Amazon Fire devices, I've worked on embedded  systems, and I've written a wide range of software, I've written some video games a  while ago, one of the most famous things that I've written, which is what we'll talk  about today, is called Gleam, but I also wrote the very first full screen color, streamed  live from disk animated game on a home computer called Dragonslayer, and I did an Amiga version  of that, and it was originally on a laser disk, and the whole program fits into 8K of  68,000 codes, so the entire program for Dragonslayer is this tiny, tiny, tiny little program.  This is just the code without the assets, of course.  That's correct, just the code without the assets.  Back then, the assets, all the original source material, the digitized material fit onto  a massively huge 40 megabyte hard drive.  That was the data, back then, I think it was a Conner drive, was enormous, and these days,  the laptop that I'm talking to you on right now has 8 terabytes of storage, and compared  to the 40 megabyte hard drive, it's minuscule, but coming from the Commodore 64 and the Commodore  128, one of the things that I learned very early on was how to keep things nice and compact  and optimized, and I think that that really helped sort of direct the projects that I've  worked on, and in particular, it was very helpful with BLEEM to make it possible to  do some of the stuff that it did.  The Centipede clone, was that like in a magazine back then?  That was the way to go?  No, actually it wasn't.  It was actually sold, and it was sold on, if we weren't in the time of COVID, I would  be talking to you from Seattle, and I would actually be able to hold up and show you the  floppy disk, the 5.25 inch floppy disk, and cassette tape that Bubbles was sold on because  the Commodore 64 had a 1541 disk drive, and it had a cassette tape drive as well.  So it was actually a real commercial where you could go into a store back then.  The only stores left these days are like EB games, but back then on every corner there  was a store that had usually Commodore 64s or Amigas, and you could go into one of these  stores and actually buy it.  And yeah, like I said, that was a long time ago, almost 35, 45 years, long time ago.  Good times, good times.  So yeah, I don't know.  Like I said before the video, I'm still a bit nervous, but I'll get over it a little.  No, don't be nervous.  But this is amazing.  So yeah, so like I mentioned, one of our emails, I'm a big fan of Doom, and you worked, yeah,  everybody, not everybody, but most people do, of course, it's amazing, and you worked  on the amazing Doom port for the Super Nintendo.  Yes.  Yes.  So I had started the project.  I was actually working at a company called Sculptured Software at the time, and I was  working on a monster truck rally game, which ended up never seeing the light of day.  But it had these huge monster trucks and erased monster trucks.  And at the time, the Super FX had just been announced by Nintendo.  And we went to a Nintendo developer conference where it was all top secret, and they showed  us at the time, Star Fox running.  And everybody was so amazed that here was the Super Nintendo doing 3D.  It got a standing ovation.  And Sculptured had decided to do a game called Dirt Tracks FX, which is a dirt track racing  game for the Super FX.  And while that was in development, I ended up developing a whole development chain, an  assembler, a linker, a source level debugger for the Super FX that was based on a hacked  up Star Fox cartridge.  We hired an electrical engineer to basically take apart the Star Fox cartridge and replace  the ROM with a tiny little boot ROM that was an EEPROM and RAM.  And so I then wrote a bootloader that communicated to the development system, which was based  on the Amiga, that allowed you to download code to the RAM.  And the whole reason all of this was done, all these complicated steps, was because there  was no development system available.  And the only way to get access to the Super FX chip was through the Star Fox cartridge.  Because you could just go to a store and buy one.  And so that's pretty much what we did.  We went to the store and bought one.  And the electrical engineer made this huge breadboard thing with wires and stuff coming  all over the place.  And all it basically did was replace the ROM with RAM.  So you could download to it.  And as it turns out, I have recently released, I guess maybe six months now or so, on my  GitHub page.  Actually, you can go to Randall Linden, R-A-M-D-A-L-L-I-M-D-E-N, all one word, dot com.  And it redirects to a link tree page.  And one of the links is for GitHub.  And on GitHub, you can now download the entire source code for the Super Nintendo version  of Doom.  And you can also download the Amiga-based tool chain, which runs, if you're familiar  with emulators, WinUae for Amiga.  And you can actually build Doom for the Super Nintendo.  I don't have the assets included because of copyrights and ownership issues.  But all of the code is there.  And people can take a look at it.  Yeah, OK.  One thing that really interested me about this particular, we should move to the other  thing, the emulator thing a bit.  But I can't resist, right?  But one thing that really interests me was because Doom was written in C and you rewrote  the whole thing in assembly.  Right?  Yes, yes.  I had never seen the code for Doom.  But I knew that the Super Effects, based on the technology and the speed and the Super  Nintendo, I knew that it would be capable of making Doom.  And so I wrote my own engine that did a very similar thing as Doom on the PC does, as far  as the way that it internally operates.  But it's all written in Super Effects GSU 2A code.  And the rest of it is a tiny little bit of 65816 on the Super Nintendo that basically  handles joystick input, DMA transfers, starting and stopping the Super Effects.  But the game itself is, it's all written in assembly language.  And it's all written in the Super Effects assembly language.  It's a risk processor.  It's very, very cool.  It's one of my favorite architectures ever.  And I've written on 6502, 68000, DSPs, 65816, 386.  I've written for FPUs and GPUs and a whole bunch of other things.  And the Super Effects chip design is one of the most elegant, efficient processors that  I've ever seen.  It's really quite a marvel.  And so yes, if you go to GitHub, GitHub analyzes the code and it shows that it's 98% assembly  language.  And the reason that it's not 100% is because I've also included all the tools.  So all the processing tools and all of those were written in C.  Okay, okay, okay.  Yeah, that was very interesting.  So yeah, I have so many questions, but we shouldn't really talk about this, but it's  so interesting.  So the last thing I'm going to ask about, you know, let's talk about this afterwards.  So I've got lots of time.  I've allocated the whole afternoon for you.  Thank you.  Thank you very much.  My pleasure.  Let's see.  Should we move on?  Okay, so last question about this.  So basically you actually wrote the game from scratch.  It wasn't actually a port like many people think.  Oh, okay.  It was a totally original engine.  Totally original technology.  I reverse engineered dooms assets.  So I saw how all of the artwork fit together.  I wrote my own tool chain so that you basically could take doom assets run through the tool  chain and it converted it into my format for my engine, which I call the reality engine.  But yeah, it's not a port.  It's a completely unique original engine that was custom made for the Super Nintendo and  the Super effects.  And as it turns out, since the source code release, there's there's a couple of message  boards that have talked about it.  And somebody came up with a brilliant idea that I wish I had thought of back when doom  was was released.  And that is to use the Super effects mosaic.  Basically what it does is it takes pixels and it duplicates the pixels for a mosaic  style effect.  The doom engine that I wrote can render single pixels.  But I ended up doing double pixels because it cost half as many cycles to horizontally  double the pixels.  And if I had thought about it a little more at the time, I would have used the Super Nintendo  mosaic to do the pixel doubling in hardware.  And I would have been able to write half as many pixels to RAM and almost doubled the  frame rate.  Okay.  That's interesting.  Yeah, it's well, it's it's it's if anything it's proof that no matter how good you think  something is, there's always something there's always a different way and unique perspective.  There's always, I like to say, always better code out there.  I'm pretty pleased with the result because I think it was a technical achievement.  But I also recognize that there's lots of room for improvement.  And as I said, it wasn't until I released the source code and people were digging through  it, and somebody had come up with this really unique idea of, oh, you can use the mosaic  on the Super Nintendo hardware and it's like, oh, yeah, I wish I had thought of that.  But you know, in retrospect, everything is easier.  So exactly, exactly.  It took 20 something years to come up with a better way of doing it.  So in the big picture, it's not so bad.  It's possible.  It's possible.  But that's amazing.  That's amazing.  Right.  Thank you.  Yeah.  So this is one of the one of the things I shouldn't really talk about myself a lot.  But you know, so one of the things is when I was worrying about this interview, you know,  and, you know, we prepare some questions and and and I sent them over and and I was thinking,  you know, so every one of these questions, we could talk like two hours about, which is  interesting.  But, you know, it's, I don't know if, yeah, if, you know, if we can, we can, you know,  put that video up in the conference.  They won't accept it.  But we can start our own conference.  So it'll be long that while there's a lot of as it turns out, one of the unique things  about about Gleam and the PlayStation.  This was back in the day when there was a lot of parts, a lot of pieces to the system.  These days you've got your your GPU and you can just send down millions of polygons and  textures and all that stuff is just sort of done for you.  But back in the days of the Nintendo and the Super Nintendo and then the PlayStation, you  really had to orchestrate and organize all of the parts, all of your graphics and your  sound and your CD tracks and and your code and it had to be optimized and there's a lot  of parts to talk about as far as the actual emulator goes.  But then there's the whole topic of emulation in general and and how far things have come.  If if anything, I think these days emulators are both easier to write and harder to write  because the hardware that's being emulated is so state of the art.  But they're easier in some respects, I think, because you can do a lot more high level emulation.  The low level emulation is where you're sort of you're emulating the processor and you're  emulating certain chips and a higher higher level emulation is is where you you know something  about what you're emulating.  You know something about the target device that's being emulated like it's sending down  a polygon and that's sort of how BLEEM operated BLEEM knew that that when a PlayStation game  did a certain sequence of operations, what it was really doing was sending down polygon  coordinates to the GTE and so instead of necessarily emulating all of the really low level chip,  you know chip based components, large chunks of BLEEM were emulating the intent of the PlayStation  rather than the actual underlying operation of the PlayStation and that's why BLEEM could  do things like especially shown off in BLEEMcast on the Dreamcast where it could really enhance  the game because BLEEM wasn't trying to be a PlayStation.  It was trying to do what the PlayStation did but targeted for the platform on which it  was running.  So on PCs that meant if you've got a 3D graphics card which back then 3D graphics cards were  rare this was back in the days when you had I want to say rendition, verite, there was  Voodoo, 3DFX, the diamonds, the creative cards, all the good stuff.  Back then you had six or eight manufacturers that were all trying to compete in the 3D  space as it was developing.  Direct 3D from Microsoft was Direct 3D 1.0 and back then it was very rare for a graphics  card that had 3D capabilities to do translucency.  They were predominantly aimed at throwing lots of polygons at things but they didn't  really do translucency and a lot of games on the PlayStation used translucency to get nice  glass effects and smooth shaded effects and things like that.  And so it depended on the graphics card what your results were when you were running under  Blean.  Different graphics cards stored internally the textures in different formats sometimes  so what I would send to a graphics card would end up taking a lot more space than the PlayStation  itself.  And so that's why the graphics cards back then if it had 8 megabytes of memory it was  enormous and these days graphics cards have gigabytes, gigs upon gigs of memory and hundreds  or thousands of processors.  But back then the PlayStation was a technical marvel for how they very carefully fit all  the pieces together.  And so that was one of I think the challenges in Blean to sort of to emulate the game but  to enhance it and to take care of all of the components.  Yeah but it's a very nice point right so because you mentioned the PlayStation was really a  technical marvel but at the time we okay so I at least didn't understand the PlayStation  as well but I did understand Blean was a technical marvel and as I you know as I gained more  experience and I gained more insight into the PlayStation Blean became even more amazing  right because to be able to do that right because Blean I think it ran on Pentium 150's  or 160's or something like that right so and nowadays you can't even imagine something  like that the PlayStation was I don't remember something like 50 megahertz I think I don't  remember.  25.  Yeah okay so.  25 and somewhere 33 and yes it was Sony did a brilliant job but it really was an homage  to Sony and the genius of the PlayStation it was always intended as to expand the audience  for PlayStation games because there was a handful of 3D games on the PC you had well  or two and a half D games you had you know Doom and you had Hexen and Heretic and then  you had Quake and there was Descent there was Unreal and so you had a handful of 3D games.  Flight simulator never forget flight simulator.  Flight simulator exactly there was there was a bunch of these but you could hold them you  know in your hands whereas on the PlayStation there were hundreds of games that were all  3D that had music that had video this was back when the average CD ROM drive was either  a 1X or a 2X CD ROM and to have music and video playing in a game was on the PC it was  just unheard of you might have a cutscene or something like that that was umpteen megabytes  of compressed video data but the PlayStation could do all that in hardware it had a custom  chip called the M-Deck for motion I believe it's motion decompression engine it's it's  basically um it's basically sort of like motion jpeg um and it could decode little tiny pixel  blocks and when you streamed off of a CD to decode these little pixel blocks you could  make full screen video um on a on a CD ROM drive that was running at you know 2X speed  whereas on the PC it required multiple thousands of dollars worth of PC hardware to be able  to do something like that and and here you could get a PlayStation for I want to say  $1.99 or something like that so it was it was quite impressive um the way that they chose  all of the components a lot of them weren't were so many components Sony being a semiconductor  company had all of these chips like they had a CD ROM chip and they had a sound chip they  were the ones who made the sound chip for the super nintendo it was a sony sound chip  that was in the super nintendo and so they had experience especially working with nintendo  I'm sure that you know the original PlayStation was a super nintendo add-on and then Sony  decided to go it on their own and the rest is history as they say um but at the time  BLEEM really uh was a project that was intended to bring the games all of those hundreds and  hundreds of games to the millions and millions of PC users who like I said after you had  your quakes and and your dooms and your flight simulator and and so on you you could play  per app of the rapper or you could play ridge racer there just weren't a lot of those kinds  of games on the PC and BLEEM sort of opened the door to that absolutely absolutely but  it also begs the question right so so it was something very the the idea itself right it  was very unique right it's like you you know people make games for computers which is you  know we've been used to it for like at that point like late 90s like maybe like 10 20  years I guess right where the where the market really picked up and and and all of a sudden  you have this idea I'm gonna make a commercial you know video game emulator for the PlayStation  for the PC right it's like I don't know I just how did that come about right so how did  it come about I was working on PC software at the time and had seen the PlayStation owned  a PlayStation and Ridge racer one of my favorite games that's a very very old school game Ridge  racer and and I thought to myself well if a PC is capable of running quake and it's  capable of running doom certainly it's capable of running Ridge racer not that Ridge racer  is by any stretch a simple game because it actually does some fairly complicated things  internally which I didn't know until I was developing BLEEM itself but it just seems  like sort of the planet sort of aligned and it said yes this is a good idea that that  especially because when I first put the Ridge racer disk into the PC it recognized it I  was stunned because there was there was a program there was graphics files there was  data and it just seemed like a perfect fit to make it possible to play this game on at  the time a low-end PC because most people didn't have high-end PCs but the hardware I knew  would be capable of doing it it would just take an awful lot of work to get it done.  Right then so this is a very good you know like they call it like a segue right so because  when you put the city in the PC right so because I did the exact same thing the only thing  is I stopped after that this I was amazed that the PC could read it right I had these  I must do.  Right like this Sony how can they mix it whatever right there.  Well you want to think how can they make such a mistake but it wasn't really a mistake  because it was actually brilliant Sony made it possible.  It was a regular CD in the PlayStation so that it was a very efficient inexpensive component  the Sony CD drives were everywhere and they I'm sure were thinking we've got the PlayStation  console and the magic is in the console which it is it's got all of these custom chips that  do the sound and the motion decoding and it's got the GTE for doing graphics transformations  and rendering and it's got its own VRAM and it's a really sort of a dedicated arcade machine  in a box whereas at the time PCs really didn't do that they they you had games on PCs and  you had games for many years on PCs but the PC wasn't really targeting gamers the way  it sort of turned out in the long run now now if you're a gamer you're either a hardcore  console gamer or you're a PC gamer and there's the whole battle there between the two but  this was just at the start where you wouldn't see the diversity of games on the PC until  years later but there was on Nintendo, Super Nintendo, PlayStation, Sega Genesis, all of  these older consoles that the hardware inside them was very simple compared to the PC the  technology in PCs was very advanced but it wasn't really designed for graphics it wasn't  really most people probably these days don't even think about oh yeah I'm gonna get this  particular GPU and especially a sound card back then there was a dozen or so different  sound card manufacturers did you have a creative sound blaster did you have the Disney sound  plus did you all of them? Oh yeah, Hercules or whatever. Oh no exactly and the graphics  ultrasound was another one these days when you buy a PC it sort of comes with all that  stuff and unless you're a gamer or you're a hardcore graphics guy you don't really think  about gee I want to put this particular graphics card into my machine unless you're building  a custom machine but back then PCs you really have to think about it you know do I want  a diamond graphics card or a voodoo graphics card or something else from 3DFX and what  kind of sound card do I want and do I want a 2x CD-ROM or a 4x CD-ROM and these days  CD-ROMs are even fading away because everything is all digital and it's all being streamed.  Yeah, that's what I mean. So I remember if I remember correctly at least from a different  interview you mentioned the next step after you know you put the CD in you went and to  a bookstore and you got a MIPS manual. I did, I went to an actual, it was an actual bookstore  because they still had them back then although I think Barnes and Noble is still around these  days and they still sell books but it was about this thick and it was an actual MIPS  R3000 manual. Okay. And I started looking through the op codes and reading the manual  and sure enough when you take a look at the files that are on the disk it's actual code.  There was no encryption, there was no obfuscation, nothing? No obfuscation, no encryption, no  decryption, no nothing. It was here's an executable and if you looked at the executable and you  looked at the op codes you could even see text often. I don't remember specifically  which ones but there are a number of games that shipped with debug symbols and bugging  information and yes all sorts of stuff like that which for somebody who's trying to reverse  engineer a system it's like wow that's a gold mine all that information that's there but  yes this was before the days where everything is encrypted and everything is hashed and everything  is secure and reverse engineering starts with trying to figure out how on earth you're  going to make it read a disk or what public key was used to encrypt and sign the digital  manifest of something else and back then it was you know stick the disk into the PCCV  wrong drive and wow there's the whole program the magic happens between reading the contents  of the disk and making it actually play the game. There's a lot of steps in between the  two but yeah I went to the bookstore got the MIPS manual and thankfully as it turns out  didn't have to implement everything I implemented BLEEM I sort of described it on an as needed  basis literally I would run a program I wrote the initial part of the emulator that it was  a an interpretive emulator that basically means that I take each op code and I interpret  the op code and when I came across an op code that I hadn't written support for yet I would  implement it so I didn't actually write a complete processor there were op codes that  didn't get implemented until months into development because no games that I was using for testing  and for development and for debugging happened to use those particular op codes and so when  the game was running it would just all of a sudden stop and it would in the debugger  I used a debugger a very low level debugger called softice yeah it's a very very old  school because the whole program was was written in x86 assembly again assembly again  yeah for speed yeah and so when I came across an unimplemented op code it would just stop  and then I would go ahead and I would write the code to implement the op code and then  they would get a little further and get a little further get a little further and the  very first time the program didn't stop I knew it was running it didn't crash because  I could stop the program and see yes it's still executing code but there wasn't really  a visual display that's one of the interesting things about the the PlayStation and a lot  of systems that are similar to it you sort of send down a list of polygons to render  and you just assume that they're going to get rendered there's there's no interaction  back and forth between the the the CPU side of things and the GPU side of things at least  back then there there really wasn't so like for example Ridge racers got this really beautiful  waving flag beautiful you know 20 plus 30 years ago time frame and they just send down  polygons and render things and they assume that the flag is being rendered and displayed  yeah very udb like exactly so I was able to get a lot of code operational without having  to have a lot of components fully operational and running it allowed me to develop especially  the graphics side of things as I figured things out because I there was my first experience  with with 3d with 3d math with you know why you would want to take two or three points  and triangulate and calculate and you know certain numerical values or why it was important  to know that here's the set of points and here's an average of the points because you're  trying to do collision or you're trying to do z sorting for example where it's required  by the program to render things in the right order and so the the PlayStation didn't have  a Z buffer and a Z buffer for people that don't know allows you to specify depth it effectively  is for each pixel that you draw how far away from the eye that particular pixel or texture  or polygon is supposed to be and so what the PlayStation did is it assumed you would known  as painters algorithm or you sorted your polygons so that's why things would sort of very so  often flicker they would they would flicker because they got closer or further to the  camera than another polygon that was right next to it and in one frame this one would  be closer and the other frame this one would be closer and so you would see this little  bit of flickering there well part of part of this lack of symbiosis lack of knowledge  that yes the graphics are rendering you know with pixel precision is what allowed Bling  to enhance the graphics in the first place I know when a game is sending down a polygon  and the game doesn't really care most games didn't really care how the polygon actually  made it to the screen and so that allowed me to separate out the CPU component from the  graphics component and the motion decoding component and the sound component and all  of these different things because although they were interrelated they weren't sort of  lockstep where there was a lot of dependency some that's one of the flaws of doing emulation  the way that game does it certain games won't run under Bling because of for example they  know when they're rendering the triangles and the polygons and it's going into to video  RAM they're then using the results of that video RAM rendering to do special effects  like fogging and blurring and certain things like that and because Bling didn't really  emulate VRAM the the same way the PlayStation graphics engine wrote and processed video  graphics there are just some things that Bling would never be able to do.  I wouldn't say never right.  There are there are ways around it there are solutions to it but they're they're complicated  and there's a lot of overhead involved and on balance the net result of being able to  say here's the game and it was running at 320 by 240 but now it runs at 640 by 480 with  you know full screen anti-aliasing and multi-sampled and isotropic filtering and it does all these  neat things and oh yes it's running on the Sega Dreamcast instead of on the PlayStation  one there's a lot to be said for for the magic of being able to take a disk from one platform  and and run it on another platform and have the enhancements to it.  It really yeah okay yeah I've always you know and I mentioned this I think in the questions  as well but I've always wanted to ask about this is so so right why did you choose to  do Blingcast instead of like Bling to you know the PlayStation 2 version right because around  the same time the PlayStation 2 I think it came out I don't remember exactly 2002 2000  2001 something like that right yep yep and you being you right you know loving your technical  challenges you know so yes that's true that that is very true I I love a technical challenge  that's really what drives me when it comes to a project I like I like being able to do  the things that people say oh this is not not possible this can't be done and then go  ahead and accomplish it and the PlayStation 2 had just been announced and the Sega Dreamcast  was already available and it was actually my business partner his name was David Herpelsheimer  who suggested Blingcast in the first place and he just thought that that we both thought  that the Dreamcast was a perfect machine it was very very well designed it it reminded  me sort of of an advanced PlayStation and so I did some research into the processor  and some of the technology behind the Dreamcast and decided that yes it had all of the components  and hardware necessary to make Bling operational on a totally different it was to my knowledge  it was one of the very first times that game console game was playable with enhancements  on a competitors console at the same time that the original console was still available  and in the market it I think was was unique especially definitely definitely don't get  me wrong I love the Dreamcast it was it's one of my favorite consoles of all time it's  actually my only the only Sega console I own and it's only and the reason for that is also  the only Sega console I love and I was very you know sad to see it not gain as much success  as we do yeah right so and there's a funny story so not about me but about you right  so in one of the interviews as well you mentioned that you guys were actually invited to Sega  right we were we were invited to Sega this is amazing but sorry yeah no no and I I I  regret declining the invitation David went and Scott I think Scott Carol who is one of  our attorneys he went to Sega and they flew them to Japan and they met with all of the  top brass at Sega and and said effectively this is what we want to do and it was a tremendous  opportunity and a tremendous honor and Sega ultimately said well we we can't really support  you officially we can't really let you publish you know on on on the Dreamcast but here's  a development system and here's some low level documentation and here's the phone numbers  and email addresses of technical people in case you happen to have any questions but  we can't really support what you're going to do and by the way there's this thing called  mill CD that was only available in Japan at the time and we'll let you figure out what  that means and so I reverse engineered the Sega Dreamcast because the it was called Katana  the hardware system that we got on loan from Sega didn't have the mill CD support now for  people that don't know what mill CD is mill CD is a regular CD wrong that was intended  for like Japanese karaoke it was mill stands for I want to say multimedia interactive  something and it was basically a regular CD that the Dreamcast could boot so there was  this way of making manufactured discs that could run software on the Dreamcast that didn't  have to be officially licensed approved or manufactured by Sega and so it was because  of that the Dreamcast came into be we David made a little piece of hardware to dump the  wrong from the Sega retail console because the Dreamcast development kit didn't support  mill CD in fact they removed all the code that had to support reading regular CD wrong  discs from the development systems they they removed it all so nobody had any idea that  the Dreamcast could read regular CD wrongs and run games on them well it's sort of this  is where sort of history branches at the same time that we realized that the code had to  be in the retail version of the boot ROM another group in Europe called Utopia got a hold of  a Sega development software kit and one of the programs that was in the software kit  was a scrambler it was effectively a little tiny tool that took a program and jumbled  it up in a particular order so that when you looked at the program it was all mixed up  that if you put the program in this mixed up order onto a regular CD wrong the Dreamcast  would boot it that was the piece of code that was missing from the Katana hardware development  kits given out to all the developers so when we showed up at E3 with the bleeding cast  running on the Sega Dreamcast people thought that Sega was supporting us but in fact they  weren't we had reverse engineered their development system and their retail consoles and at the  same time this other group of hackers reverse engineered and figured out the same kind of  thing and it's sort of it was sort of bittersweet because while MilCD allowed BLEEM and BLEEMcast  to exist it also opened the door for piracy on the Dreamcast which ultimately was one  of the things I think that killed the platform.  Yeah maybe I don't know I don't know is that I do remember that and I do remember partaking  in that but those were different types but we were younger we had less money and a lot  of things it's no excuse of course but.  Well it is what it is I vaguely recall that and I don't remember the exact numbers but  the original BLEEM on the PC was on a copy protected disc and the copy protection was  broken within a day or less of it being released and the intention was because the software  emulation was a work in progress the intention was that you would download the latest version  from our website you put the BLEEM disc in the two would talk to each other and then  you would put in a PlayStation disc and so this allowed us to update the software often  and frequently I remember looking one day and wondering about piracy and BLEEM and how  many pirated copies of BLEEM were out there because there were certain things that BLEEM  did if it detected that it was running a pirated version and one of the technical support questions  that our technical super people asked was a way of finding out were they running a real  version of BLEEM or were they running a pirated version and I vaguely remember that we had  30 times the number of downloads compared to how many discs were actually sold so if  we sold a thousand discs we ended up having 30,000 downloads of the BLEEM software even  though we really should have only had a thousand so it sort of opened my eyes to piracy and  as I said on the Dreamcast where you could get most any game and duplicate it on a regular  CD-ROM it was the very same technology that made BLEEM, BLEEMcast possible but it also  helped I think hurry along SEGA's demise they just couldn't compete.  Yeah but instead Sony got mad at you not SEGA.  Sony got mad at SEGA at D3 SEGA at their keynote mentioned BLEEM and BLEEM got a standing ovation  from everybody who was attending SEGA's keynote Sony was not happy.  They were not thrilled and I think partially it's because the licensing the way that games  are licensed it's what's known as the Razors and Blades model where you buy a razor and  the razor is inexpensive but you have to keep buying blades well the razor is the PlayStation  console or the Xbox console and the blades that you have to keep buying are the games.  Well if you could just go to a store and rent a game and play it on something other than  the original hardware then it meant that the original hardware wasn't needed anymore and  like I said I think one of the reasons that Sony was not happy with us was because people  would be playing games on the PC and they'd be playing the games enhanced compared to  playing it on a PlayStation.  Yeah okay I'll try not to talk too much about Sony about this particular part.  I have the greatest respect for Sony.  Certain areas yes not this one in certain areas yes they could have come up with a better  solution I think but.  I think so too I wish that I wish they had seen the possibilities.  I think and I don't know how the two companies are doing I think Sega saw that they could  be a better software company than a hardware company and so Sega's still around today and  they make great games and their games are playable on all sorts of platforms rather than on just  one platform.  I think especially with streaming services I think we're going to be seeing a shift where  the home console isn't really a thing in the future.  You subscribe to a service and the service can afford to have racks upon racks upon racks  of really really really really high end hardware and the throughput the internet throughput  is so high that it's just like you're playing it on a console that's that's sitting in your  living room but instead of costing five or six hundred dollars to buy the console and  then sixty dollars a game you're you're paying your monthly subscription fee.  I think that's that's the model of where things are going who it is that ends up making the  hardware I think there's probably going to be a shake out there's only going to be one  or two companies that end up doing that but it would certainly put an end to console wars  and things like that right now there's three or four different contenders for that market  space and I still think there's a long way to go but I but I think that it's sort of  ultimately the next evolution of where gaming is going to be where emulation is emulation  is less critical because the hardware is more ubiquitous if that sort of makes sense.  Sort of everywhere just like you get apps and you've either got an iPhone you've got  an Android phone but apps these days they run on both phones and it doesn't matter what  phone you've got you can still not not that the games are spectacular on either phones  frankly but I think Sega I think Sega saw the writing on the wall and realized hey you  know what we've we've got some great intellectual property some great characters some really  great video games and and we're better as a software company than we are as a hardware  company and I don't know if Microsoft and Sony and are there quite yet Google I think  is going in the opposite direction where they are sort of got their hardware their Google  branded hardware but then they've got their Stadia service.  Yeah.  This is sort of off topic from emulation.  No but and about Microsoft I think Microsoft is actually like moving backwards I mean they  are they're a software company and they got into the hardware game late and then they're  competing the same way the other hardware companies are competing well that's nuts.  It works for them and I mean they make a lot of money so they should be they are right  and I'm wrong probably but you know.  No you never know.  I worked at Microsoft for almost 10 years.  I worked on the Xbox 360.  I was in the software development group.  So I worked on what was called the XDK the development kit for the Xbox 360.  I worked I was on a team that helped develop Kinect.  Love it.  I'm very sad and to see Kinect not doing as well as but I love Kinect.  It has a love it had a lot of potential and I still use it or my kids use it but sorry  carry on carry on sorry.  No no no I think that I vaguely remember something like hearing that when Kinect came  out it was the most popular accessory hardware accessory for a game console ever and it was  very unique technology but I worked on Kinect.  I also worked on Microsoft Band.  That was the think Fitbit from Microsoft.  It was a health and fitness band that did all sorts of things way way ahead of its time  but Microsoft decided that that really wasn't the area they wanted to get into and so they  closed down the Microsoft Band group and they offered a severance package and I said yes  I'll take the severance package and take some time off and go back to my roots and that's  when I developed Cyboyd.  It's a 3D think Quake basically running on low end on Amazon, Fire TV stick, Fire tablets,  Android devices and now working on.
bleem_part1_0_179.png bleem_part1_180_263.png bleem_part1_264_335.png bleem_part1_336_707.png bleem_part1_708_779.png bleem_part1_780_947.png bleem_part1_948_1019.png bleem_part1_1020_1175.png bleem_part1_1176_1307.png bleem_part1_1308_1415.png bleem_part1_1416_2015.png bleem_part1_2016_2087.png bleem_part1_2088_2339.png bleem_part1_2340_3839.png bleem_part1_3840_4607.png bleem_part1_4608_4655.png bleem_part1_4656_4727.png bleem_part1_4728_5147.png bleem_part1_5148_5219.png bleem_part1_5220_6923.png bleem_part1_6924_7175.png bleem_part1_7176_7259.png bleem_part1_7260_7607.png bleem_part1_7608_7691.png bleem_part1_7692_7871.png bleem_part1_7872_7943.png bleem_part1_7944_8207.png bleem_part1_8208_8279.png bleem_part1_8280_8927.png bleem_part1_8928_9287.png bleem_part1_9288_9383.png bleem_part1_9384_9611.png bleem_part1_9612_9935.png bleem_part1_9936_25703.png bleem_part1_25704_43919.png bleem_part1_43920_45071.png bleem_part1_45072_45455.png bleem_part1_45456_45515.png bleem_part1_45516_45587.png bleem_part1_45588_49535.png bleem_part1_49536_49607.png bleem_part1_49608_49679.png bleem_part1_49680_49787.png bleem_part1_49788_51347.png bleem_part1_51348_69587.png bleem_part1_69588_71639.png bleem_part1_71640_71735.png bleem_part1_71736_72119.png bleem_part1_72120_72911.png bleem_part1_72912_74027.png bleem_part1_74028_74795.png bleem_part1_74796_80639.png bleem_part1_80640_80903.png bleem_part1_80904_80975.png bleem_part1_80976_81083.png bleem_part1_81084_84419.png bleem_part1_84420_84527.png bleem_part1_84528_84983.png bleem_part1_84984_85055.png bleem_part1_85056_86927.png bleem_part1_86928_87083.png bleem_part1_87084_87215.png bleem_part1_87216_87467.png bleem_part1_87468_88187.png bleem_part1_88188_88259.png bleem_part1_88260_88379.png bleem_part1_88380_96815.png bleem_part1_96816_96934.png