Skip to content

Commit 292b059

Browse files
authored
Merge pull request #184 from githubdoe/dalework
A ton of changes by Dale. Lots of new features. See VersionHistory for version 7.3.0
2 parents ad06e16 + 487e0a8 commit 292b059

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+3471
-614
lines changed

DFTFringe.pro

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -148,6 +148,7 @@ SOURCES += SingleApplication/singleapplication.cpp \
148148
annulushelpdlg.cpp \
149149
arbitrarywavefronthelp.cpp \
150150
arbitrarywavwidget.cpp \
151+
astigpolargraph.cpp \
151152
astigscatterplot.cpp \
152153
astigstatsdlg.cpp \
153154
astigzoomer.cpp \
@@ -181,6 +182,7 @@ SOURCES += SingleApplication/singleapplication.cpp \
181182
gplus.cpp \
182183
graphicsutilities.cpp \
183184
helpdlg.cpp \
185+
hotkeysdlg.cpp \
184186
igramarea.cpp \
185187
igramintensity.cpp \
186188
imagehisto.cpp \
@@ -204,9 +206,11 @@ SOURCES += SingleApplication/singleapplication.cpp \
204206
outlineplots.cpp \
205207
outlinestatsdlg.cpp \
206208
pdfcalibrationdlg.cpp \
209+
percentcorrectiondlg.cpp \
207210
pixelstats.cpp \
208211
plotcolor.cpp \
209212
profileplot.cpp \
213+
profileplotpicker.cpp \
210214
psfplot.cpp \
211215
psi_dlg.cpp \
212216
psiphasedisplay.cpp \
@@ -226,6 +230,7 @@ SOURCES += SingleApplication/singleapplication.cpp \
226230
settingsdft.cpp \
227231
settingsGeneral2.cpp \
228232
settingsigram.cpp \
233+
settingsigramimportconfig.cpp \
229234
settingsprofile.cpp \
230235
showaliasdlg.cpp \
231236
showallcontoursdlg.cpp \
@@ -266,6 +271,7 @@ HEADERS += bezier/bezier.h \
266271
SingleApplication/singleapplication.h \
267272
annulushelpdlg.h \
268273
arbitrarywavefronthelp.h \
274+
astigpolargraph.h \
269275
arbitrarywavwidget.h \
270276
astigscatterplot.h \
271277
astigstatsdlg.h \
@@ -302,6 +308,7 @@ HEADERS += bezier/bezier.h \
302308
gplus.h \
303309
graphicsutilities.h \
304310
helpdlg.h \
311+
hotkeysdlg.h \
305312
IgramArea.h \
306313
igramintensity.h \
307314
imagehisto.h \
@@ -324,9 +331,12 @@ HEADERS += bezier/bezier.h \
324331
outlineplots.h \
325332
outlinestatsdlg.h \
326333
pdfcalibrationdlg.h \
334+
percentcorrectiondlg.h \
335+
percentCorrectionSurface.h \
327336
pixelstats.h \
328337
plotcolor.h \
329338
profileplot.h \
339+
profileplotpicker.h \
330340
psfplot.h \
331341
psi_dlg.h \
332342
psiphasedisplay.h \
@@ -346,6 +356,7 @@ HEADERS += bezier/bezier.h \
346356
settingsdft.h \
347357
settingsGeneral2.h \
348358
settingsigram.h \
359+
settingsigramimportconfig.h \
349360
settingsprofile.h \
350361
showaliasdlg.h \
351362
showallcontoursdlg.h \
@@ -384,6 +395,7 @@ HEADERS += bezier/bezier.h \
384395

385396
FORMS += arbitrarywavefronthelp.ui \
386397
annulushelpdlg.ui \
398+
astigpolargraph.ui \
387399
astigstatsdlg.ui \
388400
averagewavefrontfilesdlg.ui \
389401
batchigramwizard.ui \
@@ -407,6 +419,7 @@ FORMS += arbitrarywavefronthelp.ui \
407419
foucaultview.ui \
408420
generatetargetdlg.ui \
409421
helpdlg.ui \
422+
hotkeysdlg.ui \
410423
igramintensity.ui \
411424
jitteroutlinedlg.ui \
412425
lensdialog.ui \
@@ -421,6 +434,7 @@ FORMS += arbitrarywavefronthelp.ui \
421434
outlineplots.ui \
422435
outlinestatsdlg.ui \
423436
pdfcalibrationdlg.ui \
437+
percentcorrectiondlg.ui \
424438
pixelstats.ui \
425439
profilearea.ui \
426440
profileplot.ui \
@@ -441,6 +455,7 @@ FORMS += arbitrarywavefronthelp.ui \
441455
settingsdft.ui \
442456
settingsGeneral2.ui \
443457
settingsigram.ui \
458+
settingsigramimportconfig.ui \
444459
settingsprofile.ui \
445460
showaliasdlg.ui \
446461
showallcontoursdlg.ui \

DFTFringe_Dale.pro

