X-Git-Url: http://git.kpe.io/?a=blobdiff_plain;f=src%2Fviews.cpp;h=b068214dd3eb6c27d49d38a8f1396f82879db6eb;hb=6925a2064ddce2bdc9e409fc4887a83b4a6226f5;hp=cd16c7c1d7f2588dc20732769c98571814e1872b;hpb=dc034c9d0b7d9c3874a324a4c2c189a02945adc8;p=ctsim.git diff --git a/src/views.cpp b/src/views.cpp index cd16c7c..b068214 100644 --- a/src/views.cpp +++ b/src/views.cpp @@ -9,7 +9,7 @@ ** This is part of the CTSim program ** Copyright (C) 1983-2000 Kevin Rosenberg ** -** $Id: views.cpp,v 1.25 2000/12/16 06:12:47 kevin Exp $ +** $Id: views.cpp,v 1.27 2000/12/17 22:30:34 kevin Exp $ ** ** This program is free software; you can redistribute it and/or modify ** it under the terms of the GNU General Public License (version 2) as @@ -50,10 +50,16 @@ #include "dialogs.h" #include "dlgprojections.h" #include "dlgreconstruct.h" -#include #include "backprojectors.h" #include "reconstruct.h" #include "timer.h" + +#if defined(MSVC) || HAVE_SSTREAM +#include +#else +#include +#endif + // ImageFileCanvas @@ -133,7 +139,7 @@ ImageFileView::OnProperties (wxCommandEvent& event) const std::string& rFilename = rIF.getFilename(); rIF.statistics (min, max, mean, mode, median, stddev); std::ostringstream os; - os << "file: " << rFilename << "\nmin: "<getLog() << os.str().c_str(); wxMessageDialog dialogMsg (m_frame, os.str().c_str(), "Imagefile Properties", wxOK | wxICON_INFORMATION); dialogMsg.ShowModal(); @@ -459,9 +465,9 @@ PhantomView::OnProjections (wxCommandEvent& event) } std::ostringstream os; - os << "Projections for " << rPhantom.name() << ": nDet=" << m_iDefaultNDet << ", nView=" << m_iDefaultNView << ", nSamples=" << m_iDefaultNSample << ", RotAngle=" << m_dDefaultRotation << ", FocalLengthRatio=" << m_dDefaultFocalLength << ", FieldOfViewRatio=" << m_dDefaultFieldOfView << ", Geometry=" << sGeometry.c_str() << "\n"; + os << "Projections for " << rPhantom.name() << ": nDet=" << m_iDefaultNDet << ", nView=" << m_iDefaultNView << ", nSamples=" << m_iDefaultNSample << ", RotAngle=" << m_dDefaultRotation << ", FocalLengthRatio=" << m_dDefaultFocalLength << ", FieldOfViewRatio=" << m_dDefaultFieldOfView << ", Geometry=" << sGeometry.c_str(); rProj.setRemark (os.str()); - *theApp->getLog() << os.str().c_str(); + *theApp->getLog() << os.str().c_str() << "\n"; m_frame->Lower(); ::wxYield(); @@ -785,8 +791,8 @@ ProjectionFileView::OnReconstruct (wxCommandEvent& event) pReconDoc->Modify(true); pReconDoc->UpdateAllViews(this); std::ostringstream os; - os << "Reconstruct " << rProj.getFilename() << ": xSize=" << m_iDefaultNX << ", ySize=" << m_iDefaultNY << ", Filter=" << optFilterName.c_str() << ", FilterParam=" << m_dDefaultFilterParam << ", FilterMethod=" << optFilterMethodName.c_str() << ", FilterGeneration=" << optFilterGenerationName.c_str() << ", Zeropad=" << m_iDefaultZeropad << ", Interpolation=" << optInterpName.c_str() << ", InterpolationParam=" << m_iDefaultInterpParam << ", Backprojection=" << optBackprojectName.c_str() << "\n"; - *theApp->getLog() << os.str().c_str(); + os << "Reconstruct " << rProj.getFilename() << ": xSize=" << m_iDefaultNX << ", ySize=" << m_iDefaultNY << ", Filter=" << optFilterName.c_str() << ", FilterParam=" << m_dDefaultFilterParam << ", FilterMethod=" << optFilterMethodName.c_str() << ", FilterGeneration=" << optFilterGenerationName.c_str() << ", Zeropad=" << m_iDefaultZeropad << ", Interpolation=" << optInterpName.c_str() << ", InterpolationParam=" << m_iDefaultInterpParam << ", Backprojection=" << optBackprojectName.c_str(); + *theApp->getLog() << os.str().c_str() << "\n"; imageFile.labelAdd (rProj.getLabel()); imageFile.labelAdd (Array2dFileLabel::L_HISTORY, os.str().c_str(), timerRecon.timerEnd()); }