Content deleted Content added
Added tone template |
m →Programmable pipeline approach: Fixed typo Tags: canned edit summary Mobile edit Mobile app edit Android app edit App section source |
||
(2 intermediate revisions by 2 users not shown) | |||
Line 6:
== Fixed function pipeline approach ==
Historically{{ref|nvsdk_ptm}}, using projective texture mapping involved considering a special form of eye linear texture coordinate generation{{ref|glEyeLinear}} transform (''tcGen'' for short). This transform was then multiplied by another matrix representing the projector's properties which
The key points of this approach are that eye linear tcGen is a function of vertex eye coordinates, which is a result of both eye properties and object space vertex coordinates (more specifically, the object space vertex position is transformed by the model-view-projection matrix).
Because of that, the corresponding texture matrix can be used to "shift" the eye properties so the
== Programmable pipeline approach ==
Line 16:
The previous algorithm can then be reformulated by simply considering two model-view-projection matrices: one from the eye point of view and the other from the projector point of view.
In this case, the projector model-view-projection matrix is essentially the aforementioned
By using those two matrices, a few instructions are sufficient to output the transformed eye space vertex position and a projective texture coordinate. This coordinate is simply obtained by considering the projector's model-view-projection matrix: in other words, this is the eye-space vertex position if the considered projector would have been an observer.
|