Risc OS specific ImageLib components
====================================
It is recommended that the reader refer to RISC OS programmer's reference
manual for a full description of the SWIs (Software Interrupts) used by the
Image Library, in particular, referring to:

  * 'Sprites'     in Volume 1,  begins p1-745.
  * 'JPEG images' in Volume 5a, begins p5a-143.
  * 'Colourtrans' in Volume 3,  begins p3-335.

SWIs used throughout image lib
------------------------------
OS_ReadModeVariable is used by all components to find out details about the
current screen display, specifically, the resolution, numbers of colours and
eigenvalues. The eigenvalues define the relationship between actual pixels of
the image and the co-ordinate system used to refer to the screen (OS Units).
Typically (though not always), there are 2 OS units for each pixel, so a
screen mode of 1280 x 1024 pixels might be referenced by a co-ordinate
system ranging from 0-2560 in X and 0-2048 in Y.

OS_SpriteOp provides many different operations on sprites, depending on the
reason code passed to it. This includes creating sprites, plotting sprites
and directing vdu output to sprites.

Colourtrans_GenerateTable is used to generate a colour translation table for
a sprite image. This table typically contains a piece of data for each logical
colour present in the sprite image. This data specifies the nearest colour in
the current screen mode. Sprites are then plotted, specifying a pointer to this
colour table, so that they display as well as possible in any particular screen
mode.

OS_Byte is used occasionally to determine the version of RiscOS that is
currently being run. Later versions feature enhanced colour handling and
if we are running on these versions, we will set flags in OS_SpriteOp to
force it to use the enhanced colour handling.
 
JPEG
----
RISC OS provides a module in ROM for direct plotting of JPEGs to the screen,
which the JPEG component of the image library uses (details of this are in
volume 5 of the PRMs).

If the IMAGE_FAST flag is set, then the JPEG image is plotted to a sprite.
This is done by directing VDU output to a sprite, with the SpriteOp SWI
in the SpriteExtend module (PRM volume 1) and reason code 60. The JPEG is
plotted and VDU output then directed back to the screen.

Render
------
Render uses OS_ReadVduVariables to read the current graphics clipping window.
This will typically correspond to the area that the window manager has asked
an application to redraw. Render use the window to decide how much of the
compressed data needs to be decompressed.

OS_ReadMonotomicTime is used to read the number of centiseconds elapsed
since the computer was turned on. Render uses this to calculate if it is
time to display the next frame of an animation or not.