- /**
- This method projects each pixel of a volume (stack of slices) onto a plane as the volume rotates about the x-axis. Integer
- arithmetic, precomputation of values, and iterative addition rather than multiplication inside a loop are used extensively
- to make the code run efficiently. Projection parameters stored in global variables determine how the projection will be performed.
- This procedure returns various buffers which are actually used by DoProjections() to find the final projected image for the volume
- of slices at the current angle.
- */
- private void doOneProjectionX (int nSlices, int ycenter, int zcenter, int projwidth, int projheight, int costheta, int sintheta) {
- int thispixel; //current pixel to be projected
- int offset, offsetinit; //precomputed offsets into an image buffer
- int z; //z-coordinate of points in current slice before rotation
- int ynew, znew; //y- and z-coordinates of current point after rotation
- int zmax, zmin; //z-coordinates of first and last slices before rotation
- int zmaxminuszmintimes100; //precomputed values to save time in loops
- int c100minusDepthCueInt, c100minusDepthCueSurf;
- boolean DepthCueIntLessThan100, DepthCueSurfLessThan100;
- boolean OpacityOrNearestPt, OpacityAndNotNearestPt;
- boolean MeanVal, BrightestPt;
- int ysintheta, ycostheta;
- int zsintheta, zcostheta, ysinthetainit, ycosthetainit;

This file has been truncated. show original