Texas Instruments TMS320C64X Security Camera User Manual


 
DSP_fft16x16t
4-115 C64x+ DSPLIB Reference
}
else
{
y1 = y0 + (int) (npoints >> 1);
y3 = y2 + (int) (npoints >> 1);
l1 = norm + 2;
j0 = 4;
n0 = npoints >> 2;
}
/*−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−*/
/* The following code reads data indentically for either a radix 4 */
/* or a radix 2 style decomposition. It writes out at different */
/* locations though. It checks if either half the points, or a */
/* quarter of the complex points have been exhausted to jump to */
/* pervent double reversal. */
/*−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−*/
j = 0;
for (i = 0; i < npoints; i += 8)
{
/*−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−*/
/* Digit reverse the index starting from 0. The increment to ”j” */
/* is either by 4, or 8. */
/*−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−*/
DIG_REV(j, l1, h2);
/*−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−*/
/* Read in the input data, from the first eight locations. These */
/* are transformed either as a radix4 or as a radix 2. */
/*−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−−*/
x_0 = x0[0]; x_1 = x0[1];
x_2 = x0[2]; x_3 = x0[3];
x_4 = x0[4]; x_5 = x0[5];
x_6 = x0[6]; x_7 = x0[7];
x0 += 8;
xh0_0 = x_0 + x_4; xh1_0 = x_1 + x_5;
xl0_0 = x_0 − x_4; xl1_0 = x_1 − x_5;
xh0_1 = x_2 + x_6; xh1_1 = x_3 + x_7;