Capturing IR video by OpenCV with Femto

I use https://opencv.org/orbbec-3d-uvc-cameras-are-now-supported-by-opencv/
This example works great with femto. I tried to add capture IR image in similar way by
if (obsensorCapture.retrieve(irMap, CAP_OBSENSOR_IR_IMAGE))
{
normalize(irMap, irMapNorm, 0, 255, NORM_MINMAX, CV_8UC1);
applyColorMap(irMapNorm, irMapNorm, COLORMAP_JET);
imshow(“IR Map”, irMapNorm); }
}
The issue is that obsensorCapture.retrieve(irMap, CAP_OBSENSOR_IR_IMAGE) is never true.

IR works with your SDK sample
OrbbecSDK_C_C++_v1.5.7_20230307_7093b5158_win_x64_release\Example\cpp\Sample-InfraredViewer
Probably some initializations are missing
Like seen in your example
pipe.getDevice()->setIntProperty(OB_PROP_IR_CHANNEL_DATA_SOURCE_INT, 0);
pipe.getDevice()->setBoolProperty(OB_PROP_IR_MIRROR_BOOL, true);

Is there a way to implement those in opencv alone ?

Thanks
Eyal

Succeeded to work with cv::obsensorCapture on depth and using pipe for ir
Seen offset in location of depth image vs the ir image.
Question is should they be aligned ?
Tried to use 2 pipes : 1 for ir and 1 for depth.
Each one works separately but when trying to run them together not.
can I use 2 pipes for the same device ?
Thanks
Eyal