-#if 1
- wxFrame frame (m_frame, -1, "", wxDefaultPosition, wxSize(500,500));
- frame.Show();
- wxClientDC dc (&frame);
- int x, y;
- frame.GetClientSize(&x, &y);
- SGPDriver driver (dynamic_cast<wxDC*>(&dc), x, y);
- SGP sgp (driver);
- for (int iView = 0; iView < rProj.nView(); iView++) {
- theScanner.collectProjections (rProj, rPhantom, iView, 1, true, TRACE_RAYS, &sgp);
- }
-#else
- theScanner.collectProjections (rProj, rPhantom);
-#endif
+ if (iTrace > Trace::TRACE_CONSOLE) {
+ ProjectionsDialog dialogProjections (theScanner, rProj, rPhantom, iTrace, dynamic_cast<wxWindow*>(m_frame));
+ for (int iView = 0; iView < rProj.nView(); iView++) {
+ if (! dialogProjections.projectView (iView)) {
+ pProjectionDoc->DeleteAllViews();
+ return;
+ }
+ ::wxYield();
+ }
+ } else
+ theScanner.collectProjections (rProj, rPhantom);