** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: ezplot.cpp,v 1.18 2000/12/18 05:40:30 kevin Exp $
+** $Id: ezplot.cpp,v 1.19 2000/12/18 06:32:13 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
if (o_ytlabel == TRUE && axis_near == FALSE) {
snprintf (str, sizeof(str), y_numfmt, ygw_min + yw_tickinc * i);
rSGP.moveAbs (yaxispos + ytl_ofs, y + 0.5 * charheight);
- rSGP.setTextColor (clr_number, -1);
+ rSGP.setTextColor (clr_number, -1);\r
+ rSGP.setTextAngle(HALFPI);
rSGP.drawText (str);
+ rSGP.setTextAngle(0.);\r
}
}
} // Y - Axis
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: sgp.cpp,v 1.20 2000/12/18 05:40:30 kevin Exp $
+** $Id: sgp.cpp,v 1.21 2000/12/18 06:32:13 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
g2_clear (m_driver.idG2());
#endif
#if HAVE_WXWINDOWS
- if (m_driver.isWX()) {
- wxBrush brushWhite;\r
+ if (m_driver.isWX()) {\r
+ wxBrush brushWhite;\r
brushWhite.SetColour(255,255,255);\r
m_driver.idWX()->SetBackground(brushWhite);\r
m_driver.idWX()->Clear();\r
m_driver.idWX()->SetBackground(wxNullBrush);\r
+#if 1\r
+ wxPen pen;\r
+ pen.SetColour(255,255,255);\r
+ m_driver.idWX()->SetBrush (brushWhite);\r
+ m_driver.idWX()->DrawRectangle (0, 0, m_iPhysicalXSize, m_iPhysicalYSize);\r
+ m_driver.idWX()->SetBrush (wxNullBrush);\r
+#endif\r
}
#endif
}
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: scanner.cpp,v 1.21 2000/12/18 02:23:43 kevin Exp $
+** $Id: scanner.cpp,v 1.22 2000/12/18 06:32:13 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
#ifdef HAVE_SGP
if (pSGP && m_trace >= Trace::TRACE_PHANTOM) {
m_pSGP = pSGP;
- m_pSGP->eraseWindow();
double dWindowSize = dmax (m_detLen, m_dFocalLength * 2) * SQRT2;
double dHalfWindowSize = dWindowSize / 2;
m_dXMinWin = m_dXCenter - dHalfWindowSize;
m_dYMaxWin = m_dYCenter + dHalfWindowSize;
double dHalfPhmLen = m_phmLen / 2;
- m_pSGP->eraseWindow ();
m_pSGP->setWindow (m_dXMinWin, m_dYMinWin, m_dXMaxWin, m_dYMaxWin);
m_pSGP->setRasterOp (RO_COPY);
m_pSGP->setColor (C_RED);
-<html>\r
-<body>\r
-<pre>\r
-<h1>Build Log</h1>\r
-<h3>\r
---------------------Configuration: ctsim - Win32 Debug--------------------\r
-</h3>\r
-<h3>Command Lines</h3>\r
-Creating temporary file "C:\DOCUME~1\kevin\LOCALS~1\Temp\RSP20.tmp" with contents\r
-[\r
-/nologo /G6 /MTd /W3 /Gm /GR /GX /ZI /Od /I "\wx2\include" /I "." /I "..\..\include" /I "..\..\getopt" /I "..\..\..\lpng108" /I "..\..\..\zlib" /I "..\..\..\fftw-2.1.3\fftw" /I "..\..\..\fftw-2.1.3\rfftw" /D VERSION=\"2.1.0\" /D "_DEBUG" /D "__WXMSW__" /D "HAVE_SGP" /D VERSION="2.1.0" /D "HAVE_PNG" /D "HAVE_WXWINDOWS" /D "WIN32" /D "_WINDOWS" /D "_MBCS" /D "HAVE_STRING_H" /D "HAVE_FFTW" /D "HAVE_RFFTW" /D "HAVE_GETOPT_H" /D "MSVC" /D "__WIN95__" /D "__WIN32__" /D WINVER=0x0400 /D "STRICT" /FR"Debug/" /Fp"Debug/ctsim.pch" /YX /Fo"Debug/" /Fd"Debug/" /FD /GZ /c \r
-"C:\ctsim-2.0.6\src\dlgreconstruct.cpp"\r
-]\r
-Creating command line "cl.exe @C:\DOCUME~1\kevin\LOCALS~1\Temp\RSP20.tmp" \r
-Creating temporary file "C:\DOCUME~1\kevin\LOCALS~1\Temp\RSP21.tmp" with contents\r
-[\r
-comctl32.lib winmm.lib rpcrt4.lib ws2_32.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ../libctsim/Debug/libctsim.lib kernel32.lib user32.lib gdi32.lib winspool.lib comdlg32.lib advapi32.lib shell32.lib ole32.lib oleaut32.lib uuid.lib odbc32.lib odbccp32.lib ..\..\..\lpng108\msvc\win32\libpng\lib_dbg\libpng.lib ..\..\..\lpng108\msvc\win32\zlib\lib_dbg\zlib.lib libcmtd.lib ..\..\..\fftw-2.1.3\Win32\FFTW2st\Debug\FFTW2st.lib ..\..\..\fftw-2.1.3\Win32\RFFTW2st\Debug\RFFTW2st.lib ../../../wx2/lib/wxd.lib /nologo /subsystem:windows /incremental:yes /pdb:"Debug/ctsim.pdb" /debug /machine:I386 /nodefaultlib:"libcd.lib" /nodefaultlib:"libcid.lib" /nodefaultlib:"msvcrtd.lib" /out:"Debug/ctsim.exe" /pdbtype:sept /libpath:"..\..\..\lpng108\msvc\win32\libpng\lib" /libpath:"..\..\..\lpng108\msvc\win32\zlib\lib" \r
-".\Debug\ctsim.obj"\r
-".\Debug\dialogs.obj"\r
-".\Debug\dlgprojections.obj"\r
-".\Debug\dlgreconstruct.obj"\r
-".\Debug\docs.obj"\r
-".\Debug\views.obj"\r
-".\Debug\wx.res"\r
-"\ctsim-2.0.6\msvc\libctsim\Debug\libctsim.lib"\r
-"\fftw-2.1.3\Win32\FFTW2st\Debug\FFTW2st.lib"\r
-"\fftw-2.1.3\Win32\RFFTW2st\Debug\RFFTW2st.lib"\r
-"\wx2\lib\wxd.lib"\r
-]\r
-Creating command line "link.exe @C:\DOCUME~1\kevin\LOCALS~1\Temp\RSP21.tmp"\r
-<h3>Output Window</h3>\r
-Compiling...\r
-dlgreconstruct.cpp\r
-C:\ctsim-2.0.6\src\dlgreconstruct.cpp(147) : error C2039: 'setDC' : is not a member of 'wxDC'\r
- c:\wx2\include\wx\msw\dc.h(74) : see declaration of 'wxDC'\r
-Error executing cl.exe.\r
-Creating command line "bscmake.exe /nologo /o"Debug/ctsim.bsc" ".\Debug\ctsim.sbr" ".\Debug\dialogs.sbr" ".\Debug\dlgprojections.sbr" ".\Debug\dlgreconstruct.sbr" ".\Debug\docs.sbr" ".\Debug\views.sbr""\r
-Creating browse info file...\r
-<h3>Output Window</h3>\r
-\r
-\r
-\r
-<h3>Results</h3>\r
-ctsim.exe - 1 error(s), 0 warning(s)\r
-</pre>\r
-</body>\r
-</html>\r
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: dlgprojections.cpp,v 1.10 2000/12/18 05:40:30 kevin Exp $
+** $Id: dlgprojections.cpp,v 1.11 2000/12/18 06:32:13 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
ProjectionsDialog::OnPause (wxCommandEvent& event)
{
if ( m_state == Finished ) {
- // this means that the count down is already finished and we're being
- // shown as a modal dialog - so just let the default handler do the job
event.Skip();
} else if (m_state == Continue) {
m_memoryDC.SelectObject (m_bitmap); // in memoryDC
showView (m_iLastView);
m_state = Paused;
m_btnPause->SetLabel (wxString("Resume"));
- } else if (m_state == Paused) {
m_pSGP->setDC (m_pDC);\r
m_memoryDC.SelectObject(wxNullBitmap);\r
+ } else if (m_state == Paused) {
m_state = Continue;
m_btnPause->SetLabel (wxString("Pause"));
}
ProjectionsDialog::OnStep (wxCommandEvent& event)
{
if ( m_state == Finished ) {
- // this means that the count down is already finished and we're being
- // shown as a modal dialog - so just let the default handler do the job
event.Skip();
} else if (m_state == Continue) {
m_memoryDC.SelectObject (m_bitmap); // in memoryDC
m_pSGP->setDC (&m_memoryDC);
- m_memoryDC.SetFont (*wxSWISS_FONT);
- m_rScanner.collectProjections (m_rProjections, m_rPhantom, m_iLastView, 1, true, m_iTrace, m_pSGP);
+ m_memoryDC.SetFont (*wxSWISS_FONT);\r
+ showView (m_iLastView);
+ // m_rScanner.collectProjections (m_rProjections, m_rPhantom, m_iLastView, 1, true, m_iTrace, m_pSGP);
m_state = Paused;
m_btnPause->SetLabel (wxString("Resume"));
- } else if (m_state == Paused) {
m_pSGP->setDC (m_pDC);\r
m_memoryDC.SelectObject(wxNullBitmap);\r
+ Refresh();\r
+ } else if (m_state == Paused) {
+ m_memoryDC.SelectObject (m_bitmap); // in memoryDC\r
+ m_pSGP->setDC (&m_memoryDC);\r
+ m_memoryDC.SetFont (*wxSWISS_FONT);\r
projectView (m_iLastView + 1);
+ m_pSGP->setDC (m_pDC);\r
+ m_memoryDC.SelectObject(wxNullBitmap);\r
+ Refresh();\r
}
}
{
wxPaintDC paintDC (this);\r
if (m_state == Paused) {
- paintDC.DrawBitmap(m_bitmap, 0, 0, false);
+ paintDC.DrawBitmap (m_bitmap, 0, 0, false);
}
}
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: dlgreconstruct.cpp,v 1.10 2000/12/18 05:40:30 kevin Exp $
+** $Id: dlgreconstruct.cpp,v 1.11 2000/12/18 06:32:13 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
int x, y;\r
this->GetClientSize(&x, &y);\r
m_pSGPDriver = new SGPDriver (m_pDC, x, y);\r
- m_pSGP = new SGP (*m_pSGPDriver);
- m_pSGP->getDriver().idWX()->setDC (&m_pDC);\r
+ m_pSGP = new SGP (*m_pSGPDriver);\r
wxYield(); // Update the display
m_pSGPDriver->idWX()->SetFont(*wxSWISS_FONT);
-#ifdef __WXMAC__
- MacUpdateImmediately();
-#endif
}
void
ReconstructDialog::showView (int iViewNumber, bool bBackprojectView)
{\r
- // m_pSGP->setTextSize(0.01);
if ( iViewNumber < m_rProjections.nView() ) {
m_iLastView = iViewNumber;
::wxYield(); // update the display\r
}
bool
-ReconstructDialog::reconstructView (int iViewNumber)
+ReconstructDialog::reconstructView (int iViewNumber, bool bBackproject)
{
if (iViewNumber <= m_iLastView) // have already done this view
return true;
if (iViewNumber < m_rProjections.nView()) {
::wxYield(); // update the display
- showView (iViewNumber, true);
+ showView (iViewNumber, bBackproject);
::wxYield(); // update the display
if (m_iTrace >= Trace::TRACE_PLOT) {
::wxUsleep(250);
m_state = Finished; // so that we return TRUE below and
} // that [Cancel] handler knew what to do
-#ifdef __WXMAC__
- MacUpdateImmediately();
-#endif
-
::wxYield(); // update the display
return m_state != Cancelled;
}
// shown as a modal dialog - so just let the default handler do the job
event.Skip();
} else if (m_state == Continue) {\r
-// m_memoryDC.SelectObject (m_bitmap); // in memoryDC\r
-// m_pSGP->setDC (&m_memoryDC);\r
-// m_memoryDC.SetFont (*wxSWISS_FONT);\r
+ m_memoryDC.SelectObject (m_bitmap); // in memoryDC\r
+ m_pSGP->setDC (&m_memoryDC);\r
+ m_memoryDC.SetFont (*wxSWISS_FONT);\r
showView (m_iLastView, false);\r
m_state = Paused;
m_btnPause->SetLabel (wxString("Resume"));
+ m_pSGP->setDC (m_pDC);\r
+ m_memoryDC.SelectObject(wxNullBitmap);\r
} else if (m_state == Paused) {
-// m_pSGP->setDC (m_pDC);\r
-// m_memoryDC.SelectObject(wxNullBitmap);\r
m_state = Continue;
m_btnPause->SetLabel (wxString("Pause"));
}
if ( m_state == Finished ) {
event.Skip();
} else if (m_state == Continue) {\r
-// m_memoryDC.SelectObject (m_bitmap); // in memoryDC\r
-// m_pSGP->setDC (&m_memoryDC);\r
-// m_memoryDC.SetFont (*wxSWISS_FONT);\r
+ m_memoryDC.SelectObject (m_bitmap); // in memoryDC\r
+ m_pSGP->setDC (&m_memoryDC);\r
+ m_memoryDC.SetFont (*wxSWISS_FONT);\r
showView (m_iLastView, false);\r
m_state = Paused;
m_btnPause->SetLabel (wxString("Resume"));
+ m_pSGP->setDC (m_pDC);\r
+ m_memoryDC.SelectObject(wxNullBitmap);\r
+ Refresh();\r
} else if (m_state == Paused) {
-// m_pSGP->setDC (m_pDC);\r
-// m_memoryDC.SelectObject(wxNullBitmap);\r
+ m_memoryDC.SelectObject (m_bitmap); // in memoryDC\r
+ m_pSGP->setDC (&m_memoryDC);\r
+ m_memoryDC.SetFont (*wxSWISS_FONT);\r
reconstructView (m_iLastView + 1);
+ m_pSGP->setDC (m_pDC);\r
+ m_memoryDC.SelectObject(wxNullBitmap);\r
+ Refresh();\r
}
}
{\r
wxPaintDC paintDC (this);\r
if (m_state == Paused) {
- paintDC.DrawBitmap(m_bitmap, 0, 0, false);\r
+ paintDC.DrawBitmap (m_bitmap, 0, 0, false);\r
}\r
}
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: dlgreconstruct.h,v 1.5 2000/12/18 05:40:30 kevin Exp $
+** $Id: dlgreconstruct.h,v 1.6 2000/12/18 06:32:13 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
/* Perform projection on view number
return true if ABORT button has not been pressed
*/
- bool reconstructView (int iViewNumber);
+ bool reconstructView (int iViewNumber, bool bBackproject = true);
/* Can be called to continue after the cancel button has been pressed, but
the program decided to continue the operation (e.g., user didn't