Lines changed: 17 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,9 +30,11 @@ SOURCES += main.cpp \
3030
annulushelpdlg.cpp \
3131
arbitrarywavefronthelp.cpp \
3232
arbitrarywavwidget.cpp \
33+
astigpolargraph.cpp \
3334
cpoint.cpp \
3435
defocusdlg.cpp \
3536
edgeplot.cpp \
37+
hotkeysdlg.cpp \
3638
mainwindow.cpp \
3739
igramarea.cpp \
3840
circleoutline.cpp \
@@ -42,8 +44,11 @@ SOURCES += main.cpp \
4244
dftarea.cpp \
4345
oglrendered.cpp \
4446
pdfcalibrationdlg.cpp \
47+
percentcorrectiondlg.cpp \
4548
profileplot.cpp \
49+
profileplotpicker.cpp \
4650
psiresizeimagesdlg.cpp \
51+
settingsigramimportconfig.cpp \
4752
surface3dcontrolsdlg.cpp \
4853
surfacegraph.cpp \
4954
surfacelightingproxy.cpp \
@@ -148,6 +153,7 @@ HEADERS += mainwindow.h \
148153
annulushelpdlg.h \
149154
arbitrarywavefronthelp.h \
150155
arbitrarywavwidget.h \
156+
astigpolargraph.h \
151157
cpoint.h \
152158
defocusdlg.h \
153159
edgeplot.h \
@@ -157,10 +163,15 @@ HEADERS += mainwindow.h \
157163
graphicsutilities.h \
158164
dfttools.h \
159165
dftarea.h \
166+
hotkeysdlg.h \
160167
oglrendered.h \
161168
pdfcalibrationdlg.h \
169+
percentCorrectionSurface.h \
170+
percentcorrectiondlg.h \
162171
profileplot.h \
172+
profileplotpicker.h \
163173
psiresizeimagesdlg.h \
174+
settingsigramimportconfig.h \
164175
surface3dcontrolsdlg.h \
165176
surfacegraph.h \
166177
surfacelightingproxy.h \
@@ -270,16 +281,20 @@ INCLUDEPATH += ./bezier ./SingleApplication
270281
FORMS += mainwindow.ui \
271282
annulushelpdlg.ui \
272283
arbitrarywavefronthelp.ui \
284+
astigpolargraph.ui \
273285
defocusdlg.ui \
274286
dfttools.ui \
275287
dftarea.ui \
276288
edgeplot.ui \
289+
hotkeysdlg.ui \
277290
oglrendered.ui \
278291
pdfcalibrationdlg.ui \
292+
percentcorrectiondlg.ui \
279293
profilearea.ui \
280294
profileplot.ui \
281295
contourtools.ui \
282296
psiresizeimagesdlg.ui \
297+
settingsigramimportconfig.ui \
283298
surface3dcontrolsdlg.ui \
284299
surfaceanalysistools.ui \
285300
metricsdisplay.ui \
@@ -408,12 +423,12 @@ RC_FILE = DFTFringe.rc
408423
QMAKE_CXXFLAGS += -std=c++11
409424

410425
# The application version
411-
VERSION = 6.2
426+
VERSION = Dale7.3.0
412427

413428
# Define the preprocessor macro to get the application version in our application.
414429
DEFINES += APP_VERSION=\\\"$$VERSION\\\"
415430
DEFINES += QAPPLICATION_CLASS=QApplication
416-
431+
DEFINES += DALE_DO_NOT_LOG
417432
DISTFILES += \
418433
buildingDFTFringe64.txt \
419434
helptext.txt \

RevisionHistory.html

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -418,3 +418,16 @@
418418
<li>Improved saving speed when working on network drives</li>
419419
</ul>
420420
</ul>
421+
422+
<ul><li>Version 7.3.0</li>
423+
<ul>
424+
<li>Added zonal percent completion graph to profile options</li>
425+
<li>Added polar plot of the astig of selected wave fronts under View menu.</li>
426+
<li>Changed create movie feature to add user provided prefix to each from created.</li>
427+
<li>Added hot keys to import interferogram</li>
428+
<li>Added hot key to help</li>
429+
<li>User can move mouse cursor over any profile shown, click and drag it up or down. Useful for comparing two work sessions results so that they match at zero height.</li>
430+
<li>If mouse is over the profile plot the scroll wheel can increase or decrease the y axis range.</li>
431+
<li>Added auto collimation setting to Ronchi and Foucault feature</li>
432+
<li>Remembered last ROC offset value in Ronchi and Foucault feature to remember last setting when wave front is changed to a different value</li>
433+
</ul>

