Nintendo 1504166 Programming Manual - Page 51

BG2X_H, BG2Y_L, and, The BG data reference direction is set in BG2PA, BG2PB

Page 51 highlights

AGB Programming Manual Rendering Functions Operations Used in BG Rotation/Scaling Processing 1. Using software, the user determines the results of the rotation/scaling operation for the left-upper coordinate of the display screen and sets this as the starting point of the BG data reference in registers BG2X_L, BG2X_H, BG2Y_L, BG2Y_H, BG3X_L, BG3X_H, BG3Y_L, and BG3Y_H. The set value is a signed fixed-point number (8 bits for fractional portion, 19 bits for integer portion, and 1 bit for sign, for a total of 28 bits). The BG data reference direction is set in BG2PA, BG2PB, BG2PC, BG2PD, BG3PA, BG3PB, BG3PC, and BG3PD. The set value is a signed fixed-point number (8 bits for fractional portion, 7 bits for integer portion, and 1 bit for sign, for a total of 16 bits). 2. The image processing circuit sums the increases in the x direction (dx, dy) in relation to the BG data reference starting point set in the above registers, and calculates the x-coordinate. 3. When the line is advanced, the increases in the y direction (dmx, dmy) are summed in relation to the reference starting point, and the coordinate of the rendering starting point for the next line is calculated. The processing in step 2) is then performed. 4. However, if a register for the BG data reference starting point is rewritten during an H-blanking interval, the y-direction summation for that register is not calculated. The CPU uses this mode to change the center coordinate and the rotation/scaling parameters for each line. Area Overflow Processing When the display screen overflows the boundaries of the virtual screen due to a rotation/scaling operation, this BG control register can be used to select whether the area of the screen into which the overflow occurs is transparent or wraps around the display screen. For information on BG control, see "6.1.1 BG Control". ©1999 - 2001 Nintendo of America Inc. 51 D.C.N. AGB-06-0001-002B4

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • 10
  • 11
  • 12
  • 13
  • 14
  • 15
  • 16
  • 17
  • 18
  • 19
  • 20
  • 21
  • 22
  • 23
  • 24
  • 25
  • 26
  • 27
  • 28
  • 29
  • 30
  • 31
  • 32
  • 33
  • 34
  • 35
  • 36
  • 37
  • 38
  • 39
  • 40
  • 41
  • 42
  • 43
  • 44
  • 45
  • 46
  • 47
  • 48
  • 49
  • 50
  • 51
  • 52
  • 53
  • 54
  • 55
  • 56
  • 57
  • 58
  • 59
  • 60
  • 61
  • 62
  • 63
  • 64
  • 65
  • 66
  • 67
  • 68
  • 69
  • 70
  • 71
  • 72
  • 73
  • 74
  • 75
  • 76
  • 77
  • 78
  • 79
  • 80
  • 81
  • 82
  • 83
  • 84
  • 85
  • 86
  • 87
  • 88
  • 89
  • 90
  • 91
  • 92
  • 93
  • 94
  • 95
  • 96
  • 97
  • 98
  • 99
  • 100
  • 101
  • 102
  • 103
  • 104
  • 105
  • 106
  • 107
  • 108
  • 109
  • 110
  • 111
  • 112
  • 113
  • 114
  • 115
  • 116
  • 117
  • 118
  • 119
  • 120
  • 121
  • 122
  • 123
  • 124
  • 125
  • 126
  • 127
  • 128
  • 129
  • 130
  • 131
  • 132
  • 133
  • 134
  • 135
  • 136
  • 137
  • 138
  • 139
  • 140
  • 141
  • 142
  • 143
  • 144
  • 145
  • 146
  • 147
  • 148
  • 149
  • 150
  • 151
  • 152
  • 153
  • 154
  • 155
  • 156
  • 157
  • 158
  • 159
  • 160
  • 161
  • 162
  • 163
  • 164
  • 165
  • 166
  • 167
  • 168
  • 169
  • 170
  • 171

AGB Programming Manual
Rendering Functions
©1999 - 2001 Nintendo of America Inc.
51
D.C.N. AGB-06-0001-002B4
Operations Used in BG Rotation/Scaling Processing
1.
Using software, the user determines the results of the rotation/scaling
operation for the left-upper coordinate of the display screen and sets
this as the starting point of the BG data reference in registers BG2X_L,
BG2X_H, BG2Y_L, BG2Y_H, BG3X_L, BG3X_H, BG3Y_L, and
BG3Y_H.
The set value is a signed fixed-point number (8 bits for
fractional portion, 19 bits for integer portion, and 1 bit for sign, for a total
of 28 bits).
The BG data reference direction is set in BG2PA, BG2PB, BG2PC,
BG2PD, BG3PA, BG3PB, BG3PC, and BG3PD.
The set value is a
signed fixed-point number (8 bits for fractional portion, 7 bits for integer
portion, and 1 bit for sign, for a total of 16 bits).
2.
The image processing circuit sums the increases in the x direction (dx,
dy) in relation to the BG data reference starting point set in the above
registers, and calculates the x-coordinate.
3.
When the line is advanced, the increases in the y direction (dmx, dmy)
are summed in relation to the reference starting point, and the
coordinate of the rendering starting point for the next line is calculated.
The processing in step 2) is then performed.
4.
However, if a register for the BG data reference starting point is
rewritten during an H-blanking interval, the y-direction summation for
that register is not calculated.
The CPU uses this mode to change the
center coordinate and the rotation/scaling parameters for each line.
Area Overflow Processing
When the display screen overflows the boundaries of the virtual screen
due to a rotation/scaling operation, this BG control register can be used to
select whether the area of the screen into which the overflow occurs is
transparent or wraps around the display screen.
For information on BG control, see “6.1.1 BG Control”.