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

■12.2 Special color calculation function

The special color calculation function is a function that specifies color calculation enable not only for the entire screen but also for each character or dot, and has the following four modes.

  1. Color calculation enable is specified for each screen.
  2. Color calculation enable is specified for each character.
  3. Color calculation enable is specified for each dot.
  4. Color calculation enable is specified by the most significant bit of color data.

When specifying color calculation enable for each screen, color calculation is performed when the value of the color calculation enable bit in the color calculation control register corresponding to each scroll screen is 1.
When specifying for each character, color calculation is performed only on character patterns whose special color calculation bit value in the pattern name data is 1 on the scroll screen where the color calculation enable bit is specified as 1. For details on the special color operation bits in pattern name data, please refer to " 4.6 Pattern Name Table (Page) ".

When specified for each dot, the dot specified in the special function code in the character pattern for which the value of the special color calculation bit in the pattern name data of the scroll screen whose color calculation enable bit is specified as 1 is specified. Color calculations are performed only on dots that match the color code. Do not set this mode when the scroll screen color format is RGB format. For special function codes, see 10.3 Special Function Codes .

When specifying using the most significant bit of color data, if the scroll screen with the color calculation enable bit set to 1 is in palette format, color calculation will be applied only to dots using color data with the most significant bit set to 1. I will do it. If this mode is specified when the scroll screen with the color calculation enable bit set to 1 is in RGB format, color calculation will always be performed.

If mode 1 or 2 is specified on a scroll screen where the display format is bitmap format, the special color calculation bits in the bitmap palette number register are used instead of the special color calculation bits in the pattern name data.
Table 12.3 shows the special color calculation modes.

Table 12.3 Special color calculation modes
 special color
Calculation mode
 Special color calculation
Specified content
 color format
 Color calculation enable condition
mode 0 Specify for each screen pallet format
or RGB format
Color operation enable bit = 1
mode 1 for each character
designation
pallet format
or RGB format
Color operation enable bit = 1
and
Special color calculation bits in pattern name data
t = 1
mode 2 Specify for each dot pallet format Color operation enable bit = 1
and
Special color calculation bits in pattern name data
t = 1
and
Dot color code specified in special function code
dot that matches the code
RGB format Setting prohibited
mode 3 Color data
Specified by upper bits
pallet format Color calculation enable bit = 1
and
Using color data with the most significant bit = 1
Dot
RGB format Color calculation enable bit = 1

Special color calculation mode can be specified only for the top image. Special color calculation modes other than the top image are fixed to mode 0.

 

●Special color calculation mode register

The special color calculation mode register specifies the mode of the special color calculation function for each scroll screen. This is a 16-bit write-only register located at address 1800EEH. The value is cleared to 0 after power-on or reset, so be sure to set it.

SFCCMD 1800EEH
   15   
   14   
   13   
   12   
   11   
   10   
   09   
   08   
 -
 -
 -
 -
 -
 -
 R0SCCM1
 R0SCCM0

   07   
   06   
   05   
   04   
   03   
   02   
   01   
   00   
 N3SCCM1
 N3SCCM0
 N2SCCM1
 N2SCCM0
 N1SCCM1
 N1SCCM0
 N0SCCM1
 N0SCCM0

Special color calculation mode bit
(N0SCCM1, N0SCCM0, N1SCCM1, N1SCCM0, N2SCCM1, N2SCCM0, N3SCCM1, N3SCCM0, R0SCCM1, R0SCCM0)
Specifies the mode of special color calculation function for each scroll screen.

N0SCCM1,N0SCCM0 1800EEH bit 1,0 For NBG0 (or for RBG1)
N1SCCM1,N1SCCM0 1800EEH bit 3,2 For NBG1 (or for EXBG)
N2SCCM1,N2SCCM0 1800EEH bit 5,4 For NBG2
N3SCCM1,N3SCCM0 1800EEH bit 7,6 For NBG3
R0SCCM1,R0SCCM0 1800EEH bit 9,8 For RBG0

xxSCCM1 xxSCCM0 mode process
 0
 0
 0
Color calculation enable is specified for each screen.
 0
 1
 1
Color calculation enable is specified for each character.
 1
 0
 2
Color calculation enable is specified for each dot.
 1
 1
 3
Color calculation enable is specified by the most significant bit of color data.
determine
[Note] xx in the bit name is N0, N1, N2, N3, or R0.

Specifying the special color calculation mode is valid only when each screen is the top image. For images other than the top image, the mode is fixed to 0.
If the color format of the scroll screen is RGB format, do not use mode 2. Also, if mode 3 is specified, color calculations are performed on all dots.
Do not specify mode 1 or mode 2 in EXBG.


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