astigpolargraph.cpp

Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
#include "astigpolargraph.h"
2+
#include "ui_astigpolargraph.h"
3+
#include "surfacemanager.h"
4+
5+
void astigPolargraph::makeChart(){
6+
7+
8+
QPolarChart *chart = new QPolarChart();
9+
10+
// process each wave front and place astig on the chart
11+
ui->waveFrontTable->setRowCount(m_list.size());
12+
13+
QValueAxis *angularAxis = new QValueAxis();
14+
angularAxis->setTickCount(9); // First and last ticks are co-located on 0/360 angle.
15+
angularAxis->setLabelFormat("%.0f");
16+
angularAxis->setShadesVisible(true);
17+
angularAxis->setShadesBrush(QBrush(QColor(249, 249, 255)));
18+
chart->addAxis(angularAxis, QPolarChart::PolarOrientationAngular);
19+
20+
QValueAxis *radialAxis = new QValueAxis();
21+
radialAxis->setTickCount(5);
22+
radialAxis->setLabelFormat("%.1f");
23+
chart->addAxis(radialAxis, QPolarChart::PolarOrientationRadial);
24+
double maxAstig = 1.;
25+
26+
QVector<wavefront *> wavefronts =SurfaceManager::get_instance()->m_wavefronts;
27+
28+
for(int ndx = 0; ndx < m_list.length(); ++ndx){
29+
wavefront *wf = wavefronts[m_list[ndx]];
30+
QString name = wf->name;
31+
int slashndx = name.lastIndexOf('/');
32+
QString shortName = name.mid(name.lastIndexOf('/',slashndx-1));
33+
QTableWidgetItem *item = new QTableWidgetItem(shortName, 0);
34+
ui->waveFrontTable->setItem(ndx,0,item);
35+
double xastig = wf->InputZerns[4];
36+
double yastig = wf->InputZerns[5];
37+
double mag = sqrt(xastig * xastig + yastig * yastig);
38+
if (mag > maxAstig) maxAstig = mag;
39+
40+
double angle = (atan2(yastig,xastig)/2.) * 180./M_PI;
41+
angle = 90 - angle;
42+
QScatterSeries *series = new QScatterSeries();
43+
44+
int lastndx = name.lastIndexOf('/');
45+
if (lastndx != -1)
46+
name = name.mid(lastndx);
47+
series->setName(name);
48+
series->append(angle,mag);
49+
series->append(angle+180,mag);
50+
chart->addSeries(series);
51+
series->attachAxis(radialAxis);
52+
series->attachAxis(angularAxis);
53+
54+
QLineSeries *line = new QLineSeries();
55+
line->append(angle,mag);
56+
line->append(angle+180,mag);
57+
chart->addSeries(line);
58+
line->attachAxis(radialAxis);
59+
line->attachAxis(angularAxis);
60+
chart->legend()->markers(line)[0]->setVisible(false);
61+
62+
line->setPen(QPen(series->brush(),5));
63+
64+
QTableWidgetItem *pv = new QTableWidgetItem(QString().number(mag), 0);
65+
item->setForeground(series->brush());
66+
ui->waveFrontTable->setItem(ndx, 1, pv);
67+
QTableWidgetItem *anglewidget = new QTableWidgetItem(QString().number(angle,'f',1), 0);
68+
ui->waveFrontTable->setItem(ndx, 2, anglewidget);
69+
}
70+
71+
chart->setTitle("Magnitude and axis of high edge");
72+
if (m_list.length() > 4)
73+
chart->legend()->setAlignment(Qt::AlignRight);
74+
else chart->legend()->setAlignment(Qt::AlignBottom);
75+
76+
maxAstig = ceil(maxAstig);
77+
radialAxis->setRange(0, maxAstig);
78+
angularAxis->setRange(0, 360);
79+
80+
ui->polarChart->setChart(chart);
81+
82+
83+
84+
}
85+
astigPolargraph::astigPolargraph( QList<int>list, QWidget *parent) :
86+
QDialog(parent),
87+
ui(new Ui::astigPolargraph), m_list(list)
88+
{
89+
ui->setupUi(this);
90+
//For some reason the original starter code of makeChart was in this function but it caused a crash.
91+
// I could never figure out why because that code was taken from a working Qt example. When
92+
// moved to inside another function it worked. So there you go. Exact same code with no changes worked there but not here.
93+
makeChart();
94+
95+
96+
}
97+
98+
astigPolargraph::~astigPolargraph()
99+
{
100+
delete ui;
101+
}

astigpolargraph.h

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
#ifndef ASTIGPOLARGRAPH_H
2+
#define ASTIGPOLARGRAPH_H
3+
4+
#include <QDialog>
5+
#include <QtCharts/QScatterSeries>
6+
#include <QtCharts/QLineSeries>
7+
#include <QtCharts/QSplineSeries>
8+
#include <QtCharts/QAreaSeries>
9+
#include <QtCharts/QValueAxis>
10+
#include <QtCharts/QPolarChart>
11+
#include "wavefront.h"
12+
13+
namespace Ui {
14+
class astigPolargraph;
15+
}
16+
17+
class astigPolargraph : public QDialog
18+
{
19+
Q_OBJECT
20+
21+
public:
22+
explicit astigPolargraph(QList<int> list,QWidget *parent = nullptr);
23+
~astigPolargraph();
24+
25+
private:
26+
Ui::astigPolargraph *ui;
27+
QList<int> m_list; // list index of selected wave fronts in surface manager's list.
28+
void makeChart();
29+
};
30+
31+
#endif // ASTIGPOLARGRAPH_H

0 commit comments

Comments
 (0)