-
Notifications
You must be signed in to change notification settings - Fork 4.9k
Fixing Y12i stream output in MIPI with CUDA case #13084
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
Fixing Y12i stream output in MIPI with CUDA case #13084
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The code for mipi and not pipi is exactly the same - the only difference is the padding of 8 bits that has been added for mipi.
Few questions:
Is the other padding used anywhere? (y16_y16_from_y12i)?
If no - please remove it, and keep only the mipi one.
If yes - since the code is exactly the same besides the type used (y12i_pixel or y12i_pixel_mipi), could you change it to a template function that would be used for both cases (once with the y12i_pixel type, and once with the y12i_pixel_mipi type)?
@remibettan, UVC with CUDA must be using |
|
||
template void rscuda::y16_y16_from_y12i_10_cuda_helper<rscuda::y12i_pixel_mipi>(uint8_t* const dest[], int count, const rscuda::y12i_pixel_mipi * source); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As we talked, please delete this line and the above line, and see next comment
@@ -16,7 +16,7 @@ namespace librealsense | |||
{ | |||
auto count = width * height; | |||
#ifdef RS2_USE_CUDA | |||
rscuda::split_frame_y16_y16_from_y12i_cuda_mipi(dest, count, reinterpret_cast<const y12i_pixel_mipi *>(source)); | |||
rscuda::split_frame_y16_y16_from_y12i_cuda(dest, count, reinterpret_cast<const rscuda::y12i_pixel_mipi *>(source)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Instead of :rscuda::split_frame_y16_y16_from_y12i_cuda(dest, count, reinterpret_cast<const rscuda::y12i_pixel_mipi *>(source));
Please try:
rscuda::split_frame_y16_y16_from_y12i_cuda<rscuda::y12i_pixel_mipi *>(dest, count, reinterpret_cast<const rscuda::y12i_pixel_mipi *>(source));
@@ -15,7 +15,7 @@ namespace librealsense | |||
{ | |||
auto count = width * height; | |||
#ifdef RS2_USE_CUDA | |||
rscuda::split_frame_y16_y16_from_y12i_cuda(dest, count, reinterpret_cast<const y12i_pixel *>(source)); | |||
rscuda::split_frame_y16_y16_from_y12i_cuda(dest, count, reinterpret_cast<const rscuda::y12i_pixel *>(source)); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Intead of:
rscuda::split_frame_y16_y16_from_y12i_cuda(dest, count, reinterpret_cast<const rscuda::y12i_pixel *>(source));
Please try:
rscuda::split_frame_y16_y16_from_y12i_cuda<rscuda::y12i_pixel *>(dest, count, reinterpret_cast<const rscuda::y12i_pixel *>(source));
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
please see inline comments
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
df68f90
into
IntelRealSense:development
Tracked by LRS-1052