From 22bd0fab3adb0912ebc8e1ffbd6299c276a7f445 Mon Sep 17 00:00:00 2001 From: TinyOh Date: Sat, 2 Mar 2019 08:35:33 +0800 Subject: [PATCH] fix(api): LEFT/RIGHT callback fix --- samples/tutorials/data/get_imu_correspondence.cc | 2 ++ src/mynteye/api/synthetic.cc | 4 ++++ 2 files changed, 6 insertions(+) diff --git a/samples/tutorials/data/get_imu_correspondence.cc b/samples/tutorials/data/get_imu_correspondence.cc index 9cec957..def7ba8 100644 --- a/samples/tutorials/data/get_imu_correspondence.cc +++ b/samples/tutorials/data/get_imu_correspondence.cc @@ -30,6 +30,8 @@ int main(int argc, char *argv[]) { api->ConfigStreamRequest(request); // Enable motion datas with timestamp correspondence of some stream + api->EnableStreamData(Stream::LEFT); + api->EnableStreamData(Stream::RIGHT); api->EnableTimestampCorrespondence(Stream::LEFT); api->Start(Source::ALL); diff --git a/src/mynteye/api/synthetic.cc b/src/mynteye/api/synthetic.cc index abb7c36..f3ddd9f 100644 --- a/src/mynteye/api/synthetic.cc +++ b/src/mynteye/api/synthetic.cc @@ -384,6 +384,8 @@ void Synthetic::InitProcessors() { processors_.push_back(points_processor); processors_.push_back(depth_processor); using namespace std::placeholders; // NOLINT + root_processor->SetProcessCallback( + std::bind(&Synthetic::OnDeviceProcess, this, _1, _2, _3)); rectify_processor->SetProcessCallback( std::bind(&Synthetic::OnRectifyProcess, this, _1, _2, _3)); disparity_processor->SetProcessCallback( @@ -395,6 +397,8 @@ void Synthetic::InitProcessors() { depth_processor->SetProcessCallback( std::bind(&Synthetic::OnDepthProcess, this, _1, _2, _3)); + root_processor->SetPostProcessCallback( + std::bind(&Synthetic::OnDevicePostProcess, this, _1)); rectify_processor->SetPostProcessCallback( std::bind(&Synthetic::OnRectifyPostProcess, this, _1)); disparity_processor->SetPostProcessCallback(