mirror of
https://gitlab.com/then-try-this/samplebrain.git
synced 2025-05-11 10:07:21 +00:00
added target filename to GUI - not adding brain session or directory as less need for it/more clutter... partially fixes: #76
This commit is contained in:
parent
f9f3557b79
commit
bc8002a9f0
@ -161,6 +161,12 @@ void MainWindow::init_from_session(const string &filename) {
|
|||||||
m_Ui.spinBoxSlideError->setValue(r.get_slide_error());
|
m_Ui.spinBoxSlideError->setValue(r.get_slide_error());
|
||||||
|
|
||||||
// target
|
// target
|
||||||
|
if (t.get_samples().size()>0) {
|
||||||
|
// extract target filename from brain sample
|
||||||
|
string fn = t.get_samples().begin()->m_filename;
|
||||||
|
m_Ui.labelTargetSound->setText("loaded: "+QFileInfo(QString::fromStdString(fn)).fileName());
|
||||||
|
}
|
||||||
|
|
||||||
m_Ui.spinBoxBlockSizeTarget->setValue(t.get_block_size());
|
m_Ui.spinBoxBlockSizeTarget->setValue(t.get_block_size());
|
||||||
m_Ui.doubleSpinBoxBlockOverlapTarget->setValue(t.get_overlap()/(float)t.get_block_size());
|
m_Ui.doubleSpinBoxBlockOverlapTarget->setValue(t.get_overlap()/(float)t.get_block_size());
|
||||||
|
|
||||||
|
@ -212,6 +212,7 @@ private slots:
|
|||||||
m_format_string);
|
m_format_string);
|
||||||
if (m_last_target_file!="") {
|
if (m_last_target_file!="") {
|
||||||
m_last_target_file=path;
|
m_last_target_file=path;
|
||||||
|
m_Ui.labelTargetSound->setText("loaded: "+QFileInfo(path).fileName());
|
||||||
send_process_osc("/load_target","s",m_last_target_file.toStdString().c_str());
|
send_process_osc("/load_target","s",m_last_target_file.toStdString().c_str());
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -728,6 +728,13 @@
|
|||||||
</property>
|
</property>
|
||||||
</widget>
|
</widget>
|
||||||
</item>
|
</item>
|
||||||
|
<item>
|
||||||
|
<widget class="QLabel" name="labelTargetSound">
|
||||||
|
<property name="text">
|
||||||
|
<string>no target sound loaded</string>
|
||||||
|
</property>
|
||||||
|
</widget>
|
||||||
|
</item>
|
||||||
<item>
|
<item>
|
||||||
<widget class="QPushButton" name="pushButtonLoadTarget">
|
<widget class="QPushButton" name="pushButtonLoadTarget">
|
||||||
<property name="font">
|
<property name="font">
|
||||||
@ -1112,8 +1119,8 @@
|
|||||||
</property>
|
</property>
|
||||||
<property name="sizeHint" stdset="0">
|
<property name="sizeHint" stdset="0">
|
||||||
<size>
|
<size>
|
||||||
<width>20</width>
|
<width>17</width>
|
||||||
<height>40</height>
|
<height>13</height>
|
||||||
</size>
|
</size>
|
||||||
</property>
|
</property>
|
||||||
</spacer>
|
</spacer>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user