Amstrad CPC

Anything relating to non Sinclair computers from the 1980's, 90's or even before.
Post Reply
User avatar
PeterJ
Site Admin
Posts: 6858
Joined: Thu Nov 09, 2017 7:19 pm
Location: Surrey, UK

Amstrad CPC

Post by PeterJ »

I have always been put off spending much time with the CPC range because what I considered a more chunky graphics resolution than the Spectrum offered, although of course no colour clash.

Mode 0: 160×200 pixels with 16 colours (4 bpp)
Mode 1: 320×200 pixels with 4 colours (2 bpp)
Mode 2: 640×200 pixels with 2 colours (1 bpp)
Mode 3: 160×200 pixels with 4 colours (2bpp)

Am I missing anything?
AndyC
Dynamite Dan
Posts: 1388
Joined: Mon Nov 13, 2017 5:12 am

Re: Amstrad CPC

Post by AndyC »

That's right, for a given definition of right. The CPC's video hardware is fairly flexible and those pixel dimensions are only true if you use the default 40*25 arrangement. You can change it to have different dimensions if you like so you could, for example, set up a 32*24 character screen and have 256*192 pixels in Mode 1 - which a lot of Speccy ports do, for fairly obvious reasons.
User avatar
1024MAK
Bugaboo
Posts: 3104
Joined: Wed Nov 15, 2017 2:52 pm
Location: Sunny Somerset in the U.K. in Europe

Re: Amstrad CPC

Post by 1024MAK »

PeterJ wrote: Thu Feb 22, 2018 5:33 pm Am I missing anything?
Apart from mode 3, These are only what BASIC supports.

More info on the CPC Wiki

Mark
:!: Standby alert :!:
“There are four lights!”
Step up to red alert. Sir, are you absolutely sure? It does mean changing the bulb :dance
Looking forward to summer later in the year.
User avatar
danlucio
Drutt
Posts: 6
Joined: Tue Feb 27, 2018 3:02 am

Re: Amstrad CPC

Post by danlucio »

Are there cpc clones around the world like ZX line?
User avatar
PeterJ
Site Admin
Posts: 6858
Joined: Thu Nov 09, 2017 7:19 pm
Location: Surrey, UK

Re: Amstrad CPC

Post by PeterJ »

Hi, [mention]danlucio[/mention] It looks like there were a number including one from East Germany.

https://en.m.wikipedia.org/wiki/Amstrad_CPC

Go to the models / clones section
User avatar
danlucio
Drutt
Posts: 6
Joined: Tue Feb 27, 2018 3:02 am

Re: Amstrad CPC

Post by danlucio »

PeterJ wrote: Fri Mar 02, 2018 10:16 pm Hi, @danlucio It looks like there were a number including one from East Germany.

https://en.m.wikipedia.org/wiki/Amstrad_CPC

Go to the models / clones section

Thx PeterJ, looks like ZX line was by far much more cloned
Ralf
Rick Dangerous
Posts: 2279
Joined: Mon Nov 13, 2017 11:59 am
Location: Poland

Re: Amstrad CPC

Post by Ralf »

The graphic modes that you mention are "official" modes

Just like with Spectrum multicolor you can do some tricks on CPC.

One trick which I have seen is changing the palete in the middle of the screen

See Strider. It's 4 colour mode but playing area and menu have different sets of colours:

Image
User avatar
Pegaz
Dynamite Dan
Posts: 1209
Joined: Mon Nov 13, 2017 1:44 pm

Re: Amstrad CPC

Post by Pegaz »

Amstrad also has overscan capabilities, so the screen can be expanded in all modes to 264x192, 544x384 and 768x544 pixels.
I dont know how many games are using this technique, but there are some examples in overscan mode:
[media]https://www.youtube.com/watch?v=MmXl3BAjqMU[/media]
[media]https://www.youtube.com/watch?v=Hj1YssyLx5s[/media]
spectron
Drutt
Posts: 25
Joined: Thu Mar 29, 2018 3:27 pm

Re: Amstrad CPC

Post by spectron »

You might also notice a similarity with the BBC micro. Could be because they both used the Motorola 6845 video generator.

& CGA in the PC for that matter
User avatar
Joefish
Rick Dangerous
Posts: 2042
Joined: Tue Nov 14, 2017 10:26 am

Re: Amstrad CPC

Post by Joefish »

Apart from Spectrum clones, that came across with blocky attributes, not a lot of games used the 4-colour mode. And the ones that did showed some poor choices of colour. Look at that Strider screenshot - the scoreboard is better coloured than the game!
Head Over Heels looks particularly good. Although what you might notice there, and in a few other games, is sprites only appearing to use two colours. What they're actually doing is using two colours and black, and they're using the fourth colour index in the bitmap as the mask of the sprite, to save having to have a separate mask. Knight Lore doesn't even use the remaining colour in the backdrops. But it's sprites won't take up any more memory than the Spectrum ones.
spectron
Drutt
Posts: 25
Joined: Thu Mar 29, 2018 3:27 pm

Re: Amstrad CPC

Post by spectron »

Joefish wrote: Tue May 15, 2018 1:34 pm Knight Lore doesn't even use the remaining colour in the backdrops. But it's sprites won't take up any more memory than the Spectrum ones.
I'll bet it unpacks the required ones to 4 colour mode when switching screens though!
User avatar
Joefish
Rick Dangerous
Posts: 2042
Joined: Tue Nov 14, 2017 10:26 am

Re: Amstrad CPC

Post by Joefish »

I thought you could do it without unpacking, but the Amstrad doesn't do its graphics in separate bitplanes, so you can't easily form a mask from the sprite data. Maybe it does expand 2-bit sprite images into more data before it can use them. Seems a lot of trouble though.
AndyC
Dynamite Dan
Posts: 1388
Joined: Mon Nov 13, 2017 5:12 am

Re: Amstrad CPC

Post by AndyC »

spectron wrote: Tue May 15, 2018 12:12 pm You might also notice a similarity with the BBC micro. Could be because they both used the Motorola 6845 video generator.

& CGA in the PC for that matter
Although the Amstrad does use a 6845 in it's video generation, it's really only to provide signal timing for a frame with most of the display work actually being done by a custom gate array.
Joefish wrote: Tue May 15, 2018 6:19 pm I thought you could do it without unpacking, but the Amstrad doesn't do its graphics in separate bitplanes, so you can't easily form a mask from the sprite data. Maybe it does expand 2-bit sprite images into more data before it can use them. Seems a lot of trouble though.
The usual way of masking sprites on the CPC is just to treat INK 0 as the transparent colour, giving you three other sprite colours in Mode 1 or 15 in Mode 0. A completely separate mask (as on the Speccy) is usually overkill and requires a lot more memory. Usually a 256 byte page aligned masking table is used to look up the correct mask byte value for any given byte in a sprite (this can also allow for other tricks like flashing a sprite solid white by just using a different masking table).
User avatar
1024MAK
Bugaboo
Posts: 3104
Joined: Wed Nov 15, 2017 2:52 pm
Location: Sunny Somerset in the U.K. in Europe

Re: Amstrad CPC

Post by 1024MAK »

On any system, the Motorola 6845 CRT controller (which was also available from other semiconductor manufacturers) ONLY provides timing signals and address control lines for screen memory control. It has nothing to do with pixel data.

Other circuitry has to be provided to generate the pixel information. In text only systems, this would be some memory chips (RAM or RAM and ROM, the ROM containing character font data) and a parallel to serial converter. Plus some logic support chips.

In the Acorn BBC Micro, there is a custom Acorn chip (either a "Video ULA" or "VideoProc"). Plus some logic support chips.

In the Amstrad CPC machines, the Amstrad custom chip (the gate array, an application specific custom chip) does all the handling of the pixel data.

Mark
:!: Standby alert :!:
“There are four lights!”
Step up to red alert. Sir, are you absolutely sure? It does mean changing the bulb :dance
Looking forward to summer later in the year.
User avatar
Joefish
Rick Dangerous
Posts: 2042
Joined: Tue Nov 14, 2017 10:26 am

Re: Amstrad CPC

Post by Joefish »

AndyC wrote: Tue May 15, 2018 6:43 pmThe usual way of masking sprites on the CPC is just to treat INK 0 as the transparent colour, giving you three other sprite colours in Mode 1 or 15 in Mode 0. A completely separate mask (as on the Speccy) is usually overkill and requires a lot more memory. Usually a 256 byte page aligned masking table is used to look up the correct mask byte value for any given byte in a sprite (this can also allow for other tricks like flashing a sprite solid white by just using a different masking table).
That makes sense. With the pixels packed into bytes you couldn't easily implement a single-bitplane mask. It explains why the sprites in Head Over Heels don't use all 4 colours, but the backdrops do.

But you don't have to re-use the background (black) as one of the sprite colours. They've retained it because they've simply done a re-colouring of the monochrome Speccy sprites, which need black for outlining. The sprites could be drawn in three distinct colours, though in that case the sprites would have to be drawn solidly in those three colours; any black pixels would be transparent...
AndyC
Dynamite Dan
Posts: 1388
Joined: Mon Nov 13, 2017 5:12 am

Re: Amstrad CPC

Post by AndyC »

