PCD on MSX.

Written by Henrik Gilvad.

In Tilburg 94 I showed a few Photo CD pictures on the MSX 
with a V9990 graphicboard. Unfortunately I only had 2 CD's at 
that time and I forgot the one with no-so-dirty pictures in a 
friends CDROM drive before I left for Tilburg.

What is PCD ?

PCD stands for "Photo CD" and is something that KODAK came up 
with in 1990. It won several prices for being the 'best of 
whats new'.

Today everyone can get their holiday fotographs on a CD 
instead of on film. One CD can store 120 pictures if they are 
stored at the same time. If you don't have 120 pictures then 
you can take it easy and just start with what you have. Later 
you just give back the CD and a new film then the photoshop 
will add the pictures to what is already on the CD. This can 
be done, I think, 4 times and is called 'MULTI SESSION'. 
Because a CD can only be written once then they have to write 
a complete new directory for each new 'session', therefore it 
can only take up to 100 pictures.

Each picture is stored in 5 different resolutions:

 192 * 128
 384 * 256
 768 * 512
1536 *1024
3072 *2048

X * Y !

The first 3 resolutions are stored in a kind of 'YUV' color 
mode which is near to what we have on MSX 2+ (YJK).

The greytone part of the picture are stored for each dot. The 
colorinformations are shared between 4 dots. The human eye 
can seperate Greytones 4 times better than the 
colorinformation so it should not matter that the colors are 
compressed like this if the resolution is big enough.

The last 2 resolutions are more difficult because they are 
based on a mathematically result from the lower resolution 
and then 'Xor'ed with the data stored for this resolution. 
This saves a lot of space but takes a lot of time to do.

On MSX 2+ we use 4 horizontally dots to share the color 
information, this is not so good in low resolutions. The PCD 
YUV mode shares the colorinformations in 2*2 dots, this means 
that the COLOR resolution is 2 times lower in X and Y than 
the Greytone resolution.


PCD on MSX.

Photo CD is popping up for any computer system around so I 
thought we should also have it on MSX. When I could read the 
CDROM format then I begun to explore the PCD format and in 1 
weekend I made the first converting routine for the V9990.

This routine loads the PCD file directly from the CD, 1 
picture can take like 3 Mbytes of space so there was no 
reason in copying the file to harddisk or floppydisk before 
the convertion.

Today I have made convertions for 3 modes of the V9990:
Screen 8, 256 colors.	Up to 512*424 shown. 1024*512 stored.
YUV, 19268 diffent.	--!!--
RGB16bit, 32k		Up to 512*424 shown. 512*512 stored.

After the convertion you can scroll in the picture with the 
mouse and 'zoom' with the buttons. (Made simply by changing 
the resolution to a lower one.)

The YUV have perfect colors but is not as sharp as the RGB16.
The RGB16 have a litle convertion error, blue sometimes get a 
bit too magenta but I am working on it.

PCD for MSX2+ ?

The only thing I need to change in the program is the formula 
which converts 8 bit RGB to Screen 12 YJK in a resonable 
matter. When this is done then the MSX 2+ can show 256*424 
dots and store 256*512 dots.

The great thing about PCD is that you get a perfect DIGITIZER 
to convert pictures into digital values that you can put on 
the screen. This gives better pictures than most digitizers 
we have for MSX can perform. You have no problems with bad 
rebuilded digitizers or bad VCR's etc. The only thing needed 
is that you can take a good sharp photograph.


My PCD programs only works on my SCSI interface but will work 
on other interfaces which are using the "WD33C93A" chip.
No Turbo R is nessesary but it is nice to have because the 
convertionspeed is so much higher on it.

H.G.
                                                   