Skip to content

Commit 0c7bf0d

Browse files
authored
Merge pull request #214 from atsju/JST/QT6retro
Minor Changes necessary for QT6 that are compatible with QT5
2 parents d194cf6 + 01818da commit 0c7bf0d

40 files changed

+127
-167
lines changed

IgramArea.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -73,9 +73,6 @@
7373
#include <opencv2/highgui/highgui.hpp>
7474
#include "dftthumb.h"
7575
#include <QTimer>
76-
#include <QVideoWidget>
77-
#include <QMediaPlayer>
78-
#include <QMediaPlaylist>
7976
#include <QScrollArea>
8077
#include "settingsigram.h"
8178
#include <QDockWidget>

astigpolargraph.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#include "astigpolargraph.h"
22
#include "ui_astigpolargraph.h"
33
#include "surfacemanager.h"
4+
#include <QtCharts/QLegendMarker>
45

56

67
astigPolargraph::astigPolargraph( QList<astigSample>list, QWidget *parent) :

astigstatsdlg.cpp

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
#include <qwt_interval_symbol.h>
1313
#include <qwt_plot_intervalcurve.h>
1414
#include <qwt_scale_engine.h>
15+
#include <qwt_scale_map.h>
1516
#include <qwt_plot_marker.h>
1617
#include <QDebug>
1718
#include <math.h>
@@ -26,6 +27,7 @@
2627
#include <qwt_plot_panner.h>
2728
#include <QScrollArea>
2829
#include <QGroupBox>
30+
#include <QPen>
2931
#include <QPrinter>
3032
#include <QTextDocument>
3133
#include <QTextEdit>
@@ -53,7 +55,7 @@ class Zoomer: public QwtPlotZoomer
5355
Zoomer( QWidget *canvas, QwtPlot * plot ):
5456
QwtPlotZoomer( canvas ),mPlot(plot)
5557
{
56-
setRubberBandPen( QColor( Qt::lightGray ) );
58+
setRubberBandPen( QPen( Qt::lightGray ) );
5759
setTrackerMode( QwtPlotPicker::AlwaysOn );
5860
}
5961

astigzoomer.cpp

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,12 @@
33
#include <qwt_plot.h>
44
#include <qwt_plot_marker.h>
55
#include <QtMath>
6+
#include <QPen>
67

78
astigZoomer::astigZoomer( QWidget *canvas, QwtPlot * plot ):
89
QwtPlotZoomer( canvas ),mPlot(plot)
910
{
10-
setRubberBandPen( QColor( Qt::lightGray ) );
11+
setRubberBandPen( QPen( Qt::lightGray ) );
1112
setTrackerMode( QwtPlotPicker::AlwaysOn );
1213
}
1314

averagewavefrontfilesdlg.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99
#include "utils.h"
1010
#include <opencv2/imgproc.hpp>
1111

12-
void showData(const std::string &txt, Mat mat, bool useLog);
12+
void showData(const std::string &txt, cv::Mat mat, bool useLog);
1313
averageWaveFrontFilesDlg::averageWaveFrontFilesDlg(QStringList list, SurfaceManager *m, QWidget *parent) :
1414
QDialog(parent),
1515
ui(new Ui::averageWaveFrontFilesDlg)

cameracalibwizard.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
#include "cameracalibwizard.h"
22
#include "ui_cameracalibwizard.h"
3+
#include "spdlog/spdlog.h"
34
#include <QLabel>
45
#include <QLayout>
56
#include "camwizardpage1.h"
6-
#include "spdlog/spdlog.h"
77

88
cameraCalibWizard::cameraCalibWizard(QWidget *parent) :
99
QWizard(parent),

camwizardpage1.cpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -240,11 +240,11 @@ void CamWizardPage1::on_compute_clicked()
240240
if (found)
241241
break;
242242
if ( i == 1){
243-
cv::SimpleBlobDetector detector;
243+
static Ptr<SimpleBlobDetector> detector = cv::SimpleBlobDetector::create();
244244

245245
// Detect blobs.
246246
std::vector<cv::KeyPoint> keypoints;
247-
detector.detect( dial, keypoints);
247+
detector->detect( dial, keypoints);
248248

249249
/*int horz = 1;
250250
int vert = 1;
@@ -329,13 +329,13 @@ void CamWizardPage1::on_compute_clicked()
329329
msg << "Grid of " << ui->columns->value() << " X " << ui->rows->value() << " not found. Press any key.";
330330
ui->Results->append("Pattern not found. Calibration failed.");
331331
// Set up the detector with default parameters.
332-
cv::SimpleBlobDetector detector;
332+
static Ptr<SimpleBlobDetector> detector = cv::SimpleBlobDetector::create();
333333

334334
cv::threshold(raw,view, 200, 255, cv::THRESH_BINARY);
335335

336336
// Detect blobs.
337337
std::vector<cv::KeyPoint> keypoints;
338-
detector.detect( view, keypoints);
338+
detector->detect( view, keypoints);
339339

340340
// Draw detected blobs as red circles.
341341
// DrawMatchesFlags::DRAW_RICH_KEYPOINTS flag ensures the size of the circle corresponds to the size of blob

contourplot.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@
4242
#include <qwt_plot_shapeitem.h>
4343
#include <QSettings>
4444
#include <qwt_picker_machine.h>
45+
#include "spdlog/spdlog.h"
4546

4647

4748
double zOffset = 0;

contourrulerparams.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ void ContourRulerParams::on_radialAngleSB_valueChanged(int arg1)
3535
void ContourRulerParams::on_setColorPB_clicked()
3636
{
3737

38-
QColor color = QColorDialog::getColor( ui->setColorPB->palette().color(QPalette::Background));
38+
QColor color = QColorDialog::getColor( ui->setColorPB->palette().color(QPalette::Window));
3939

4040
QSettings set;
4141
set.setValue("contourRulerColor", color.name());

contourtools.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,12 +114,12 @@ void ContourTools::on_ColorMapCB_activated(int index)
114114

115115

116116

117-
void ContourTools::on_zeroOffsetCB_activated(const QString &arg1)
117+
void ContourTools::on_zeroOffsetCB_textActivated(const QString &arg1)
118118
{
119119
emit contourZeroOffsetChanged(arg1);
120120
}
121121

122-
void ContourTools::on_colorRangeCB_activated(const QString &arg1)
122+
void ContourTools::on_colorRangeCB_textActivated(const QString &arg1)
123123
{
124124
ui->errorRangeSpin->setEnabled(arg1 == "Fractions of Wave");
125125
emit contourColorRangeChanged(arg1);

0 commit comments

Comments
 (0)