-
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 crop rs2::frame #11140
Comments
Hi @AlexKanakis5 There is a further discussion of this cropping method at #8512 if you have not seen it already A couple of different approaches to cropping are at #2016 (comment) and #3894 (comment) |
I didn't get an answer to my original question but these suggestions really helped. What I wanted was to create a point cloud from the copped frame. What I ended up doing was to follow what the #2016 comment described with some help from the link in the #3894 comment. For anyone in a similar situation as me this is the methodology I followed:
Here is a snippet from my code that I used to convert the pixels to points. This does not work on its own but it gives an idea on how to get there.
|
It's great to hear that you achieved a solution, @AlexKanakis5 - thanks so much for sharing it with the RealSense community! |
Case closed due to solution achieved and no further comments received. |
Issue Description
<Describe your issue / question / feature request / etc..>
Hello,
I want to crop a frame to specific dimensions. From what I understand, I have to convert it to Mat, crop it and then convert it back to a frame. I have seen the issue #2634 on how to convert Mat to frame, and the code works when applying Gaussian blur as the example. However when I crop the Mat and then convert it, the resulting frame is not cropped. I am new and I am really struggling with this, any help would be much appreciated.
realsense_crop.txt
The text was updated successfully, but these errors were encountered: