r648: no message
[ctsim.git] / src / dialogs.h
index 2497562355365f6658ca533d7dfe6a82df08f467..9faf10f932a1fbcf82682b12f3fc6be178c8dc4f 100644 (file)
@@ -9,7 +9,7 @@
 **  This is part of the CTSim program
 **  Copyright (c) 1983-2001 Kevin Rosenberg
 **
-**  $Id: dialogs.h,v 1.29 2001/02/22 00:56:50 kevin Exp $
+**  $Id: dialogs.h,v 1.36 2001/03/30 19:17:32 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
@@ -37,6 +37,7 @@
 #include "procsignal.h"
 #include "filter.h"
 #include "projections.h"
+#include "ctsim-map.h"
 
 
 class CTSimHelpButton : public wxButton
@@ -56,24 +57,24 @@ public:
 class StringValueAndTitleListBox : public wxListBox
 {
  public:
-  StringValueAndTitleListBox (wxDialog* pParent, int nChoices, const char* aszTitle[], const char* aszValue[]);
+  StringValueAndTitleListBox (wxDialog* pParent, int nChoices, const char* const aszTitle[], const char* const aszValue[]);
 
     const char* getSelectionStringValue () const;
 
  private:
-    const char** m_ppszValues;
+    const char* const* m_ppszValues;
 };
 
 
 class StringValueAndTitleRadioBox : public wxRadioBox
 {
  public:
-  StringValueAndTitleRadioBox (wxDialog* pParent, const wxString& strTitle, int nChoices, const char* aszTitle[], const char* aszValue[]);
+  StringValueAndTitleRadioBox (wxDialog* pParent, const wxString& strTitle, int nChoices, const char* const aszTitle[], const char* const aszValue[]);
 
   const char* getSelectionStringValue () const;
 
  private:
-  const char** m_ppszValues;
+  const char* const* m_ppszValues;
 };
 
 
@@ -89,6 +90,18 @@ class DialogGetPhantom : public wxDialog
     StringValueAndTitleRadioBox* m_pRadioBoxPhantom;
 };
 
+class DialogGetThetaRange : public wxDialog
+{
+ public:
+   DialogGetThetaRange (wxWindow* pParent, int iDefaultThetaRange = ParallelRaysums::THETA_RANGE_UNCONSTRAINED);
+    virtual ~DialogGetThetaRange () {}
+
+    int getThetaRange ();
+
+ private:
+    wxRadioBox* m_pRadioBoxThetaRange;
+};
+
 
 #include <vector>
 class ImageFileDocument;
@@ -113,19 +126,21 @@ class DialogPreferences : public wxDialog
 {
  public:
     DialogPreferences (wxWindow* pParent, const char* const pszTitle, bool bAdvanced, bool bAskNewDocs,
-      bool bVerboseLogging, bool bStartupTips);
+      bool bVerboseLogging, bool bStartupTips, bool bUseBackgroundTasks);
     virtual ~DialogPreferences ();
 
     bool getAdvancedOptions ();
     bool getAskDeleteNewDocs ();
     bool getVerboseLogging ();
     bool getStartupTips ();
+    bool getUseBackgroundTasks();
 
  private:
     wxCheckBox* m_pCBAdvancedOptions;
     wxCheckBox* m_pCBAskDeleteNewDocs;
     wxCheckBox* m_pCBVerboseLogging;
     wxCheckBox* m_pCBStartupTips;
+    wxCheckBox* m_pCBUseBackgroundTasks;
 };
 
 
@@ -178,7 +193,7 @@ class DialogGetProjectionParameters : public wxDialog
  public:
     DialogGetProjectionParameters (wxWindow* pParent, int iDefaultNDet = 0, 
       int iDefaultNView = 0, int iDefaultNSamples = 1, double dDefaultRotAngle = 1., 
-      double dDefaultFocalLength = 1, double dDefaultViewRatio = 1., 
+      double dDefaultFocalLength = 1, double dDefaultCenterDetectorLength = 1, double dDefaultViewRatio = 1., 
       double dDefaultScanRatio = 1., int iDefaultGeometry = Scanner::GEOMETRY_PARALLEL, int iDefaultTrace = Trace::TRACE_NONE);
     ~DialogGetProjectionParameters ();
 
@@ -191,6 +206,7 @@ class DialogGetProjectionParameters : public wxDialog
     double getViewRatio ();
     double getScanRatio ();
     double getFocalLengthRatio ();
