-
Notifications
You must be signed in to change notification settings - Fork 4.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
How to get color frame and pose data in same time #3817
Comments
@HowICanBeWithYou hello,
These modes are mutually-exclusive and cannot be applied interchangeably. Once you apply
the pipeline is internally configured to redirect all the outputs to the callback invocation. Calling The asynchronous mode of operation is elaborated in rs-callback tutorial. Note, that contrary to low-level |
@ev-mp
In addition,for others who use this code for test, there are some other tips found during the debug process. For the |
Glad it you've managed to resolve it. Couple of notes:
There are actually auxillary functions that are designed to read different frame types. So there is no need to use heuristic to differenciate depth and color: auto fs = pipe.wait_for_frames();
auto depth_frame = fs.get_depth_frame();
auto color_frame = fs.get_color_frame();
In the this case the |
Before opening a new issue, we wanted to provide you with some useful suggestions (Click "Preview" above for a better view):
All users are welcomed to report bugs, ask questions, suggest or request enhancements and generally feel free to open new issue, even if they haven't followed any of the suggestions above :)
Issue Description
<Describe your issue / question / feature request / etc..>
I want to read the aligned color image , depth image and the imu data. And I want to calculate the pose at the same time .
I try the way that used in the "rs-motion.cpp" (examples/motion)to calculate the camera pose. In my wish , there are two threads:One thread read the color_frame,the depth_frame and the aligned motion_frame(contains the current imu data).And other thread can read the imu data consistently to calculate the pose of camera. Either of the two threads does not influence each other. However , If I use "pipe.start(cfg,[&]rs2::frame frame)..." to calculate the pose , I can not get the current frame data with using "pipe.wait_for_frames()" ,even through I set the "cfg" with enabling the color , the depth , the gyrol and the accel streams.
Could you give me some advice about the question?Thanks in advance.
The text was updated successfully, but these errors were encountered: