Japanese
HARDWARE ManualVDP2 User's ManualChapter 12 Color calculation
BackForward
VDP2 User's Manual/Chapter 12 Color Calculation

●Color calculation control register

The color calculation control register controls color calculation. This is a 16-bit write-only register located at address 1800ECH. The value is cleared to 0 after power-on or reset, so be sure to set it.

CCCTL 1800ECH
   15   
   14   
   13   
   12   
   11   
   10   
   09   
   08   
 BOKEN
 BOKN2
 BOKN1
 BOKN0
 -
 EXCCEN
 CCRTMD
 CCMD

   07   
   06   
   05   
   04   
   03   
   02   
   01   
   00   
 -
 SPCCEN
 LCCCEN
 R0CCEN
 N3CCEN
 N2CCEN
 N1CCEN
 N0CCEN

Blur operation enable bit : Gradation enable bit (BOKEN), bit 15
Specify whether to use the blur calculation function.

BOKEN process
0 Do not use blur calculation function
1 Using the blur calculation function

Setting this bit to 1 disables the extended color calculation function.
The blur calculation function can only be used when the TV screen mode is normal mode and the color RAM mode is mode 0.

Blur screen number bit : Gradation number bit (BOKN2 to BOKN0), bits 14 to 12
Specify the screen that uses the blur calculation function.

BOKN2 BOKN1 BOKN0 Blur calculation function usage screen
0 0 0 sprite
0 0 1 RBG0
0 1 0 NBG0 or RBG1
0 1 1 Setting prohibited
1 0 0 NBG1 or EXBG
1 0 1 NBG2
1 1 0 NBG3
1 1 1 Setting prohibited

Extended color calculation enable bit (EXCCEN), bit 10
Specify whether to use the extended color calculation function.

EXCCEN process
0 Do not use extended color calculation function
1 Use extended color calculation functions

The blur calculation function cannot be used at the same time. This bit is ignored when the BOKEN bit is 1.
The extended color calculation function can only be used when the TV screen mode is normal mode, and cannot be used when the TV screen mode is high resolution or dedicated monitor mode.

Color calculation ratio mode bit (CCRTMD), bit 9
Specifies the color calculation ratio mode.

CCRTMD mode process
0 0 Specify the color calculation ratio on the top image side
1 1 Specify the color calculation ratio on the second image side

Whether or not to perform normal color calculations is always specified on the top image side.

Color calculation mode bit (CCMD), bit 8
Specifies the color calculation mode.

CCMD mode process
0 0 Add according to the color calculation ratio register value
1 1 Add as is

In mode 1, the value of the color calculation ratio register for each screen is ignored.

Color calculation enable bit
(N0CCEN, N1CCEN, N2CCEN, N3CCEN, R0CCEN, LCCCEN, SPCCEN)
Specify whether to perform color calculation (color calculation enable).

N0CCEN 1800ECH bit 0 For NBG0 (or for RBG1)
N1CCEN 1800ECH bit 1 For NBG1 (or for EXBG)
N2CCEN 1800ECH bit 2 For NBG2
N3CCEN 1800ECH bit 3 For NBG3
R0CCEN 1800ECH bit 4 For RBG0
LCCCEN 1800ECH bit 5 For LNCL
SPCCEN 1800ECH bit 6 for sprites

xxCCEN process
0 Do not perform color calculations
1 Perform color calculations
[Note] xx in the bit name is N0, N1, N2, N3, R0, LC, or SP.

When performing color calculations between the top image and the second image, control is done using the color calculation enable bit on the top image side. When using the extended color calculation function, the connection between the second image and the third image is controlled by the color calculation enable bit on the second image side, and the connection between the third image and the fourth image is controlled by the color calculation enable bit on the third image side. Masu.

 

●Color calculation ratio register

The color calculation ratio register specifies the color calculation ratio. This is a 16-bit write-only register located at addresses 180108H to 18010EH. The value is cleared to 0 after power-on or reset, so be sure to set it.

CCRNA 180108H
   15   
   14   
   13   
   12   
   11   
   10   
   09   
   08   
 -
 -
 -
 N1CCRT4
 N1CCRT3
 N1CCRT2
 N1CCRT1
 N1CCRT0

   07   
   06   
   05   
   04   
   03   
   02   
   01   
   00   
 -
 -
 -
 N0CCRT4
 N0CCRT3
 N0CCRT2
 N0CCRT1
 N0CCRT0 

