|Version 6 (modified by sam, 5 years ago) (diff)|
Oric Atmos graphics using libpipi
libpipi can load and save images in the Oric screen format. The Oric screen format is one of the most twisted standards and very little artwork exists for this vintage computer. It was therefore the perfect challenge for the Caca Labs image processing team.
The graphical part of the Oric screen has 240×200 pixels and can only display 8 different colours (black, blue, red, green, cyan, magenta, yellow and white). Each horizontal group of 6 pixels can only use two different colours: the foreground and the background colours. The background or the foreground colour may also be changed (one at a time), but while doing so the next 6 pixels cannot be chosen: they will use the background colour instead. Finally, a special bit may be activated to display the current group of pixels in reverse video.
libpipi is pretty slow: around 2 minutes to process an image on a modern computer at full quality. It is certainly possible to make it run faster, but I am not aware of trivial ways to do so, except by reducing the computation depth (hence reducing the quality).
There used to be a program called img2oric to do this task, but libpipi’s pipi utility is now far more powerful.
Windows executable (28 Sep 2008 snapshot): pipi.exe.
For those interested, the relevant source code is in oric.c. You can also download a sample OUTPUT.TAP file as generated by libpipi. To load it into an Oric computer, or an emulator such as xeuphoric, just type HIRES:CLOAD"OUTPUT" and it will be immediately displayed.
Convert an Oric .tap file into a BMP:
pipi screen.tap -o image.bmp
Convert a BMP file into an Oric .tap file:
pipi image.bmp -o screen.tap
Convert a BMP file into an Oric .tap file, then reopen the .tap file and save it as another BMP:
pipi image.bmp -o screen.tap screen.tap -o screen.bmp
Open a BMP file, convert it to linear colour space (gamma = 1.0), apply a 2×2 Gaussian blur filter and save it into an Oric .tap file:
pipi image.bmp --gamma 1 --gaussian 2 -o screen.tap
Open a .tap file, apply a 3×3 Gaussian blur filter, and save it back to another .tap file:
pipi input.tap --gaussian 3 -o output.tap
These images show how libpipi performs. The results may not seem terribly clean, but they are probably better than anything that has been seen so far on an Oric computer.
These first 4 images show the results on the same images than the ones on Dbug’s PictConv website, to illustrate the improvements over the traditional RGB separation technique.
The following images show libpipi’s results with grayscale images and cartoon images.
The following images use real Oric artwork, taken from the Buggy Boy and the VIP 4 demos: they are almost pixel-perfect.
The libpipi Oric codec was written by Sam Hocevar. Thanks to Jean-Yves Lamoureux, Mickaël Pointier, Robert Chéramy, André Chéramy and Fabrice Frances for their help, their work and the information they provided.