File indexing completed on 2024-12-22 04:18:18
0001 /*************************************************************************** 0002 * * 0003 * copyright : (C) 2007 The University of Toronto * 0004 * netterfield@astro.utoronto.ca * 0005 * * 0006 * This program is free software; you can redistribute it and/or modify * 0007 * it under the terms of the GNU General Public License as published by * 0008 * the Free Software Foundation; either version 2 of the License, or * 0009 * (at your option) any later version. * 0010 * * 0011 ***************************************************************************/ 0012 0013 #ifndef FFTOPTIONS_H 0014 #define FFTOPTIONS_H 0015 0016 #include <QWidget> 0017 #include "ui_fftoptions.h" 0018 0019 #include "psd.h" 0020 0021 #include "kstwidgets_export.h" 0022 0023 namespace Kst { 0024 0025 class KSTWIDGETS_EXPORT FFTOptions : public QWidget, public Ui::FFTOptions 0026 { 0027 Q_OBJECT 0028 0029 public: 0030 explicit FFTOptions(QWidget *parent = 0); 0031 ~FFTOptions(); 0032 0033 double sampleRate() const; 0034 bool sampleRateDirty() const; 0035 void setSampleRate(const double sampleRate); 0036 0037 double sigma() const; 0038 bool sigmaDirty() const; 0039 void setSigma(const double sigma); 0040 0041 bool interleavedAverage() const; 0042 bool interleavedAverageDirty() const; 0043 void setInterleavedAverage(const bool interleavedAverage); 0044 0045 int FFTLength() const; 0046 bool FFTLengthDirty() const; 0047 void setFFTLength(const int FFTLength); 0048 0049 bool apodize() const; 0050 bool apodizeDirty() const; 0051 void setApodize(const bool apodize); 0052 0053 bool removeMean() const; 0054 bool removeMeanDirty() const; 0055 void setRemoveMean(const bool removeMean); 0056 0057 QString vectorUnits() const; 0058 bool vectorUnitsDirty() const; 0059 void setVectorUnits(const QString vectorUnits); 0060 0061 QString rateUnits() const; 0062 bool rateUnitsDirty() const; 0063 void setRateUnits(const QString rateUnits); 0064 0065 ApodizeFunction apodizeFunction() const; 0066 bool apodizeFunctionDirty() const; 0067 void setApodizeFunction(const ApodizeFunction apodizeFunction); 0068 0069 PSDType output() const; 0070 bool outputDirty() const; 0071 void setOutput(const PSDType output); 0072 0073 void clearValues(); 0074 0075 void setWidgetDefaults(); 0076 void loadWidgetDefaults(); 0077 0078 Q_SIGNALS: 0079 void modified(); 0080 0081 public slots: 0082 void changedApodizeFxn(); 0083 void clickedInterleaved(); 0084 void clickedApodize(); 0085 void synch(); 0086 bool checkValues(); 0087 bool checkGivenValues(double sampRate, int FFTLen); 0088 0089 private: 0090 void init(); 0091 }; 0092 0093 } 0094 #endif 0095 // vim: ts=2 sw=2 et