mirror of
https://github.com/introlab/rtabmap.git
synced 2026-09-02 01:20:25 +08:00
MainWindow->start detection: fixed error msg on CameraOpenNI2::setExposure when exposure/gain parameters are not available
git-svn-id: http://rtabmap.googlecode.com/svn/trunk/rtabmap@2070 f169173b-cf89-36c8-b27e-44dbe73f0c83
This commit is contained in:
@@ -2242,8 +2242,11 @@ void MainWindow::startDetection()
|
||||
{
|
||||
((CameraOpenNI2*)camera)->setAutoWhiteBalance(_preferencesDialog->getSourceOpenni2AutoWhiteBalance());
|
||||
((CameraOpenNI2*)camera)->setAutoExposure(_preferencesDialog->getSourceOpenni2AutoExposure());
|
||||
((CameraOpenNI2*)camera)->setExposure(_preferencesDialog->getSourceOpenni2Exposure());
|
||||
((CameraOpenNI2*)camera)->setGain(_preferencesDialog->getSourceOpenni2Gain());
|
||||
if(CameraOpenNI2::exposureGainAvailable())
|
||||
{
|
||||
((CameraOpenNI2*)camera)->setExposure(_preferencesDialog->getSourceOpenni2Exposure());
|
||||
((CameraOpenNI2*)camera)->setGain(_preferencesDialog->getSourceOpenni2Gain());
|
||||
}
|
||||
}
|
||||
|
||||
_camera = new CameraThread(camera);
|
||||
|
||||
Reference in New Issue
Block a user