Skip to content

Commit

Permalink
Revert "Disable cameras after fetching images, projection matrix (#2881
Browse files Browse the repository at this point in the history
…)"

Running the Image API continuously seems to trigger exceptions

This reverts commit ba4be15
  • Loading branch information
rajat2004 committed Oct 7, 2020
1 parent 05a9625 commit 014a196
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 7 deletions.
3 changes: 0 additions & 3 deletions Unreal/Plugins/AirSim/Source/PIPCamera.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -170,9 +170,6 @@ msr::airlib::ProjectionMatrix APIPCamera::getProjectionMatrix(const APIPCamera::
else
mat.setTo(Utils::nan<float>());

// Disable camera after our work is done
const_cast<APIPCamera*>(this)->setCameraTypeEnabled(image_type, false);

return mat;
}

Expand Down
4 changes: 0 additions & 4 deletions Unreal/Plugins/AirSim/Source/UnrealImageCapture.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -112,10 +112,6 @@ void UnrealImageCapture::getSceneCaptureImage(const std::vector<msr::airlib::Ima
response.width = render_results[i]->width;
response.height = render_results[i]->height;
response.image_type = request.image_type;

// Disable camera after fetching images
APIPCamera* camera = cameras_->at(request.camera_name);
camera->setCameraTypeEnabled(request.image_type, false);
}

}
Expand Down

0 comments on commit 014a196

Please sign in to comment.