depthai: fixed app freezing if oakd device (oak-d lite) doesn't have imu and imu is requested.

This commit is contained in:
matlabbe
2022-10-24 11:13:27 -07:00
parent a8cdf1f940
commit df888962f4
3 changed files with 45 additions and 31 deletions

View File

@@ -3931,9 +3931,10 @@ void PreferencesDialog::selectSourceDriver(Src src, int variant)
// disable IMU filtering (zed sends already quaternion)
_ui->comboBox_imuFilter_strategy->setCurrentIndex(0);
}
else if(src == kSrcStereoDepthAI) // OAK-D, OAK-D Lite
else if(src == kSrcStereoDepthAI) // OAK-D (variant==1), OAK-D Lite (variant==0)
{
_ui->checkBox_depthai_imu_published->setChecked(variant == 1);
_ui->comboBox_depthai_resolution->setCurrentIndex(variant == 1?1:3);
}
}
else if(src >= kSrcRGB && src<kSrcDatabase)

View File

@@ -63,7 +63,7 @@
<property name="geometry">
<rect>
<x>0</x>
<y>-548</y>
<y>-543</y>
<width>756</width>
<height>3657</height>
</rect>
@@ -5815,7 +5815,7 @@ when using the file type, logs are saved in LogRtabmap.txt (located in the worki
<item row="0" column="0">
<widget class="QComboBox" name="comboBox_depthai_resolution">
<property name="currentIndex">
<number>1</number>
<number>0</number>
</property>
<property name="sizeAdjustPolicy">
<enum>QComboBox::AdjustToContents</enum>
@@ -5835,6 +5835,16 @@ when using the file type, logs are saved in LogRtabmap.txt (located in the worki
<string>400p</string>
</property>
</item>
<item>
<property name="text">
<string>480p</string>
</property>
</item>
<item>
<property name="text">
<string>1200p</string>
</property>
</item>
</widget>
</item>
<item row="2" column="0">