SGL User's ManualPROGRAMMER'S STRUCT
BackForward

8-3. Screen mode

The screen mode is for determining the screen resolution, screen size, display device, etc. Sega Saturn supports a wide variety of screen modes, but SGL specifically adopts and supports the following 16 screen modes.

Table 8-1 Screen modes

 Display device
 TV screen mode
 Graphic mode
 Interlaced mode
 Resolution: Vertical x Horizontal
(pixel)
NTSC method normal Graphic A Non-interlaced 320 x 224
320 x 240
Interlace 320 x 448
320 x 480
Graphic B Non-interlaced 352 x 224
352 x 240
Interlace 352 x 448
352 x 480
High resolution Graphic A Non-interlaced 640 x 224
640 x 240
Interlace 640 x 448
640 x 480
Graphic B Non-interlaced 704 x 224
704 x 240
Interlace 704 x 448
704 x 480

note)
The default value of the screen mode is 320 horizontal x 224 vertical.

For details on the screen mode, refer to "HARDWARE MANUAL vol.2: VDP2 User's Manual".

In SGL, use the library function "slInitSystem" to initialize scrolling and set screen mode.
In addition, this function "slInitSystem" also performs initialization and initial settings other than scrolling at the same time, but for details, refer to the default list at the end of the reference manual "Function Reference".

[Void slInitSystem (Uint16 type, TEXTURE * texptr, Uint16 cnt);]
Initialize various settings including scrolling, set screen mode, and set drawing processing unit.
Substitute the #define value indicating the screen mode, the start address of the memory where the texture is stored (null if the texture is not used), and the integer value (1 to 127) indicating the screen processing unit to the parameters.
The default value is the resolution / width 320 x height 224 pixel mode.
In addition, the resolution of 352 horizontal x 240 vertical pixels cannot be displayed because the resolution is insufficient on a normal TV monitor. The resolution / width 352 x height 240 pixel mode can be completely displayed only when using a monitor capable of RGB input.

Table 8-2 Example of “slInitSystem” parameter assignment value (TV_MODE)
Resolution (pixels)
Width 320 x length 224 352 horizontal x 240 vertical
Substituted value TV_320x224 TV_352x240

note)
The values in the above table are defined in “sl_def.h”.

When the resolution is 320 x 224 pixels (non-interlaced), there is no texture, and the drawing processing unit is 1 (1/60 seconds), the function "slInitSystem" is as shown in the figure below.

<Fig. 8-4 Example of using the function "slInitSystem">

● System initialization ●

slInitSystem (TV_320x224, NULL, 1); | | | | | Drawing processing unit: 1 (1/60 seconds) | No texture Resolution: 320 x 224 pixels

About drawing processing unit

Setting the drawing processing unit in the parameter means specifying how often the image should be rewritten.
In the case of SGL, 1/60 seconds for non-interlaced and 1/30 seconds for double-dense interlaced are set as one drawing processing unit, and can be set in the range of 1 to 127.
The longer the rewrite interval, the more arithmetic processing can be performed, but the longer the drawing interval, the more awkward the appearance will be when drawing continuous images.
Conversely, if the rewrite interval is short, a smooth image can be achieved, but the amount of calculation that can be processed at one time decreases.


BackForward
SGL User's ManualPROGRAMMER'S STRUCT
Copyright SEGA ENTERPRISES, LTD., 1997