Joefish wrote: Thu May 17, 2018 11:49 am
AndyC wrote: Tue May 15, 2018 6:43 pmThe usual way of masking sprites on the CPC is just to treat INK 0 as the transparent colour, giving you three other sprite colours in Mode 1 or 15 in Mode 0. A completely separate mask (as on the Speccy) is usually overkill and requires a lot more memory. Usually a 256 byte page aligned masking table is used to look up the correct mask byte value for any given byte in a sprite (this can also allow for other tricks like flashing a sprite solid white by just using a different masking table).
That makes sense. With the pixels packed into bytes you couldn't easily implement a single-bitplane mask. It explains why the sprites in Head Over Heels don't use all 4 colours, but the backdrops do.

But you don't have to re-use the background (black) as one of the sprite colours. They've retained it because they've simply done a re-colouring of the monochrome Speccy sprites, which need black for outlining. The sprites could be drawn in three distinct colours, though in that case the sprites would have to be drawn solidly in those three colours; any black pixels would be transparent...
There isn't really a "background" colour, per se. As far as the Amstrad hardware goes all colours are equal - it's not like the C64 for example, where one of the palette entries is a special colour across the whole screen.

In the case of Head Over Heels on the Amstrad, it's actually using the second colour in the palette as the transparent colour (which is the one also being used for the "unselected" items/character in the status panel). You are entirely right that they've clearly chosen to just colour in some of the Speccy graphics which isn't strictly necessary. Aside from being quicker form a work perspective, it probably also helps with the "unselected" bit too as that can then be the same graphic data but mapped onto just two colours whilst still looking correct - that would be harder to achieve with a "solid" three colour arrangement.
User avatar
Joefish
Rick Dangerous
Posts: 2042
Joined: Tue Nov 14, 2017 10:26 am

Re: Amstrad CPC

Post by Joefish »

Ah, but is colour index 0 then also the border colour, or is that a separate setting?
One thing that can catch Speccy coders out on moving to the ST or Amiga is that you can no longer set the border colour independently of the screen - it assumes the colour of palette index 0.

It's particularly a problem on the Amiga when you want other scenery layers to show through or sprites to go behind things, then you have to use colour 0 as your see-through background index. Then if you want to do a pretty raster effect on your horizon, the colour changes spill over into the border! One of the stunts you might not realise Shadow of the Beast is doing is redefining colour 0 at the edges of the 'border' from black to sky and back again individually on every line of the display (whilst sneakily lopping 16 pixels off each side). On the ST you just arrange your (software) masking logic to leave a different colour index in the background.
AndyC
Dynamite Dan
Posts: 1388
Joined: Mon Nov 13, 2017 5:12 am

Re: Amstrad CPC

Post by AndyC »

Nope, the border is a whole different colour entirely.
User avatar
PeterJ
Site Admin
Posts: 6858
Joined: Thu Nov 09, 2017 7:19 pm
Location: Surrey, UK

Re: Amstrad CPC

Post by PeterJ »

I've been playing with the Amstrad CPC over the last few days. I've always had some negativity about it, but thought I would give it another go.

Mode 0, which is the 160 x 200 does have the huge advantage of having the option of having a different colour on each double width pixel (max 16). So multi-colour characters look very nice.

Image

Now, can someone invent a computer with an 8bit feel, with the same advantages as Mode 0, but at 320 x 200 please
User avatar
Pegaz
Dynamite Dan
Posts: 1209
Joined: Mon Nov 13, 2017 1:44 pm

Re: Amstrad CPC

Post by Pegaz »

PeterJ wrote: Tue Jan 12, 2021 7:37 pmNow, can someone invent a computer with an 8bit feel, with the same advantages as Mode 0, but at 320 x 200 please
Enterprise and MSX 2 are closest to what you want.
I'm not sure there are stronger 8bit models, in terms of graphics capabilities.
Matt_B
Manic Miner
Posts: 655
Joined: Sun Nov 01, 2020 8:47 am

Re: Amstrad CPC

Post by Matt_B »

The SAM Coupe comes pretty close, with 256x192 at 4bpp.

There are a bunch of Japanese machines like the Sharp X1 Turbo, NEC PC88 VA and Fujitsu FM7 AV which can go way beyond that, even. Mind you, they were all around the Amiga in terms of price, so not exactly competing with the regular 8-bit market.
User avatar
Jbizzel
Dynamite Dan
Posts: 1529
Joined: Mon May 04, 2020 4:34 pm
Location: Hull
Contact:

Re: Amstrad CPC

Post by Jbizzel »

https://youtu.be/kHH1V-zOlZk

This remake of Rtype for the CPC is astonishing.

The original Rtype spectrum port was a mistake, they should have devoted more time to it.
User avatar
lovebug
Drutt
Posts: 29
Joined: Mon Jan 11, 2021 7:01 pm

Re: Amstrad CPC

Post by lovebug »

oh my that r-type remake is amazing
lovebug.ml
randomly changing stuff in your code until it works is "hacky" and "bad coding practice" but if you can do it fast enough its "machine learning"
Post Reply