<b>(a)</b> N2 = (N/2) + 1 center point of a map edge NN = 0.5 - N2 adjust to center of a given pixel FOR I = 1 TO N t = I + NN center-point pixel coordinate CC[I] = t * C precompute Cosine table SS[I] = t * S precompute Sine table <b>(b)</b> Xrot = CC[X] + SS[Y] Yrot = CC[Y] - SS[X]
Figure 3: (a) Precomputation code; (b) rotation equations.
Copyright © 1999, Dr. Dobb's Journal