Skip to content
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

Aligning color to depth (again) #3338

Closed
AndrewFielding opened this issue Feb 27, 2019 · 4 comments
Closed

Aligning color to depth (again) #3338

AndrewFielding opened this issue Feb 27, 2019 · 4 comments
Labels

Comments

@AndrewFielding
Copy link


Required Info
Camera Model { D415}
Firmware Version (05.11.01.00)
Operating System & Version {Win (10) /
Kernel Version (Linux Only)
Platform PC/
SDK Version { 2.18.1}
Language {matlab }
Segment {Robot/Smartphone/VR/AR/others }

Issue Description

I am trying to use the align.m function to align video and depth streams using the MATLAB wrapper. I am using the code chunk suggested in issue #2455.

align_to = realsense.stream.color;
alignedFs = realsense.align(align_to);
.....
fs = pipe.wait_for_frames();
aligned_frames = alignedFs.process(fs);

When using this I get the following error message corresponding to the line of script.

alignedFs = realsense.align(align_to);

Can anyone help with this error message (see below)?

Error using realsense.align
Error: File: align.m Line: 9 Column: 35
A constructor call to superclass realsense.filter appears after the object is used, or after a return.

Error in acquire_color_depth (line 45)
aligned = realsense.align(align_to);

@RealSenseCustomerSupport
Copy link
Collaborator


Hi AndrewFielding,

Besides the changes mentioned in #2455, you will need to do another change in align constructor.
Together 2 changes:
a) For https://github.com/IntelRealSense/librealsense/blob/master/wrappers/matlab/align.m#L8
Replace "this.objectHandle" with "out", which is used in next line for fitler().
b) As mentioned in #2455, comment out validateattributes() in process()
https://github.com/IntelRealSense/librealsense/blob/master/wrappers/matlab/align.m#L17

Thanks!

@RealSenseCustomerSupport
Copy link
Collaborator


Hi AndrewFielding,

Wonder if you have any update?

Thanks!

@AndrewFielding
Copy link
Author

AndrewFielding commented Mar 26, 2019 via email

@lramati
Copy link
Contributor

lramati commented Mar 26, 2019 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants