Interpolation of surface - Polygon Rendering
Interpolation of surface normals beside the polygonedge between two vertices is demonstrated above in the figure 15. Here the normal vector N for the scan line intersection point beside the edge between vertices 1 and 2 can be acquired by vertically interpolating among edge end points normals. After that incremental methods are utilized to evaluate normals among scan lines and along each particular scan line. At each pixel position beside a scan line, the illumination model is implemented to find out the surface intensity at such point
N= [((y-y_{2}) / (y_{1}-y_{2})) N_{1}] + [((y-y_{2}) / (y_{1}-y_{2})) N_{2}]
In the figure 15 that already given above, as N¯ is surface normal to be interpolated beside polygon edge 1- 2 having vertices 1 and 2. N¯_{1} and N¯_{2} both are normal at the vertices. Therefore, through using the parametric equation across the edge 1 - 2 we can find out the value of the normal N¯ that will be specified by:
N = N¯_{1} + t (N¯_{2}- N¯_{1})
As the same in the figure 16 we can get N¯_{p} and N¯_{q} such are the normal at point as P and Q through that the scan line passes,
N¯_{p }= N¯_{A} +t (N¯_{B} - N¯_{A}); here t = |AP|/|AB|
At present we utilize N¯_{P} to determine cos θ; here, θ is the angle among Normal vector and direction of light represented through vector L i.e. here refer to Phong model.
cos θ = N¯. L¯
And cos^{n} α =( R¯ . V¯)^{n}
= [( 2 N¯ (N¯. L¯) - L¯) . V]^{n}
Now by using here cos^{n} α, cos θ in
I = I_{a }K_{a} + I_{d} K_{d} cos θ + I_{s} K_{s} cos^{n} α
/* similarly we can determine intensity of points lying within the surface */
This Np will be utilized to find intensity value that is, I_{P}. at points P_{o} in the object that projection is P, by utilizing the intensity computation formula that we had utilized for the determination of intensities in diffused and specular reflection.