Bit Blit Algorithm (Amiga Blitter Chip) - Computerphile

  Рет қаралды 109,168

Computerphile

Computerphile

Күн бұрын

The Bit Blit algorithm dates back to Xerox PARC, but was famously used to sell the Amiga home computer among others. Dr Steve Bagley takes us through how it works.
This is a re-upload due to an audio problem on the earlier edit -Sean
/ computerphile
/ computer_phile
This video was filmed and edited by Sean Riley.
Computer Science at the University of Nottingham: bit.ly/nottscomputer
Computerphile is a sister project to Brady Haran's Numberphile. More at www.bradyharan.com

Пікірлер: 272
@laurencevanhelsuwe3052
@laurencevanhelsuwe3052 2 жыл бұрын
The Amiga blitter also had something amazing (for that time): a mode to render lines. If I remember correctly it implemented Bresenham's line drawing algorithm.. in hardware. This was pretty mindblowing stuff, at the time. I got it to work (banging pure hardware) and managed to get a wireframe space shuttle rotating smoothly on the screen. Those were the days.
@eadweard.
@eadweard. 2 жыл бұрын
What do you mean "banging"?
@laurencevanhelsuwe3052
@laurencevanhelsuwe3052 2 жыл бұрын
@@eadweard. Banging = just writing to the blitter registers. If my memory doesn't fail me, the hard part was that your code needed to figure out in which of 8 octants the line would fall into.. this information was needed by the blitter to properly render the line. So it wasn't as simple as passing (x1,y1) and (x2, y2) to the registers..
@eadweard.
@eadweard. 2 жыл бұрын
@@laurencevanhelsuwe3052 oh right thanks I thought at first it was some kind of depravity.
@Michaeltroughton
@Michaeltroughton 2 жыл бұрын
@@laurencevanhelsuwe3052 I wrote a lot of stuff for the Amiga back in my youth, and started doing some programming on it again recently to render filled vector objects. Getting the line drawing code right is quite finnicky as you say. The Amiga also had a primitive polygon filling operation built into the blitter, which had some subtleties to overcome when used with the line drawing hardware. Amazing machine for it's time though.
@jkdsteve
@jkdsteve 2 жыл бұрын
@@eadweard. It definitely is and a great time in history of programming :D
@ScottLahteine
@ScottLahteine 2 жыл бұрын
For my 1990 Amiga game "Dino Wars" I went "straight to the hardware" for everything, bypassing the OS, and there is a lot of unique and clever use of the Blitter to optimize drawing of large graphics. Specifically, I implemented a "blit strips" compression/decompression algorithm that divided up all the large dinosaur bitmaps into vertical strips, only where the data was non-zero, and with a minimum gap between strips. All the size and blitter setup info is interspersed in the data, so it is read sequentially during the full blit operation. The Amiga also used "bit planes" for its graphics, so the bits in each plane always correspond to one pixel. This meant that some of the data planes in the source graphics were mostly empty. The mask -which is just an OR of all the planes in the bitmap- was the largest blob of data, but also the most vital, as it was used to do "cookie cutter" operations. And, depending on how the image mask was applied to the bit planes, the graphics could be made to use different parts of the color palette, so the same bitmap data could be used to draw different colored dinosaurs. Even though the blit strips method uses the CPU a lot more during drawing, since the overall strip-compressed data size was a lot smaller than the raw rectangle the end result was much faster drawing. On top of using the blitter in this clever manner, I also ended up writing blitter code to handle the MFM (or was it GCR?) floppy disk encoding/decoding because I even bypassed the OS for disk I/O. I no longer have the originsl source code, but someday I hope to use the debug monitor in an Amiga emulator to extract some of these cool bits and showcase them someplace for posterity. I know of no other game that thought to employ the blitter in just this way.
@noor-rx1ij
@noor-rx1ij 2 жыл бұрын
Would be really nice to see a more detailed writeup on this!
@isyt1
@isyt1 2 жыл бұрын
@@noor-rx1ij agreed
@Lynxxde
@Lynxxde 2 жыл бұрын
Nice to see a Amiga featured in a Computerphile video, but the amiga blitter was much more complex, it could for example combine 3 sources in one operation, for example a char of a font, a mask which defines which pixels to copy over, the destination (yes as source also) and the destination again, so that only the bits set in the mask are blitted over, at the same time the barrelshifter could shift the whole operation multiple bits to the side (for pixelexact placement/scrolling), it could also draw lines, fill outlines, all this made the amiga far ahead of any pc for a long time, when 386 with ~80Mhz and the first Geforce cards showed up pc slowly had the same power as an plain Amiga 500 with 68000@7Mhz.
@desertfish74
@desertfish74 2 жыл бұрын
Was looking for this comment. The Amiga’s blitter could be used to paint filled polygon 3d graphics with the right setups
@dansalvato
@dansalvato 2 жыл бұрын
I love Amiga and never expected this crossover! I always think about the blitter and how it could be leveraged to create really interesting visual effects and blazing fast graphics, but specifically if the application/game is designed with the blitter in mind (like many demos are). I think the blitter was more often used to emulate "chunky" graphics. It made sense during a time where such colorful 16-bit graphics was a cutting-edge novelty, and games were often even marketed with having "arcade-quality" visuals. But the gaming landscape is so different now - especially in the indie space, we prioritize design so much more than "realistic" graphics, and I think that opens up a world of potential for Amiga and its powerful and unique blitter. Seeing releases like Sam's Journey for C64 and Micro Mages for NES makes me excited for the future of our favorite retro platforms!
@treyquattro
@treyquattro 2 жыл бұрын
should have mentioned that "blt" is short for block transfer
@MePeterNicholls
@MePeterNicholls 2 жыл бұрын
But what if The Master gets in and corrupts the process?! It’ll be Logopolis all over again 😫
@MolenTheGreat
@MolenTheGreat 2 жыл бұрын
tf you mean? blt stands for bacon lettuce tomato smh
@paulturner5769
@paulturner5769 2 жыл бұрын
In the day, Bit Block Transfers were called 'Bit Blot' operations and Block Image Transfers were called 'Blit' operations. The real trickiness happens with blitting, on screen or off, when the source and target rectangles memory regions overlap, then you might have to read rows, or columns, or both in reverse order to not wreck the source data during the copy. I worked on coin-op conversions back in the 6502 and Z80 days. Non-contiguous display memory rows like the Apple ][ were a pain!
@captainboing
@captainboing 2 жыл бұрын
... and blitter = BLock Image Transferrer. When the ST finally got some more advanced gfx hardware, I heard it called a "blimmer" which was a block image manipulator. Mag article and jealousy slap at Amiga hw
@fiona9891
@fiona9891 2 жыл бұрын
yum, virtual burguer
@PregnantSausage
@PregnantSausage 2 жыл бұрын
The Amiga was one helluva brilliant machine.
@zanesthename
@zanesthename 2 жыл бұрын
I learned that from the book Smalltalk 80 and later used it to implement the display for the first raster-scanned anti-aliased heart monitor. Previous to that vector displays, large, heavy, power guzzlers, were used by all displays.
@squishmastah4682
@squishmastah4682 2 жыл бұрын
Sounds like a definite win.
@zanesthename
@zanesthename 2 жыл бұрын
@@squishmastah4682 Thanks yeah, it was interesting. Either directly from Smalltalk 80 or something else I had read I learned that if you have a monochrome display where each pixel has several levels of intensity you could make it appear that a pixel was located somewhere between two pixels by appropriately setting the intensity of those pixels. That let me make a smooth curve even on the then low-resolution displays.
@paulturner5769
@paulturner5769 2 жыл бұрын
@@zanesthename You were lucky! Getting to play with anti-aliasing while I was busy fixing S.E Labs (later Thorn EMI) CardioStore heart monitors. :-)
@isyt1
@isyt1 2 жыл бұрын
Love this. As a middle aged software engineer who grew up learning to code on amigas and Atari st’s I had no idea what was going on under the bonnet. Brilliant video!
@tramsgar
@tramsgar 2 жыл бұрын
I used the Amiga blitter to write programs for it's 'Copper' video coprocessor to create colourful gradients otherwise not possible with the limited number of bitplanes. Very useful hardware indeed.
@BrekMartin
@BrekMartin 2 жыл бұрын
About time the Amiga featured here! :D
@dat_chip
@dat_chip 2 жыл бұрын
I have been wondering about that too - especially considering how far ahead of the competition it was in the late 80s. Full 32-bit preemptive multitasking, with OS-wide cross process scripting and what not. The HAM (hold-and-modify) mode is worth a video all by itself, I think. Imagine doing 1448 x 720 in 262144 colors in 1991? Yup, it did that.
@captainboing
@captainboing 2 жыл бұрын
the Amiga used the blitter for disk access too. Because of the encoding, there was a "soft index" (4489h... maybe... ?) that could never be the result of a data encoding action. AmigaDOS just dropped the head on the disk, read an entire track (+ a bit). The blitter was then tasked to find the index and re-construct the entire track in the right order. The DOS firmware then just picked out the sectors it wanted.
@PaulFisher
@PaulFisher 2 жыл бұрын
One example of the “bitplanes” you discuss at about 07:45 is on the SNES. Retro Game Mechanics Explained has an excellent video about how backgrounds and color work on that system!
@crtxl
@crtxl 2 жыл бұрын
Bitplanes in the ST or Amiga are different from background layers of the SNES.
@subliminalvibes
@subliminalvibes 2 жыл бұрын
"Blit... Now that's a name I've not heard since..." A long time ago in a galaxy far, far away.
@gottagowork
@gottagowork 2 жыл бұрын
Yeah, the blitter is very effective on copying from memory lane. Got a bit nostalgic here, not gonna lie.
@TheSpacecraftX
@TheSpacecraftX 2 жыл бұрын
A blit function is still used in computer graphics today. I used it this year in a modern environment.
@davidgillies620
@davidgillies620 2 жыл бұрын
It would be interesting to see a detailed examination of the QuickDraw CopyBits function that Apple used in early versions of the Mac. That was a software blitter, but incredibly highly optimised and included the ability to clip the destination with an arbitrary region (which is a video all by itself). The Apple engineers were justifiably proud of how much work went into CopyBits.
@darkwinter6028
@darkwinter6028 2 жыл бұрын
Well, QuickDraw and MacPaint have been open-sourced, so…
@TheSulross
@TheSulross 2 жыл бұрын
Dark Winter but regions and bitblit implementations were down in ROM - at the time, they were impressive graphics primitives even though coded to execute on the 68000 cpu
@darkwinter6028
@darkwinter6028 2 жыл бұрын
@@TheSulross QuickDraw was ROM-resident and the source for that part of the ROM is included in the package of source code.
@lawrencedoliveiro9104
@lawrencedoliveiro9104 2 жыл бұрын
They got a patent on the QuickDraw region structure, and wouldn’t let anybody else use it until it expired in about the 200x’s.
@TheTurnipKing
@TheTurnipKing 2 жыл бұрын
it was massively useful for graphics operations because early days, that's what 95% of graphics operations were: Copying (relatively) huge chunks of data around. Scrolling is the defacto example of this. You're moving 95% of the already on-screen data from one location in memory to another area nearby and then copying a small amount of new data onto one or two of the borders of that screen ram.
@VastyVastyVoid
@VastyVastyVoid 2 жыл бұрын
True, but not always. On the Amiga, you would simply update the bitplane pointers to point to the new location.
@TheTurnipKing
@TheTurnipKing 2 жыл бұрын
@@VastyVastyVoid That's a perfect example of WHY companies started introducing hardware assistance like Blitters and such into their systems to perform these tasks.
@Jimbaloidatron
@Jimbaloidatron 2 жыл бұрын
@@VastyVastyVoid Yup, or update the LMS addresses for Antic on it's true predecessor, the Atari 8 bit machines. No screen memory moves, the 'Window' into memory moves.
@VastyVastyVoid
@VastyVastyVoid 2 жыл бұрын
@@Jimbaloidatron Eh, I wouldn't call the Atari 8-bit its predecessor. I could be convinced, but the evidence would have to be something special -- the engineers having worked at Atari wouldn't be sufficient, given the differences in terms of architecture, OS decisions, microkernel etc. But yes, that part works in a similar fashion, or at least as far as I know.
@Jimbaloidatron
@Jimbaloidatron 2 жыл бұрын
@@VastyVastyVoid I don't believe you can really be thinking in terms of the OS and microkernel software when comparing to any 8 bit system, Atari or otherwise! Without even knowing that Jay Miner designed the Antic and C/GTIA chips, you can see things in the hardware; like how the Amiga sprites have unlimited height is an evolution of the C/GTIA columnar 'players'. That _by design_ you can display multiple modes of different resolutions all on the screen simultaneously from different places in memory. The emphasis toward graphical co-processor use itself. It's inevitable some concepts will have stayed with him, evolved and been turned up to eleven in the Amiga - the clues are there. When Atari released the ST, I was among many Atari 8 bit users who could not accept a bunch of off-the-shelf components as a compelling upgrade and instead bought an Amiga. Maybe I choose to see things that way, and it's entirely confirmation bias, but I'm happy with that. We all learn as we go and our successes will influence our future choices, no reason to think it wouldn't have applied back then and it does no harm to the Amiga legacy, except perhaps if there are those who think a beam of golden light came from the sky and the wire-wrapped prototype descended slowly in a shimmering cloud of beautiful copper bars! :-)
@ltdowney
@ltdowney 2 жыл бұрын
Blitting in some sense is more alive than ever. Deferred rendering techniques in modern graphics engines involve rendering to an offscreen buffer for various uses. These could be postprocessing effects like bloom or shader-based antialiasing, but the best example is probably environment mapping. If you’re playing a game and you walk into a bathroom (toilet, for the Brits), and you’re impressed that you can see your character move back and forth in the mirror, it’s really nothing too fancy happening there. The game is rendering the scene once from the mirror’s perspective into a texture buffer, and then rendering the scene again from the player’s perspective after mapping the texture onto the mirror in 3D space. All this takes place inside the graphics card, so the programmer doesn’t interact with it quite the same way any more. We don’t have to worry about the copy operations pixel-by-pixel, per se, although in a fragment shader you are computing the output of each pixel, but the graphics hardware and driver take care of calling it repeatedly, in parallel, over the entire scene.
@superscatboy
@superscatboy 2 жыл бұрын
We have bathrooms in Britain. If you walk into a toilet you get wet feet.
@sanskarpandey6213
@sanskarpandey6213 2 жыл бұрын
Thank you for this explanation.
@NorbertHarrer
@NorbertHarrer 2 жыл бұрын
@Xeno The Strange Or brown toes?!
@adrianscarlett
@adrianscarlett 2 жыл бұрын
All gpu operations render to an offscreen framebuffer before swapping to the screen, even window managers do this, compositing everything together before showing the final result.
@fburton8
@fburton8 2 жыл бұрын
superscatboy Yep, though you can also "go to" the toilet (presumably stopping before stubbing your toe).
@DavePoo
@DavePoo 2 жыл бұрын
24:48 - "you can't have 2 things accessing memory at the same time" - well, that's not quite true with the Amiga, as it had the ability to access the non shared RAM at the same time as the blitter was accessing the shared ram -> from The Amiga Hardware Manual -> "Performance of the 68000 is enhanced by a system design that gives it every alternate bus cycle, allowing it to run at full rated speed most of the time. As described in the section below, the special purpose hardware can steal time from the 68000 for jobs it can do more efficiently than the 68000. Even then, such cycle stealing only blocks the 68000's access to the shared memory. When using ROM or external memory, the 68000 always runs at full speed. "
@theamigashow9506
@theamigashow9506 2 жыл бұрын
You can also send blitter commands via the copper, freeing the CPU even more. It's not often used though, as I believe it can can get a little messy.
@user-lz2mu9uq4e
@user-lz2mu9uq4e 2 жыл бұрын
BitBlit hardware is still there actually. Every smartphone has 2D acceleration block inside SoC. And its main task is BitBlit. Yes, it's a bit more advanced since it can convert colorspace and do alpha blending. It also can "fill rectangle with color" and "draw line". But 2D accelerator is mostly (like 80%) a BitBlit chip. 2D accelerator easily outperforms both CPU and GPU inside mobile chipsets. And there are more 2D hardware in a smartphone. Like Image Signal Processor which can crop and resize image from your camera. Or Video Output Processor which can blend several planes (aka windows) on the fly pixel by pixel while sending result directly to display. Much like graphics editors handle multiple layers.
@discoisdead8504
@discoisdead8504 2 жыл бұрын
Yay Amiga. The 80s, a time when computers were much more interesting than today.
@recompile
@recompile 2 жыл бұрын
Steve, you can very easily divide a box into 8 parts by cutting things in half 3 times. (From your starting rectangle, making 2, then 4, and finally 8 boxes) 2^3=8 after all! Estimating half is easy for humans, so your boxes will come out very even.
@NorbertHarrer
@NorbertHarrer 2 жыл бұрын
Nice way to do it. Works great for any 2^x divided boxes (8, 16, 32, etc.).
@jhoughjr1
@jhoughjr1 2 жыл бұрын
that is also why Imperial length units live on.
@Jimbaloidatron
@Jimbaloidatron 2 жыл бұрын
I was watching the video thinking the exact same thing... every... single... time... I thought it was a natural programmery thing to 'binary chop' it!
@marsvandeplaneet7786
@marsvandeplaneet7786 2 жыл бұрын
I was just about to comment that, too! 😀
@Amonimus
@Amonimus 2 жыл бұрын
This sounds extremely useful, not just for graphics but in data transfer in general.
@recompile
@recompile 2 жыл бұрын
I guess I don't see the utility outside of older computer graphics. Do you have an example of where you'd need to copy data that isn't byte aligned to a source that is misaligned differently?
@NorbertHarrer
@NorbertHarrer 2 жыл бұрын
@@recompile In it's simplest form just to copy big blocks of memory (without shifting or bit operating), to free up the CPU to do other things. It was even mentioned in the video.Then it's basically DMA (which the Amiga also implemented btw.).
@jhoughjr1
@jhoughjr1 2 жыл бұрын
yeah GPUs were a main driver in the reduction of that bottleneck. Fastest circuits in any comp were the video circuits.
@FinaISpartan
@FinaISpartan 2 жыл бұрын
Anyone who works directly with the win32 API for graphics knows bit blit very intimately. Interesting to learn of its history.
@MrValsung
@MrValsung 6 ай бұрын
I've made Conway in the Win32 API recently. would love to learn more about its bit blit functionalities more in-depth if you have any resources and/or advice you're willing to share
@SteelHorseRider74
@SteelHorseRider74 2 жыл бұрын
Amiga also had the "Copper" (simply an abbrev. for "Co-Processor") in addition to the Blitter - and although it had only three commands built in it understood (move, skip, wait) it could get very complex in using it...
@hardware4200
@hardware4200 2 жыл бұрын
Wasn't copper used to implement hold and modify. This goes way back for me.
@v4lgrind
@v4lgrind 2 жыл бұрын
@@hardware4200 No, HAM was implemented in the graphics chip, but you could use the copper to increase the effective palette in all modes by switching palette entries when you got to specific screen positions.
@valenrn8657
@valenrn8657 2 жыл бұрын
@@hardware4200 Slice HAM mode used copper to reload the color palette at a specific display location. Normal HAM used specific hardware features in Amiga's custom chip.
@lawrencedoliveiro9104
@lawrencedoliveiro9104 2 жыл бұрын
The Copper chip was far more innovative than the Blitter. It was the Copper that allowed the multiple vertically-sliding “screens” with different graphics modes. They could only be partitioned vertically, because the Copper chip could only change mode between scan lines, not in the middle of a scan line. But being able to dynamically rebuild a display list was (in those days) much quicker than having to copy entire screenfuls of pixels around.
@amigalemming
@amigalemming 2 жыл бұрын
@@lawrencedoliveiro9104 The Copper could change a register in the middle of a scan line. However, for one change along a vertical line you would have to do perform a Copper operation in every scan line. And the horizontal resolution for changes was limited (I assume 4 pixels).
@feppfepp
@feppfepp 2 жыл бұрын
That's an zx spectrum A. I still recognise the byte values from creating fonts for it almost 40 years ago...
@isyt1
@isyt1 2 жыл бұрын
Yeah and when he inverted it, it made me think of the inverse video button (symbol shift 4?)
@FyberOptic
@FyberOptic 2 жыл бұрын
I suggest folks go read about how John Carmack implemented side-scrolling on PC using the EGA latches. PC graphics hardware was never made for gaming but a lot of clever tricks were used to speed up blitting in ways never really intended.
@uriituw
@uriituw 2 жыл бұрын
Are you saying EGA had a blitter?
@synchronos1
@synchronos1 2 жыл бұрын
@@uriituw if you mean blitter, no, they are not saying that. They are saying that EGA has horizontal and vertical offset values for the frame buffer. This drastically reduced the amount of blitting needed for scrolling graphics. Do as they suggest and google that "John Carmack implemented side-scrolling on PC using the EGA latches", and you'll find the Wikipedia article describing the whole process.
@sharpfang
@sharpfang 2 жыл бұрын
One big problem with the video. "You could do this much faster than you could in software" - on Amiga, actually, no! Blitting using CPU was roughly the same speed on A500, and significantly slower on A1200 - simply because Blitter operated at much slower clock than the CPU. It still had its uses because you could blit areas of memory using the blitter while the CPU was busy doing other, unrelated stuff - or even blitting *other* areas of memory, say, have a game with a couple objects maintained as BLOBs (Blitter Objects) and majority generated by CPU. Plus Blitter could keep your software short and sweet, setting it up was way less work. But apples to apples, it wasn't faster.
@DuncanGlendinning
@DuncanGlendinning 2 жыл бұрын
It would have been great to have done the setup starting with one of the first GUI's based on Smalltalk in the mid 1970's, and the need to move / manipulate bitmaps.
@dr_stevious
@dr_stevious 2 жыл бұрын
Every time I see Dr Bagley, I feel like parallel universes somehow merged.
@squishmastah4682
@squishmastah4682 2 жыл бұрын
Berenstain Bears.
@randName
@randName 2 жыл бұрын
for a few moments I wondered why Steve was answering a question I couldn't hear and then I realized I was only wearing my right earpiece 😅
@inshadowz
@inshadowz 2 жыл бұрын
And here I thought my office workstation headset output was mono, turns out it's right channel only 😝
@uriituw
@uriituw 2 жыл бұрын
Amiga! 🤘
@IntrinsicPalomides
@IntrinsicPalomides 2 жыл бұрын
Amigaaaaaaaaa!
@wockeyfilm
@wockeyfilm 2 жыл бұрын
My right ear has been satiated.
@editedreality7955
@editedreality7955 2 жыл бұрын
This comment will bring a lot of confusion to people without the context.
@timharig
@timharig 2 жыл бұрын
@@editedreality7955 Makes perfect sense to me.
@gregheffley5712
@gregheffley5712 2 жыл бұрын
@@editedreality7955 pls help me understand
@AhmedHOmar-vz4qz
@AhmedHOmar-vz4qz 2 жыл бұрын
This video is a reupload because the previous upload had an audio problem
@1e1001
@1e1001 2 жыл бұрын
@@AhmedHOmar-vz4qz no don't explain keep it a secret
@Kenbomp
@Kenbomp 2 жыл бұрын
Nice to know that smalltalk had a influence on the Amiga. Like stars aligned
@poorman-trending
@poorman-trending 2 жыл бұрын
You guys really need to do an entire series on c64.
@ul0q808
@ul0q808 2 жыл бұрын
Yes. This please. That’d be like 100 videos just going over the basics of how the hardware worked. This would be glorious!
@poorman-trending
@poorman-trending 2 жыл бұрын
Who do you think should be the guest? I’m thinking 8- but show and tell. Or 8-bit-guy. Heck, why not both.
@sergiomurru5055
@sergiomurru5055 2 жыл бұрын
There also is the BItBlt Win16 SDK API, that wasn't implementeed in HW, but relied on auto-modifying code, if I do remember correctly Matt Pietrek's artticle from Beautiful Code. That was the reason why the first Microsoft WIndows was astoundingly fast ("fast" in the '80s).
@rititone
@rititone 2 жыл бұрын
Nice! What is the title of the paper in which they implement the bit blit in hardware?
@Ziplock9000
@Ziplock9000 2 жыл бұрын
The Amiga was amazing. It's a shame Commodore UK didn't manage to get the deal through to buy the rights for the IP from the GHQ in the US
@robchr
@robchr 2 жыл бұрын
This seems like an early version of single instruction multiple data (SIMD).
@absalomdraconis
@absalomdraconis 2 жыл бұрын
Essentially it's DMA with some extra capabilities. Somewhat unfortunate that the 90s was dominated by the IBM compatible alone, since programmable logic could have made blitting virtually omnipresent.
@SpringDivers
@SpringDivers 2 жыл бұрын
Thanks, Steve. Quite interesting. Have you heard of NAPLPS? And if so, perhaps you might consider a segment covering the once popular graphics protocol.
@filker0
@filker0 2 жыл бұрын
NAPLPS? Videotex/Teletext Presentation Layer Protocol Syntax (North American PLPS)? ANSI BSR X3.110-198X? X3L2.1? Successor to TELIDON? Never heard of it. Though, come to think of it, back in June 1983, I had a weird dream that was picked up by a tornado and dropped in Chicago, where I represented Digital Equipment Corp. (not as the primary representative) at a trilateral (ANSI-CSA-EIA) meeting where we spent much of the time arguing over unprotected fields or some such nonsense. I woke from the dream is a cold sweat, clutching the draft proposal closely. Was it real? That was definitely my handwriting on the March trilateral meeting draft. My name isn't in the standard, I don't think, so maybe it was a dream... I still have a photocopy of the June 10, 1983 draft, and I spent several months implementing PDIs and DRCS for the NAPLPS and TELEDON terminal emulator for the DEC Professional 350, working late into the night in my cube on the 2nd floor of building 5 of the Mill in Maynard, MA. What utter BLISS (the language I wrote it in).
@GilesBathgate
@GilesBathgate 2 жыл бұрын
@Steve Bagley. Does the hardware "shift" register (that doesn't actually shift) have a name?
@GodBeastX
@GodBeastX 2 жыл бұрын
Thanks for bringing me back to my MSDOS days of programming and graphics memory at A000:0000. Far pointers... AHHHHHHH!
@DanielMonteiroNit
@DanielMonteiroNit 2 жыл бұрын
I see that planar graphics made a lot of sense to exploit a blitter chip...but it's a pain in the 0xA55 to do texture mapping with. No wonder only now the Amiga got a proper Doom clone (as in, it plays *fast* on a stock A500, in Fullscreen)
@DanielMonteiroNit
@DanielMonteiroNit 2 жыл бұрын
It's quite cool that Intuition (or is it from a layer below?) exposes all this to the graphic routines to plot shapes... something the Win32 API would have to wait a little to see the same level of versatility
@kirschhoffer
@kirschhoffer 2 жыл бұрын
... and that's why screen scrolling was always much more fluid on Amiga than on the Atari ST :-)
@ChrisSmith-tc4df
@ChrisSmith-tc4df 2 жыл бұрын
Barrel Shifter: shifts an arbitrary number of positions in one operation
@noor-rx1ij
@noor-rx1ij 2 жыл бұрын
Is that what the trick in the end is called?
@sanderbos4243
@sanderbos4243 2 жыл бұрын
I'm not sure if it's worth another reupload to fix it, but at 7:19, 9:54, 21:48, 24:11 it's very quiet and only plays in the left ear. The marker scratching is also a little out-of-sync at 12:11. At 20:40 it's also quiet, but that might just be the original volume picked up by the microphone of him whispering. :-)
@rolfs2165
@rolfs2165 2 жыл бұрын
Because Sean's wearing a mask and sitting to the left of the camera. ;)
@aamiddel8646
@aamiddel8646 2 жыл бұрын
Interesting. Makes me think of sprites. I guess the same mechanization but not storing the result in the original memory but combining the original memory with the 'sprite'content.
@abbbb5625
@abbbb5625 2 жыл бұрын
Programmed that one int assembler on a MC68K atari for the fun of it. pretty fun to do... hard to debug if you have a bug... lol
@bengoodwin2141
@bengoodwin2141 2 жыл бұрын
Do modern computers have chips for this? Or do they just do it on the CPU? Is it a part of the GPU now? Edit: I see, less useful with higher bits per pixel
@disliker7182
@disliker7182 2 жыл бұрын
At least on the CPU, with random access memory there isn't much need to copy things around. Most instructions can use one memory operand (source/destination) and the others are registers. So the AND could be either "read and AND" or "read, AND and write". Pure memory copy instructions are not prioritized because the limiting factor is usually latency. On my CPU: read (from cache) and add value takes effectively 0.5 cycles (out of 5Ghz, e.i. 5 billion/s), but the latency is 5 cycles. Accessing RAM takes hundereds. Even light could only travel ~6cm per cycle. CPUs have more power than simple operations require, so they make them more complex by combining them and executing them in parallel.
@alienrenders
@alienrenders 2 жыл бұрын
GPUs are more generic now. So they work quite differently. And video output hasn't used bit planes since vga. GPUs have tons of parallel processors that can operate on each pixel at the same time. And each one can often operate on multiple pixels with a single instruction. But you code it up directly. It can get complicated with shared registers, shared local memory, latency and other things. Loading data has latency, so you need multiple things to run on the same core so that when one program is waiting for data, it can execute a different program in the meantime. RDNA from AMD tried to reduce the number of programs you need. It can be on the order of 16... with AMD trying to reduce that to 4 or 8. And by program, they're really smaller sections of code and are called something else on GPU.
@valenrn8657
@valenrn8657 2 жыл бұрын
DMA Move Engines.
@paco3447
@paco3447 2 жыл бұрын
Amiga's masked blit operation or "Cookie Cut"
@oldmandoinghighkicksonlyin1368
@oldmandoinghighkicksonlyin1368 2 жыл бұрын
So that's why _Rocket Ranger_ was so ahead of its time.
@Veptis
@Veptis 2 жыл бұрын
I remember a project in school we did in Assembly. It had a custom character set and bitmaps. And the display had to run through some cycles to change to a different characters l
@Turrican
@Turrican 2 жыл бұрын
Only amiga makes it possible.
@dotslashsatan
@dotslashsatan 2 жыл бұрын
I remember playing with bitblt in VB6 and alpha blit!
@MrDarchangelomni
@MrDarchangelomni Жыл бұрын
I wasn't looking when this came on and I thought "WOW I didn't know JARED HARRIS is a technophile".
@meestyouyouestme3753
@meestyouyouestme3753 2 жыл бұрын
Wow, we're gonna need a bigger Chip.
@123FireSnake
@123FireSnake 2 жыл бұрын
correct me if i'm wrong but can't every algorithm be faster if implemented in hardware? Sure for some it's not really neccessary or efficient to do so but with tailor made hardware it'll still be faster
@jhoughjr1
@jhoughjr1 2 жыл бұрын
In general yeah. Its just it is usually far easier to keep hardware general.
@PixelOutlaw
@PixelOutlaw 2 жыл бұрын
As fast as stuff like GLSL and Vulkan are, blitting is just SO much more intuitive. In some ways it's raised the barrier to entry for new programmers through the roof. Why should you have to write program files in an alien language and work backwards inventing projection from "first principles" just to say "put a red pixel at 3,4"? Parallelism is fast but woof it's a dog when compared to pushing colors into memory directly.
@Churchill250267
@Churchill250267 2 жыл бұрын
If you want to write to display memory directly in Linux then grab a pointer to the frame buffer - have fun…
@Alistair
@Alistair 2 жыл бұрын
Because shader operations are inherently parallel. It's definitely less intuitive, but it's far more powerful overall if you take the time to figure out what is really happening. Still, maybe you are right that there is scope for a higher level of abstraction which could make this process simpler for some limited set of operations..
@soylentgreenb
@soylentgreenb 2 жыл бұрын
Try doing perspective correct texturing with anisotropic filtering using a BLIT.
@mrxmry3264
@mrxmry3264 2 жыл бұрын
7:20 i thought that was how it worked in the graphics mode on the C64, but it turned out it was quite a bit more complicated than that.
@ChrisSmith-tc4df
@ChrisSmith-tc4df 2 жыл бұрын
Commodore aimed for simplicity, so they used the same address generator in graphics mode as used in text mode, so the screen was still laid out as little 8x8 character regions. So in effect the whole screen was an agglomeration of characters with the bits of each character laid out as if they were little 8x8 raster scanned screens in memory.
@mrxmry3264
@mrxmry3264 2 жыл бұрын
@@ChrisSmith-tc4df and that is what made graphics programming on the C64 considerably more complicated than it should have been.
@marsvandeplaneet7786
@marsvandeplaneet7786 2 жыл бұрын
tnx al lot
@lawrencedoliveiro9104
@lawrencedoliveiro9104 2 жыл бұрын
The next logical thing to talk about after this would be Porter-Duff operators.
@thenewchicken1339
@thenewchicken1339 Жыл бұрын
Is this unlisted?
@valenrn8657
@valenrn8657 2 жыл бұрын
Amiga's recent Dread game has used Blitter for C2P.
@LunaticEdit
@LunaticEdit 2 жыл бұрын
I want that shirt.
@patton72010
@patton72010 2 жыл бұрын
George Constanza's mathematician brother. (even same mannerism at 2:59)
@jo555444
@jo555444 2 жыл бұрын
Did you realize that even the paper he is drawing on is from the 80's? Where did he store all that paper over 30 years?
@absalomdraconis
@absalomdraconis 2 жыл бұрын
Tractor feed paper you mean? They still make that stuff, so he probably just ordered it.
@peppers1758
@peppers1758 2 жыл бұрын
Felt tip marker ASMR
@dotslashsatan
@dotslashsatan 2 жыл бұрын
What’s the modern way to bitblt?
@wbfaulk
@wbfaulk 2 жыл бұрын
It sounds to me like he spent 15 minutes describing copying data from one memory location to another, and I don't really understand how there's really any other way to do it. You read from the source and write to the destination. I feel like he's describing something clever, but it sounds very obvious to me. What am I missing? I guess it's just the boolean operation in the middle?
@IsYitzach
@IsYitzach 2 жыл бұрын
It is what he's describing. What you're missing is the many variations (start part way through a byte/word, start part way through one block, discard part of a block, and so on) of how that move happens and the fact that while CPU can do it, it is designed for a more general case so it does it poorly. Blitter chip specializes in the moving and combining of large data sets quickly with low latency, something the CPU wasn't designed for.
@Lynxxde
@Lynxxde 2 жыл бұрын
If you do such copy operations with the cpu you first need a command to read the source-byte, then maybe shift it to get to the exact destination adress, "and" it to mask the bits you dont want, read the destination, "or" the source/masked/bits with it, write it to the destination .. and that for every byte (and also skip x bytes after a row is complete) - with a blitter you tell him the source, destination, modulos (how many bytes to the next line), shift how many bits, copy how many pixel in x&y - and then the blitter does the rest, your cpu can do something else ..
@wbfaulk
@wbfaulk 2 жыл бұрын
I understand the advantage of offloading a process from the CPU, but that's advantageous regardless of what you're offloading. He did mention that it was particularly efficient in hardware, but then never described why.
@Lynxxde
@Lynxxde 2 жыл бұрын
@@wbfaulk Because you need multiple cpu-commands, read the bits, mask it with AND, read the destbits, OR the destbits, write to the destination, and that over and over again, and skip row-bytes to get to the next row and so on .. a blitter has these commands "baked" in hardware, you just say how much to copy and he does his thing and the cpu is free to do other tasks.
@wbfaulk
@wbfaulk 2 жыл бұрын
@@Lynxxde Again, that's true of any offloading. What makes this more advantageous than other things you could offload? Also, my point is more about the incompleteness of the video than the idea that I can't find this information elsewhere.
@mountp1391
@mountp1391 2 жыл бұрын
great
@peppers1758
@peppers1758 2 жыл бұрын
I remember first hearing about bitblit in highschool thinking it sounded funny
@shadout
@shadout 2 жыл бұрын
Funny that just when he said "greyscales" the lights in the background turned off.
@paszTube
@paszTube 2 жыл бұрын
the dog looks fine
@billkendrick1
@billkendrick1 2 жыл бұрын
Would've been cool if someone had made a blitter chip add-on for the Atari 8bits (via cart or PBI port). Ah well.
@crtxl
@crtxl 2 жыл бұрын
Booooring 😉 Seriously, would have been cool, however, for games the ANTIC mode 4 is preferred. And using Blitter with char based gfx is not useful AFAICS.
@AdamKlobukowski
@AdamKlobukowski 2 жыл бұрын
In Atari Falcon, for just simple memory copy, Blitter is slower than CPU, so it makes no sense to use it for HDD data transfer and is not used for that.
@DrSteveBagley
@DrSteveBagley 2 жыл бұрын
The source code for AHDI definitely has code for using the blitter to read from the IDE, and as far as I can tell it’s enabled if IDE exists, and the machine isn’t an ST Book, which leaves the Falcon. Yep, the Falcon's CPU can out run the blitter, but the IDE isn’t just a straight memory copy since you are reading from a single location, and writing to many which forces you to use move.w (a0), (A1)+ type code, that won’t get the full performance out of the 030 anyway.
@gav1njackson
@gav1njackson 2 жыл бұрын
Oh, "Gamma Channel BitBlt Failure" @25:02 ;-)
@KunalSaini97
@KunalSaini97 2 жыл бұрын
Bit Blyaat!
@StefanReich
@StefanReich 2 жыл бұрын
Wow what a lengthy explanation... how about showing some Amiga demos
@mikebailey783
@mikebailey783 2 жыл бұрын
I think the cameraman needs a tripod!
@tian5185
@tian5185 2 жыл бұрын
Also short for Bacon, Lettuce & Tomato
@Jkauppa
@Jkauppa 2 жыл бұрын
which is better, avx compared to cores, same amount of atomic ops in memory size
@Jkauppa
@Jkauppa 2 жыл бұрын
compare single core doing say 10x n-bit ops as single avx op, or 10x cores doing single-bit ops
@Jkauppa
@Jkauppa 2 жыл бұрын
its the same speed, if all the cores run the same program in the same place, different register contents
@Jkauppa
@Jkauppa 2 жыл бұрын
result buffer of single operation, of two 8-bit operands, is 2^(8+8)bytes = 64kbytes, result is one byte, as a cached op chip
@mikejohnstonbob935
@mikejohnstonbob935 2 жыл бұрын
6:30 A? Amongus?
@danieldiebolt9483
@danieldiebolt9483 2 жыл бұрын
I frigging Love this guy!
@justice4g
@justice4g 2 жыл бұрын
I pretty much gave up computers as a hobby when I sold my Amiga, it just wasn't enjoyable tinkering with PCs.
@GrinyaPLAY
@GrinyaPLAY 2 жыл бұрын
Creator of ZX Spectrum Clive Sinclair died 17.09.2021
@ImmortalDuke
@ImmortalDuke 2 жыл бұрын
Sensible soccer
@x3ICEx
@x3ICEx 2 жыл бұрын
25:00 light switch troll :)
@stanleywhiteman6450
@stanleywhiteman6450 2 жыл бұрын
Even on 386 platform with modest video card it was very very fast.
@PebblesChan
@PebblesChan 2 жыл бұрын
1970’s SPACE INVADERS uses cascaded Am25S10 hardware to perform the bit selection described @20:48
@GordieGii
@GordieGii 2 жыл бұрын
How is a BOB different from a Sprite?
@DrSteveBagley
@DrSteveBagley 2 жыл бұрын
Depends on the architecture, on some platforms (eg the ST, or Archimedes) then nothing everything is done by manipulating the in memory bitmap, on others such as the Amiga then sprites are composited onto the background as the image is drawn to the screen by the video hardware, the hardware effectively reads the background bitmap and the sprite bitmap and combines them. You can then move the sprite just by updating its position and altering where they are combined, rather than having to redraw it into the bitmap
@GordieGii
@GordieGii 2 жыл бұрын
@@DrSteveBagley Thanks
@listerdave1240
@listerdave1240 2 жыл бұрын
AFAIK the difference is that a BOB consists of actually writing the graphic into the display memory whereas the sprite is not written into video memory but instead overlayed on the output stream. Put differently, as the pixels are being scanned and sent to the ADC, when a pixel position is reached where the sprite is not transparent the DAC will read that pixel from the memory where the sprite is stored rather than from the memory where the pixel at that position is stored.
@GordieGii
@GordieGii 2 жыл бұрын
@@listerdave1240 Probably more accurate to say that the "GPU" reads both and when the sprite isn't transparent it writes the sprite data, instead of the buffer data, to the DAC.
@Sandeepan
@Sandeepan 2 жыл бұрын
Finally you fixed left channel in this re-upload
@stub1116
@stub1116 2 жыл бұрын
This video seams to describe some sort of , 'paged graphics' : am I right?
@synchronos1
@synchronos1 2 жыл бұрын
What do you mean by "paged graphics"? Blitting is just a basic process where you copy image data (could be other data, but usually image) from memory to other parts of memory. If you have separate video memory, then quite often the copy happens from CPU memory to video memory. Nothing related to paging here. Blitting can be done with arbitrary-sized source data from any memory position to an arbitrary position in the destination memory. If by paging you mean double buffering, the answer is still no. Blitting is in no way dependent on the amount of frame buffers.
@jhoughjr1
@jhoughjr1 2 жыл бұрын
I have that shirt!
@fabioscognamiglio9281
@fabioscognamiglio9281 2 жыл бұрын
❤️ where can i get one?
@jhoughjr1
@jhoughjr1 2 жыл бұрын
@@fabioscognamiglio9281 My mom worked for Apple support for years and they would send stuff out every few months. You can get them at a gift shop at the mothership, or look on eBay as a lot of ppl sell their schwag there. Stay Schwifty
@SockTaters
@SockTaters 2 жыл бұрын
6:34 That letter "A" is lookin a bit sus
@SteveGouldinSpain
@SteveGouldinSpain 2 жыл бұрын
Wow, you didn't use the word 'sprite' once!
@NorbertHarrer
@NorbertHarrer 2 жыл бұрын
Because done with a blitter, they are called bobs (blitter objects).
@headlessxp4948
@headlessxp4948 2 жыл бұрын
So those blitter chips were basically just some clever DMAs?
@Lynxxde
@Lynxxde 2 жыл бұрын
Yes .. Amiga had several DMA's, for Sprites, Copper, Disk, Blitter, Sound, Video-Out, ...
@uriituw
@uriituw 2 жыл бұрын
No.
@g0rth0rTBL
@g0rth0rTBL 2 жыл бұрын
Why are you not stabilizing your camera footage?
@valseedian
@valseedian 2 жыл бұрын
my minesweeper automating dissociated bot uses bitblt to copy the hardware context screen buffer to a memory block that doesn't need to be locked to read. fastest screen grab function I tested by a factor of 50. it had the added benefit of being able to hold a copy of the hardware device context live in memory instead of asking for it every refresh. gotta eek out every ms I can! average solve time 175ms on an fx-8350. I think an older computer on 32bit would run substantially faster ironically. our of those 175ms average, 160+ms is just waiting for minesweeperx to refresh its state after sending a dozen clicks directly to its input queue... a windows 8+ only feature that saves a ton of time by not having to actually take control of or move the mouse cursor to do clicks. womp womp.
@UberMathNerd
@UberMathNerd 2 жыл бұрын
Thank you! I always wondered why the operation in PyGame was called Blit()
@supertrn76
@supertrn76 Жыл бұрын
\o/
@leodeoliveira7480
@leodeoliveira7480 2 жыл бұрын
With all due deference to your Atari and Amiga fanbois (😊), let us not forget Bill Atkinson's Quickdraw programming tour-de force on the original Macintosh (128kb, 1984), which packed all this BitBlitty goodness, plus graphics line-drawing primitives (including circles, arcs etc), rounded corners, drawing regions, font drawing, scaling, rotation, all in 24KB of hand-optimized assembly code. You say, for example, that someone wrote a screen-copying algorithm that took 8 minutes to run? Then why was QuickDraw so damned quick, considering it was all done in 68000 code, and without even the benefit of a barrel-shifter, which only appeared in the much later 68020.
What's Virtual Memory? - Computerphile
22:40
Computerphile
Рет қаралды 172 М.
Why was the Amiga so awesome?
27:18
Dave Poo 2
Рет қаралды 104 М.
Can You Draw The PERFECT Circle?
00:57
Stokes Twins
Рет қаралды 88 МЛН
1 класс vs 11 класс (неаккуратность)
01:00
БЕРТ
Рет қаралды 1,9 МЛН
La final estuvo difícil
00:34
Juan De Dios Pantoja
Рет қаралды 25 МЛН
CAN YOU HELP ME? (ROAD TO 100 MLN!) #shorts
00:26
PANDA BOI
Рет қаралды 35 МЛН
Iterative Closest Point (ICP) - Computerphile
16:25
Computerphile
Рет қаралды 134 М.
Sir Clive Sinclair & British Computer Revolution - Computerphile
30:00
Log4J & JNDI Exploit: Why So Bad? - Computerphile
26:31
Computerphile
Рет қаралды 496 М.
ChatGPT does Physics - Sixty Symbols
16:42
Sixty Symbols
Рет қаралды 638 М.
Why Files Become Bigger in Emails - Computerphile
18:17
Computerphile
Рет қаралды 65 М.
Hacking Out of a Network - Computerphile
25:52
Computerphile
Рет қаралды 237 М.
Square & Multiply Algorithm - Computerphile
17:35
Computerphile
Рет қаралды 272 М.
The Rise and Sad Fall of Wang Labs
29:15
Asianometry
Рет қаралды 300 М.
Cracking Enigma in 2021 - Computerphile
21:20
Computerphile
Рет қаралды 2,4 МЛН
Can You Draw The PERFECT Circle?
00:57
Stokes Twins
Рет қаралды 88 МЛН