2 **********************************************************************
3 $SNARK_Header: S N A R K 1 4 - A PICTURE RECONSTRUCTION PROGRAM $
4 $HeadURL: svn://dig.cs.gc.cuny.edu/snark/trunk/src/snark/disply.cpp $
5 $LastChangedRevision: 79 $
6 $Date: 2014-07-01 15:33:39 -0400 (Tue, 01 Jul 2014) $
8 **********************************************************************
26 // was in post but it is realy local
31 // was in geo but it is realy local
35 INTEGER word, flags[51];
36 unsigned int count, iter;
45 static const INTEGER hphan = CHAR2INT('p', 'h', 'a', 'n');
46 static const INTEGER hscal = CHAR2INT('s', 'c', 'a', 'l');
48 // modified calls to getwrd() to use the 4-parameter version. Lajos, Dec 13, 2004
49 static const INTEGER disply_codes[2] =
50 { CHAR2INT('p', 'h', 'a', 'n'), CHAR2INT('s', 'c', 'a', 'l') };
54 word = InFile.getwrd(FALSE, &eol, disply_codes, 2);
65 scale = InFile.getnum(FALSE, &eol);
71 if (RecFile.Open("recfil") != 0)
73 fprintf(output, "\n **** unable to open recfil");
74 fprintf(output, "\n **** DISPLAY execution aborted\n");
78 if (RecFile.GetNelem(&nelem) != 0)
83 if (RecFile.GetProjName(prjnam) != 0)
89 //GeoPar.midpix = (GeoPar.nelem + 1) / 2;
93 Recon = new REAL[area];
95 // if phantom selected
98 if (RecFile.ReadPhan(phnnam, Recon) != 0)
100 fprintf(output, "\n **** phantom not present\n");
104 fprintf(output, "\n display of phantom\n");
106 fprintf(output, "\n phantom name: %s", phnnam);
108 disp(Recon, nelem, nelem, scale, output);
112 while (RecFile.ReadRec(recnam, algn, &count, &iter, Recon) == 0)
116 if (flags[iter - 1] != 0)
119 fprintf(output, "\n\n reconstruction using %s iter %4i\n", algn,
122 fprintf(output, "\n projection data: %s", prjnam);
126 fprintf(output, "\n execution name: %s", recnam);
129 disp(Recon, nelem, nelem, scale, output);
133 delete[] Recon; // bug 92 - Lajos - 03/02/2005
135 fprintf(output, "\n"); // end of file reached