@@ -26,6 +26,7 @@ NormalsFrame::NormalsFrame(QWidget *parent): QFrame(parent) {
26
26
content->addWidget (source_row = new NormalsSourceRow (parameters, this ));
27
27
content->addWidget (flatten_row = new NormalsFlattenRow (parameters, this ));
28
28
content->addWidget (surface_row = new NormalsSurfaceRow (parameters, this ));
29
+ content->addWidget (export_row = new NormalsExportRow (parameters, this ));
29
30
30
31
31
32
{
@@ -66,53 +67,10 @@ NormalsFrame::NormalsFrame(QWidget *parent): QFrame(parent) {
66
67
67
68
68
69
content->addStretch ();
70
+ }
69
71
70
- return ;
71
- content->addWidget (jpg = new QRadioButton (" JPEG: normalmap" ));
72
- content->addWidget (png = new QRadioButton (" PNG: normalmap" ));
73
- {
74
- QButtonGroup *group = new QButtonGroup (this );
75
- group->addButton (jpg);
76
- group->addButton (png);
77
- jpg->setChecked (true );
78
- }
79
-
80
- content->addWidget (new QLabel (" <h2>Flatten normals</h2>" ));
81
- content->addWidget (radial = new QCheckBox (" Radial" ));
82
- content->addWidget (fourier = new QCheckBox (" Fourier" ));
83
- {
84
- QHBoxLayout *fourier_layout = new QHBoxLayout;
85
-
86
- fourier_layout->addWidget (new HelpLabel (" Fourier image percent: " , " normals/flatten" ));
87
- fourier_layout->addWidget (fourier_radius = new QSpinBox);
88
- fourier_radius->setRange (0 , 100 );
89
-
90
- content->addLayout (fourier_layout);
91
- }
92
-
93
- content->addSpacing (30 );
94
- content->addWidget (new QLabel (" <h2>Export 3D surface</h2>" ));
95
- content->addSpacing (30 );
96
- {
97
- QHBoxLayout *discontinuity_layout = new QHBoxLayout;
98
-
99
- discontinuity_layout->addWidget (new HelpLabel (" Disconitnuity parameter:" , " normals/disconituity" ));
100
- discontinuity_layout->addWidget (discontinuity = new QDoubleSpinBox);
101
- discontinuity->setRange (0.0 , 4.0 );
102
- discontinuity->setValue (2.0 );
103
- content->addLayout (discontinuity_layout);
104
- }
105
-
106
- content->addWidget (tif = new QCheckBox (" TIF: depthmap" ));
107
- content->addWidget (ply = new QCheckBox (" PLY: mesh" ));
108
-
109
-
110
- QPushButton *save = new QPushButton (" Export" );
111
- content->addWidget (save);
112
-
113
- connect (save, SIGNAL (clicked ()), this , SLOT (save ()));
114
-
115
- content->addStretch ();
72
+ void NormalsFrame::init () {
73
+ export_row->suggestPath ();
116
74
}
117
75
118
76
void NormalsFrame::save () {
@@ -124,6 +82,7 @@ void NormalsFrame::save() {
124
82
125
83
NormalsTask *task = new NormalsTask ();
126
84
task->parameters = parameters;
85
+ task->output = parameters.path ;
127
86
task->initFromProject (qRelightApp->project ());
128
87
129
88
ProcessQueue &queue = ProcessQueue::instance ();
0 commit comments