FNX6809 GraphicsVTIOCalls

From F256 Foenix
Revision as of 08:19, 6 October 2024 by Jfed (talk | contribs)
Jump to navigationJump to search

Graphics Summary

vtio Get/Set Stat Calls

SS.AScrn

Allocate a bitmap screen

Entry: R$Y = bitmap# (0-2)
       R$X = screentype (0=320x240, 1=320x200)
Exit:  B = A non-zero error code.
      CC = Carry flag clear to indicate success
       X = Starting Page# of bitmap address

SS.DScrn

Display Screen Settings

Set MCR to display text or graphics or both

Entry: R$X = Vicky_MCR Low Byte
       R$Y = Vicky_MCR High Byte
Exit:  Nothing. This just sets the register and updates driver variables

VICKY MASTER CONTROL REGISTER to enable graphics and capabilities

| 7 |   6   |    5   |   4  |    3   |   2   |   1   |   0  |
| X | GAMMA | SPRITE | TILE | BITMAP | GRAPH | OVRLY | TEXT |
|   -----   | FON_SET|FON_OV| MON_SLP| DBL_Y | DBL_X | CLK70|
$FFC0 MASTER_CTRL_REG_L, MASTER_CTRL_REG_H

********************************************************************
* vtio graphics constants (in f256.d)
********************************************************************
* Constants used in SS.DScrn to set the display screen type
FX_GAM             equ       %01000000              Gamma Correction On
FX_SPR             equ       %00100000              Sprites On
FX_TIL             equ       %00010000              Tile Maps On
FX_BM              equ       %00001000              Bitmaps On
FX_GRF             equ       %00000100              Graphics Mode On
FX_OVR             equ       %00000010              Overlay Text on Graphics
FX_TXT             equ       %00000001              Text Mode On
FT_FSET            equ       %00100000              Font Set 1 On (0=Font Set 0)
FT_FOVR            equ       %00010000              FG and BG colors displayed when overlay text 0=transparent
FT_MON             equ       %00001000              Turn off monitor sync and sleep monitor
FT_DBX             equ       %00000100              Double-wide text mode characters
FT_DBY             equ       %00000010              Double-high text mode characters
FT_CLK70           equ       %00000001              70 Hz screen (640x400 txt,320x200 grf)
FX_OMIT            equ       %11111111              Setting for SS.DScrn don't change first byte in MCR
FT_OMIT            equ       %11111111              Setting for SS.DScrn don't change second byte in MCR 

SS.PScrn

Position Screen Layers

Set layer to display a screen

Entry: R$X = layer (0-2)
       R$Y = bitmap# (0-2), tilemap (4-6)
       
Exit:  B = A non-zero error code.
      CC = Carry flag clear to indicate success

SS.FScrn

Free a bitmap screen

Entry: R$Y = bitmap# (0-2)
Exit:  B = A non-zero error code.
      CC = Carry flag clear to indicate success

SS.DfPal

Define Palette and populate a CLUT from Memory Module

Entry: R$X = CLUT # (0-3)
       R$Y = pointer to location of data in caller process
       (Caller must load data module)
Exit:  B = A non-zero error code.
      CC = Carry flag clear to indicate success