projects
/
ctsim.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
r264: *** empty log message ***
[ctsim.git]
/
src
/
dlgreconstruct.cpp
diff --git
a/src/dlgreconstruct.cpp
b/src/dlgreconstruct.cpp
index e9831843568d87a90af89727ac465c0ae928efc2..4729ee9c3930aad1542da8bf967d841a04e7d77b 100644
(file)
--- a/
src/dlgreconstruct.cpp
+++ b/
src/dlgreconstruct.cpp
@@
-9,7
+9,7
@@
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
** This is part of the CTSim program
** Copyright (C) 1983-2000 Kevin Rosenberg
**
-** $Id: dlgreconstruct.cpp,v 1.
5 2000/09/07 14:29:05
kevin Exp $
+** $Id: dlgreconstruct.cpp,v 1.
7 2000/12/16 03:39:06
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
**
** 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
@@
-36,7
+36,6
@@
#pragma hdrstop
#endif
#pragma hdrstop
#endif
-#ifndef WX_PRECOMP
#include "wx/utils.h"
#include "wx/frame.h"
#include "wx/button.h"
#include "wx/utils.h"
#include "wx/frame.h"
#include "wx/button.h"
@@
-48,7
+47,6
@@
#include "wx/dcclient.h"
#include "wx/timer.h"
#include "wx/image.h"
#include "wx/dcclient.h"
#include "wx/timer.h"
#include "wx/image.h"
-#endif
#include "dlgreconstruct.h"
#include <algorithm>
#include "dlgreconstruct.h"
#include <algorithm>
@@
-57,6
+55,13
@@
static const int LAYOUT_X_MARGIN = 4;
static const int LAYOUT_Y_MARGIN = 4;
static const int LAYOUT_X_MARGIN = 4;
static const int LAYOUT_Y_MARGIN = 4;
+
\r
+
\r
+const int ReconstructDialog::ID_BTN_PAUSE = 19998;
\r
+const int ReconstructDialog::ID_BTN_STEP = 19999;
\r
+const int ReconstructDialog::MAX_IMAGE_X = 400;
\r
+const int ReconstructDialog::MAX_IMAGE_Y = 400;
\r
+
\r
BEGIN_EVENT_TABLE(ReconstructDialog, wxDialog)
EVT_BUTTON(wxID_CANCEL, ReconstructDialog::OnCancel)
BEGIN_EVENT_TABLE(ReconstructDialog, wxDialog)
EVT_BUTTON(wxID_CANCEL, ReconstructDialog::OnCancel)
@@
-189,13
+194,13
@@
ReconstructDialog::showView (int iViewNumber)
}
unsigned char* imageData = new unsigned char [m_nxImage * m_nyImage * 3];
double dScale = 255 / (maxValue - minValue);
}
unsigned char* imageData = new unsigned char [m_nxImage * m_nyImage * 3];
double dScale = 255 / (maxValue - minValue);
- for (int ix
= 0; ix < m_nxImage; ix
++) {
+ for (int ix
2 = 0; ix2 < m_nxImage; ix2
++) {
for (int iy = 0; iy < m_nyImage; iy++) {
for (int iy = 0; iy < m_nyImage; iy++) {
- double dPixel = v[ix][iy];
+ double dPixel = v[ix
2
][iy];
dPixel = (dPixel - minValue) * dScale;
int intensity = nearest<int>(dPixel);
intensity = clamp (intensity, 0, 255);
dPixel = (dPixel - minValue) * dScale;
int intensity = nearest<int>(dPixel);
intensity = clamp (intensity, 0, 255);
- int baseAddr = ((m_nyImage - 1 - iy) * m_nxImage + ix) * 3;
+ int baseAddr = ((m_nyImage - 1 - iy) * m_nxImage + ix
2
) * 3;
imageData[baseAddr] = imageData[baseAddr+1] = imageData[baseAddr+2] = intensity;
}
}
imageData[baseAddr] = imageData[baseAddr+1] = imageData[baseAddr+2] = intensity;
}
}