
Intel® 815 Chipset: Graphics Controller PRM, Rev 1.0
R
The following gives a more detailed description of the algorithm. A line with two coordinate points as (x1, y1) and (x2, y2) can be defined by the following equation:
y2 = slope (x2 - x1) + y1
This implies slope of the line is:
slope = (y2 - y1) / x2
Another point with X = x3 on the same line can be defined as (x3, y3) where y3 is
y3 = slope (x3 - x1) + y1
Derived Slope =
Interpolated Point
Value Of Latch
@ Adrs [N+1] |
Adrs[N+1] - Adrs[N]
Value Of Latch
@ Adrs [N]
Value Of LSB's
Ideal Curve |
Result = Value Of Latch @ Adrs[N] + Slope * LSB's
Gamma correction can be bypassed by programming the registers with data values corresponding to a linear curve with slope = 1. The register programming for gamma bypassing is as shown below.
Adrs[8] = 8 | Adrs[64] = 64 |
Adrs[16] = 16 | Adrs[128] = 128 |
Adrs[32] = 32 | Adrs[192] = 192 |
When registers are programmed with the above values, output of the gamma unit is the same as the input, and no gamma correction occurs.
Gamma Hardware Implementation
Result = Adrs[192] + | [[0x00 | - Adrs[192]] * [X - 192] << 1] >> 7 | 192 <= X < 256 | ||||
Result = Adrs[128] + | [[Adrs[192] - Adrs[128]] * [X - 128] << 1] >> 7 | 128 <= X < 192 | |||||
Result = Adrs[64 ] + | [[Adrs[128] - Adrs[ 64 ]] * [[X - 64] << 1]] >> 7 | 64 <= X < 128 | |||||
Result = Adrs[32 | ] + [[Adrs[64 | ] - Adrs[ 32 ]] * [[X - 32] << 2]] >> 7 | 32 | <= X < | 64 | ||
Result = Adrs[16 | ] + [[Adrs[32 | ] - Adrs[ 16 ]] * [[X - 16] << 3]] >> 7 | 16 | <= X < | 32 | ||
Result = Adrs[ 8 | ] + [[Adrs[16 | ] - Adrs[ 8 ]] * [[X - 8] << 4]] >> 7 | 8 | <= X < | 16 | ||
Result = 0x00 | + [[Adrs[8 | ] - 0x00 ]] * [[X - 0 ] << 4]] >> 7 | 0 | <= X < | 8 | ||
Consider Adrs[8] = 8, Adrs[16] = 16, Adrs[32] = 32, Adrs[64] = 64, Adrs[128] = 128, Adrs[192] = 192. | |||||||
For X = 5, Result = 0 + | == 5 |
|
|
| |||
For X = 11, Result = 8 + | == 11 |
|
|
| |||
For X = 24, Result = 16 + | == 24 |
|
|
| |||
For X = 63, Result = 31 + | == 63 |
|
|
| |||
For X = 100, Result = 64 + | == 100 |
|
|
| |||
For X = 156, Result = 128 + | == 156 |
|
|
| |||
For X = 200, Result = 192 + | == 200 |
|
|
| |||
273