Rapid computation of local eye vectors in a fixed point lighting unit
First Claim
1. A method for calculating a local eye vector in a graphics sub-system, wherein said local eye vector corresponds to a given eye position and a first vertex of a first geometric primitive, said method comprising:
- receiving a first set of coordinates corresponding to said first vertex, wherein said first set of coordinates are represented in a first coordinate space;
generating a reverse transform matrix corresponding to said given eye position, wherein said given eye position is represented by a second set of coordinates located in a second coordinate space;
transforming said first set of coordinates using said reverse transform matrix, wherein said transforming generates a preliminary local eye vector;
wherein said preliminary local eye vector is usable to perform lighting computations upon said first vertex.
0 Assignments
0 Petitions
Accused Products
Abstract
A rapid method for calculating a local eye vector in a fixed point lighting unit. For a given triangle primitive which is to be projected into a given viewport in screen space coordinates, the local eye vector corresponds to a given eye position and a first vertex of the given triangle primitive. (A different local eye vector is calculated for each vertex of the given triangle primitive). The method first comprises generating a view vector matrix which corresponds to the given eye position and corner coordinates of the given viewport, where the corner coordinates are expressed in screen space coordinates. The view vector matrix is usable to map screen space coordinates to an eye vector space which corresponds to the given viewport. The method next includes receiving a first set of coordinates (in screen space) which correspond to the first vertex. The first set of coordinates are then scaled to a numeric range which is representable by the fixed point lighting unit. Next, the first set of coordinates are transformed using the view vector matrix, which produces a non-normalized local eye vector within the eye vector space for the given viewport. The non-normalized local eye vector is normalized to form a normalized local eye vector. The normalized local eye vector is then usable to perform subsequent lighting computations such as computation of specular reflection values for infinite light sources, producing more realistic lighting effects than if an infinite eye vector were used. These more realistic lighting effects do not come at decreased performance, however, as the local eye vector may be calculated rapidly using this method.
33 Citations
26 Claims
-
1. A method for calculating a local eye vector in a graphics sub-system, wherein said local eye vector corresponds to a given eye position and a first vertex of a first geometric primitive, said method comprising:
-
receiving a first set of coordinates corresponding to said first vertex, wherein said first set of coordinates are represented in a first coordinate space; generating a reverse transform matrix corresponding to said given eye position, wherein said given eye position is represented by a second set of coordinates located in a second coordinate space; transforming said first set of coordinates using said reverse transform matrix, wherein said transforming generates a preliminary local eye vector; wherein said preliminary local eye vector is usable to perform lighting computations upon said first vertex. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11)
-
-
12. A graphics sub-system for calculating a local eye vector, wherein said local eye vector corresponds to a given eye position and a given position value, said graphics sub-system comprising:
-
a coordinate conversion unit coupled to receive a first set of coordinates corresponding to said given position value, wherein said coordinate conversion unit is configured to generate a second set of coordinates from said first set of coordinates, wherein said first set of coordinates are located in a first coordinate space, and wherein said second set of coordinates are located in a second coordinate space; a lighting unit coupled to receive said second set of coordinates and a reverse transform matrix corresponding to said given eye position, wherein said lighting unit is configured to generate a preliminary local eye vector by transforming said second set of coordinates using said reverse transform matrix, wherein said lighting unit is configured to utilize said preliminary local eye vector in performing lighting computations on said given position value. - View Dependent Claims (13, 14, 15, 16, 17, 18, 19, 20)
-
-
21. A computer system for calculating a local eye vector, wherein said local eye vector corresponds to a given eye position and a given position value, said computer system comprising:
-
a host CPU configured to generate a reverse transform matrix corresponding to said given eye position, wherein said given eye position is represented by coordinates located in a first coordinate space; a graphics sub-system coupled to said host CPU, said graphics sub-system comprising; a coordinate conversion unit coupled to receive a first set of coordinates corresponding to said given position value, wherein said coordinate conversion unit is configured to generate a second set of coordinates from said first set of coordinates, wherein said first set of coordinates are located in said first coordinate space, and wherein said second set of coordinates are located in a second coordinate space; a lighting unit coupled to receive said second set of coordinates and said reverse transform matrix, wherein said lighting unit is configured to generate a preliminary local eye vector by transforming said second set of coordinates using said reverse transform matrix, wherein said lighting unit is configured to utilize said preliminary local eye vector in performing lighting computations on said given position value. - View Dependent Claims (22, 23, 24, 25)
-
-
26. A system for calculating a local eye vector, wherein said local eye vector corresponds to a given eye position and a first vertex of a first geometric primitive, said system comprising:
-
receiving means for receiving a first set of coordinates corresponding to said first vertex, wherein said first set of coordinates are represented in a first coordinate space; generating means for generating a reverse transform matrix corresponding to said given eye position, wherein said given eye position is represented by a second set of coordinates located in a second coordinate space; transforming means for transforming said first set of coordinates using said reverse transform matrix, wherein said transforming generates a preliminary local eye vector; wherein said preliminary local eye vector is usable to perform lighting computations upon said first vertex.
-
Specification