CCRNB 18010AH
   15   
   14   
   13   
   12   
   11   
   10   
   09   
   08   
 -
 -
 -
 N3CCRT4
 N3CCRT3
 N3CCRT2
 N3CCRT1
 N3CCRT0

   07   
   06   
   05   
   04   
   03   
   02   
   01   
   00   
 -
 -
 -
 N2CCRT4
 N2CCRT3
 N2CCRT2
 N2CCRT1
 N2CCRT0 

CCRR 18010CH
   15   
   14   
   13   
   12   
   11   
   10   
   09   
   08   
 -
 -
 -
 -
 -
 -
 -
 -

   07   
   06   
   05   
   04   
   03   
   02   
   01   
   00   
 -
 -
 -
 R0CCRT4
 R0CCRT3
 R0CCRT2
 R0CCRT1
 R0CCRT0 

CCRLB 18010EH
   15   
   14   
   13   
   12   
   11   
   10   
   09   
   08   
 -
 -
 -
 BKCCRT4
 BKCCRT3
 BKCCRT2
 BKCCRT1
 BKCCRT0

   07   
   06   
   05   
   04   
   03   
   02   
   01   
   00   
 -
 -
 -
 LCCCRT4
 LCCCRT3
 LCCCRT2
 LCCCRT1
 LCCCRT0

Color calculation ratio bit (for scroll screen) : Color calculation ratio bit
(N0CCRT4~N0CCRT0, N1CCRT4~N1CCRT0, N2CCRT4~N2CCRT0, N3CCRT4~N3CCRT0, R0CCRT4~R0CCRT0, LCCCRT4~LCCCRT0, BKCCRT4~BKCCRT0)
Specify the color calculation ratio for each scroll screen. The color calculation ratio is based on the value obtained by multiplying the RGB color data by 1/32.

N0CCRT4〜N0CCRT0 180108H bits 4-0 For NBG0 (or for RBG1)
N1CCRT4~N1CCRT0 180108H bits 12-8 For NBG1 (or for EXBG)
N2CCRT4~N2CCRT0 18010AH bits 4-0 For NBG2
N3CCRT4~N3CCRT0 18010AH bits 12-8 For NBG3
R0CCRT4~R0CCRT0 18010CH bits 4-0 For RBG0
LCCCRT4~LCCCRT0 18010EH bits 4-0 For LNCL
BKCCRT4~BKCCRT0 18010EH bits 12-8 For BACK

xxCCRT4 xxCCRT3 xxCCRT2 xxCCRT1 xxCCRT0 Color calculation ratio
Top image: Second image
0 0 0 0 0
 31:1
0 0 0 0 1
 30:2
0 0 0 1 0
 29:3
0 0 0 1 1
 28:4
0 0 1 0 0
 27:5
0 0 1 0 1
 26:6
0 0 1 1 0
 25:7
0 0 1 1 1
 24:8
0 1 0 0 0
 23:9
0 1 0 0 1
 22:10
0 1 0 1 0
 21:11
0 1 0 1 1
 20:12
0 1 1 0 0
 19:13
0 1 1 0 1
 18:14
0 1 1 1 0
 17:15
0 1 1 1 1
 16:16
1 0 0 0 0
 15:17
1 0 0 0 1
 14:18
1 0 0 1 0
 13:19
1 0 0 1 1
 12:20
1 0 1 0 0
 11:21
1 0 1 0 1
 10:22
1 0 1 1 0
 9:23
1 0 1 1 1
 8:24
1 1 0 0 0
 7:25
1 1 0 0 1
 6:26
1 1 0 1 0
 5:27
1 1 0 1 1
 4:28
1 1 1 0 0
 3:29
1 1 1 0 1
 2:30
1 1 1 1 0
 1:31
1 1 1 1 1
 0:32
[Note] xx in the bit name is N0, N1, N2, N3, R0, LC, or BK.

For information on the color calculation ratio register for sprites, see ` `●Color calculation ratio register '' in ``9.2 Priority and color calculation .''


BackForward
HARDWARE ManualVDP2 User's ManualChapter 12 Color calculation
Copyright SEGA ENTERPRISES, LTD., 1997