Creating New Screen Modes
by Glynn Clements

This program creates modules to implement additional screen modes. When run, it prompts for the details of the new mode, and assembles a module to implement it. The assembled module is saved within the !NewModes application directory.

The details requested are the number of the new mode, screen size in rows and columns, number of colours, and x and y eig-factors. The new mode number should be between 30 and 255. Maximum number of rows is 36 on a PAL monitor or 65 on a multi-sync. Maximum number of columns is 160, or 100 if there are more than 36 rows. For number of colours enter 0,1,2 or 3 for 2,4,16 or 256 colours respectively.

The x and y eig-factors determine the size of a pixel in OS co-ordinates. If the x eig-factor is x and the y eig-factor is y, then a pixel measures 2^x by 2^y OS co-ordinates. In mode 12 x-eig is 1 and y-eig is 2, while in mode 20 x-eig and y-eig are both 1. The Wimp works in terms of OS co-ordinates, so the x and y eig-factors determine the scaling of text, icons and windows under the Wimp.

This directory contains a number of modules created in this way, each one implementing a new mode. Once the module has been loaded, the new mode can be used like any other. Mode99 is 160 columns by 36 lines, 16 colours, and works on a standard PAL monitor, while Mode98 is 100 columns by 64 lines, 16 colours, but with a changed y-eig factor, allowing 64 text lines under the Wimp.

Note that it may be necessary to adjust the scaling controls on the monitor in order to be able to see the entire screen. This program was tested using a standard Acorn/Philips PAL monitor. Other monitors may need lines 330-450 modifying in order for the new modes to work correctly.
