ListReference

function

slRparaInitSet


Store rotation parameter table in VRAM area

Form

    #include "sgl.h"

    ROTSCROLL * addr_A;

    void slRparaInitSet (addr_A);

argument

    ROTSCROLL * addr_A-VRAM start address to store rotation parameter table

Number of returns

    void --Nothing is returned.

function

    VRAM the rotation parameter table (size: 60H) used for rotation scrolling
    Store in the area. Since parameter B is stored from the position of parameter A + 20H, E0H is required in total for parameters A and B.
The default storage address when this function is not used is 25E3FF00H.
Be sure to specify the absolute address for addr_A.

Example

    slRparaInitSet ((void *) (0x25e5fe00));

reference

 slMakeKtable
 slKtableRA
 slKtableRB
 slRparaReadCtrlRA
 slRparaReadCtrlRB
 MsScreenSizeX
 MsScreenSizeY
 Resolution
 VDP2_RPTA
 ScrRotPtr
 rpara_vram_adr
 RotScrParA
 RotScrParB 



ListReference

function

slCurRpara


Specify the operating parameter of the rotation parameter

Form

    #include "sgl.h"

    Uint16 mode;

    void slCurRpara (mode);

argument

    Uint16 mode-Rotation parameters

Number of returns

    void --Nothing is returned.

function

    Of the rotation parameters A and B, specify the parameter to be operated.
The following parameters are entered in mode.
RA : Rotation parameter A RB : Rotation parameter B

Example

    / * Operation of rotation coefficient A * /
    slCurRpara ( RA );
    slUnitMatrix ( CURRENT );
    slTranslate ( toFIXED (10.0), toFIXED (20.0), toFIXED (15.0));
    slRotZ ( debugtoANG (10.0));
    slScrMatSet ();

    / * Operation of rotation coefficient B * /
    slCurRpara ( RB );
    slUnitMatrix ( CURRENT );
    slTranslate ( toFIXED (100.0), toFIXED (-100.0), toFIXED (15.0));
    slRotZ ( debugtoANG (10.0));
    slScrMatSet ();

reference

 slRparaMode
 slScrMatSet
 slScrMatConv
 ScrRotPtr
 RotScrParA
 RotScrParB 



ListReference

function

slRparaMode


Specify the mode of use of rotation parameters

Form

    #include "sgl.h"

    Uint16 mode;

    void slRparaMode (mode);

argument

    Uint16 mode --Rotation parameter mode (see below).

Number of returns

    void --Nothing is returned.

function

    Specify the usage mode of rotation parameters A and B.
The following parameters are entered in mode.
RA : Only rotation parameter A is used RB : Only rotation parameter B is used K_CHANGE : Image switching according to the coefficient data of rotation parameter A W_CHANGE : Image switching in the rotation parameter window

Example

    slRparaMode ( RA );

reference

 slCurRpara
 slRparaMode
 slRparaReadCtrlRA
 slRparaReadCtrlRB
 VDP2_RPMD 



ListReference

function

slMakeKtable


Create a table of coefficients

Form

    #include "sgl.h"

    void * addr_A;

    void slMakeKtable (* addr_A);

argument

    void * addr_A --VRAM address of coefficient table

Number of returns

    void --Nothing is returned.

function

    Create a table of coefficients for use in 3D rotation.
2 Create one bank of Word-sized data. When using this function, Function slKtableRA ( K_2WORD | K_ON | K_DOT | K_FIX ) slKtableRB ( K_2WORD | K_ON | K_DOT | K_FIX ) Please use together.

Example

    slRparaInitSet ((void *) (0x25e5fe00));
    slKtableRA ((void *) (0x25e40000), K_2WORD | K_ON | K_DOT | K_FIX );
    slMakeKtable ((void *) (0x25e40000));

    slRparaMode ( K_CHANGE );

reference

 slRparaInitSet
 slKtableRA
 slKtableRB
 slRparaReadCtrlRA
 slRparaReadCtrlRB
 VDP2_KTAOF
 k_table_adr 



ListReference

function

slKtableRA



ListReference

function

slKtableRB


Setting the address of the coefficient table

Form

    #include "sgl.h"

    void * addr_A;
    Uint16 mode;

    void slKtableRA (addr_A, mode);
    void slKtableRB (addr_A, mode);

argument

    void * addr_A --Coefficient table VRAM address Uint16 mode --Coefficient table control mode (described later)

Number of returns

    void --Nothing is returned.

function

    Set the address of the coefficient table in the register, and at the same time, how to use the coefficient table,
    Specify the configuration.
The following parameters are entered in mode. K_OFF | K_ON : Table use K_2WORD | K_1WORD : Coefficient data size K_MODE0 | K_MODE1 | K_MODE2 | K_MODE3 : Coefficient mode K_LINECOL : Line color K_DOT | K_LINE : Deformation unit K_FIX : Fixed coefficient Please specify by connecting with.

Example

    Use mode 0 (pick up the x and y expansion factors from the coefficient table) and
    When using the coefficient in 2 Word mode, dot by dot.
#define RBG0RA_RPARA_ADR (void *) VDP2_VRAM_A0 void slKtableRA (RBG0RA_RPARA_ADR, K_ON | K_2WORD | K_MODE0 | K_DOT );

reference

 slRparaInitSet
 slRparaReadCtrlRA
 VDP2_KTCTL
 slRparaReadCtrlRB
 VDP2_KTAOF
 RotScrParA
 RotScrParB 



ListReference

function

slRparaReadCtrlRA



ListReference

function

slRparaReadCtrlRB


Specifying how to read the rotation parameters

Form

    #include "sgl.h"

    Uint16 type;

    void slRparaReadCtrlRA (type);
    void slRparaReadCtrlRB (type);

argument

    Uint16 type --How to read rotation parameters (see below).

Number of returns

    void --Nothing is returned.

function

    Specifies whether to reread the rotation parameters Xst, Yst, and KAst for each line.
type is LnRd_Xst , LnRd_Yst , LnRd_KAst Are specified by connecting them with'|'.

Example

    slRparaReadCtrlRB ( LnRd_Yst );

reference

 slRparaInitSet
 slKtableRA
 slKtableRB
 VDP2_RPRCTL

return
Copyright SEGA ENTERPRISES, LTD., 1997