+    double getCenterDetectorLengthRatio ();
     const char* getGeometry();
 
  private:
@@ -199,6 +215,7 @@ class DialogGetProjectionParameters : public wxDialog
     wxTextCtrl* m_pTextCtrlNSamples;
     wxTextCtrl* m_pTextCtrlRotAngle;
     wxTextCtrl* m_pTextCtrlFocalLength;
+    wxTextCtrl* m_pTextCtrlCenterDetectorLength;
     wxTextCtrl* m_pTextCtrlViewRatio;
     wxTextCtrl* m_pTextCtrlScanRatio;
     StringValueAndTitleRadioBox* m_pRadioBoxGeometry;
@@ -211,6 +228,7 @@ class DialogGetProjectionParameters : public wxDialog
     int m_iDefaultGeometry;
     double m_dDefaultRotAngle;
     double m_dDefaultFocalLength;
+    double m_dDefaultCenterDetectorLength;
     double m_dDefaultViewRatio;
     double m_dDefaultScanRatio;
 };
@@ -226,7 +244,7 @@ class DialogGetReconstructionParameters : public wxDialog
       int iDefaultFilterGeneration = ProcessSignal::FILTER_GENERATION_DIRECT, 
       int iDefaultZeropad = 3, int iDefaultInterpID = Backprojector::INTERP_LINEAR, 
       int iDefaultInterpParam = 1, int iDefaultBackprojectID = Backprojector::BPROJ_IDIFF, 
-      int iDefaultTrace = Trace::TRACE_NONE);
+      int iDefaultTrace = Trace::TRACE_NONE, ReconstructionROI* pROI = NULL);
     virtual ~DialogGetReconstructionParameters ();
 
     unsigned int getXSize();
@@ -239,6 +257,7 @@ class DialogGetReconstructionParameters : public wxDialog
     const char* getInterpName();
     unsigned int getInterpParam();
     const char* getBackprojectName();
+    void getROI (ReconstructionROI* pROI);
     int getTrace ();
 
  private:
@@ -247,7 +266,10 @@ class DialogGetReconstructionParameters : public wxDialog
     wxTextCtrl* m_pTextCtrlZeropad;
     wxTextCtrl* m_pTextCtrlFilterParam;
     wxTextCtrl* m_pTextCtrlInterpParam;
-
+    wxTextCtrl* m_pTextCtrlRoiXMin;
+    wxTextCtrl* m_pTextCtrlRoiXMax;
+    wxTextCtrl* m_pTextCtrlRoiYMin;
+    wxTextCtrl* m_pTextCtrlRoiYMax;
     StringValueAndTitleRadioBox* m_pRadioBoxFilter;
     StringValueAndTitleRadioBox* m_pRadioBoxFilterMethod;
     StringValueAndTitleRadioBox* m_pRadioBoxFilterGeneration;
@@ -260,7 +282,10 @@ class DialogGetReconstructionParameters : public wxDialog
     double m_dDefaultFilterParam;
     int m_iDefaultZeropad;
     int m_iDefaultInterpParam;
-    int m_iDefaultTrace;
+    double m_dDefaultRoiXMin;
+    double m_dDefaultRoiXMax;
+    double m_dDefaultRoiYMin;
+    double m_dDefaultRoiYMax;
 };
 
 
@@ -311,6 +336,18 @@ class DialogExportParameters : public wxDialog
     StringValueAndTitleRadioBox* m_pRadioBoxFormat;
 };
 
+class DialogImportParameters : public wxDialog
+{
+ public:
+    DialogImportParameters (wxWindow* pParent, int iDefaultFormatID);
+    virtual ~DialogImportParameters () {}
+
+    const char* getFormatName();
+
+ private:
+    StringValueAndTitleRadioBox* m_pRadioBoxFormat;
+};
+
 class DialogAutoScaleParameters : public wxDialog
 {
  public:
@@ -353,7 +390,7 @@ class DialogGetConvertPolarParameters : public wxDialog
  public:
    DialogGetConvertPolarParameters (wxWindow* pParent, const char* const pszTitle, int iDefaultXSize = 0, 
      int iDefaultYSize = 0, int iDefaultInterpolationID = Projections::POLAR_INTERP_BILINEAR, 
-     int iDefaultZeropad = 1);
+     int iDefaultZeropad = 1, int iHelpID = IDH_DLG_POLAR);
    virtual ~DialogGetConvertPolarParameters ();
 
     unsigned int getXSize();