Graphics Programming
TVP4020
Programmers Reference Manual
108
5.11.5
Flat Shading Example
A flat shaded primitive:
// Set DDA to flat shade mode
colorDDAMode.UnitEnable = PERMEDIA_ENABLE
colorDDAMode.Shade = PERMEDIA_FLAT_SHADE_MODE
ColorDDAMode(colorDDAMode)
ConstantColor(0xFFFFFFFF)
// Load the flat color
5.11.6
Gouraud Shaded Trapezoid Example
See Appendix D for details of how to calculate delta values.
// Enable unit in Gouraud shading mode
colorDDAMode.UnitEnable = PERMEDIA_ENABLE
colorDDAMode.Shade = PERMEDIA_GOURAUD_SHADE_MODE
ColorDDAMode(colorDDAMode)
// Load the color start values and deltas for dominant edge
// and the body of the trapezoid
RStart()
// Set-up the red component start value
dRdx()
// Set-up the red component increments
dRdyDom()
GStart()
// Set-up the green component start value
dGdx()
// Set-up the green component increments
dGdyDom()
BStart()
// Set-up the blue component start value
dBdx ()
// Set-up the blue component increments
dBdyDom ()
5.11.7
Gouraud Shaded Line Example
Содержание TVP4020 PERMEDIA 2
Страница 1: ...Texas Instruments TVP4020 PERMEDIA 2 Programmer s Reference Manual Issue 4 ...
Страница 47: ...Memory I O and Organization TVP4020 Programmers Reference Manual 38 Texture address TextureBaseAddress T W S ...
Страница 284: ...TVP4020 Programmers Reference Manual A Gouraud Shaded Triangle 275 ...
Страница 292: ...TVP4020 Programmers Reference Manual Register Tables 283 ...
Страница 314: ...TVP4020 Programmers Reference Manual Index 305 ...
Страница 315: ...Index TVP4020 Programmers Reference Manual 306 Index ...
Страница 323: ...Index TVP4020 Programmers Reference Manual 314 ...