Continuing the discussion from NvSciBufObjGetPixels is too slow to get yuv420 frames by 30fps:
Please provide the following info (tick the boxes after creating this topic):
Software Version
DRIVE OS 6.0.8.1
[yes] DRIVE OS 6.0.6
DRIVE OS 6.0.5
DRIVE OS 6.0.4 (rev. 1)
DRIVE OS 6.0.4 SDK
other
Target Operating System
Linux
QNX
other
Hardware Platform
DRIVE AGX Orin Developer Kit (940-63710-0010-300)
DRIVE AGX Orin Developer Kit (940-63710-0010-200)
DRIVE AGX Orin Developer Kit (940-63710-0010-100)
DRIVE AGX Orin Developer Kit (940-63710-0010-D00)
DRIVE AGX Orin Developer Kit (940-63710-0010-C00)
[yes] DRIVE AGX Orin Developer Kit (not sure its number)
other
SDK Manager Version
1.9.3.10904
other
Host Machine Version
native Ubuntu Linux 20.04 Host installed with SDK Manager
[yes] native Ubuntu Linux 20.04 Host installed with DRIVE OS Docker Containers
native Ubuntu Linux 18.04 Host installed with DRIVE OS Docker Containers
other
Hi there, i also found that NVSCIBufObjGetPixels is too slow to get ISP0/1/2 frames… so i tried to use NVSCIBufObjGetPixels to get VA addr and dump this buf. As a result, I’ve noticed that I can’t play this yuv image correctly, so I’m wondering how the data is aligned.
my setting:
sensor input is raw12:height:2168, width:3840, embedded_top =4 ,embedded_bottom=4,
ICP Buf :output align height: 2168 ,output height: 2168, output width: 3840, output pitch: 7680,output BPP: 16
ISP0 Buf:height:2160, width:3840, output align height: 2176, output height: 2160, output width: 3840, output pitch: 3840, output padding: top 0, bottom 0,output BPP: 8,
numbersuface[0]:width:3840, height:2160, align_height:2176, xScalePtr:1, yScalePtr:1, bytesPerPixelPtr:1,align_size:8355840, pBuffPitches0:3840
numbersuface[1]:width:3840, height:2160, align_height:2176, xScalePtr:0.5, yScalePtr:0.5, bytesPerPixelPtr:1,align_size:2088960, pBuffPitches1:1920
numbersuface[2]:width:3840, height:2160, align_height:2176, xScalePtr:0.5, yScalePtr:0.5, bytesPerPixelPtr:1,align_size:2088960, pBuffPitches2:1920
//ISP0 Buf:image_ptr
void const *image_ptr = nullptr;
sciErr = NvSciBufObjGetConstCpuPtr(bufPtr, &image_ptr);
CHK_NVSCISTATUS_AND_RETURN(sciErr, "NvSciBufObjGetConstCpuPtr Failed");
uint8_t *nvbuf_image_ptr =
reinterpret_cast<uint8_t *>(const_cast<void *>(image_ptr));
align_size[0] = (width * xScalePtr[0] * align_height * yScalePtr[0] *
bytesPerPixelPtr[0]); //3840×2176=8355840
fwrite(nvbuf_image_ptr, 1, align_size[0], m_pOutFile); //align_size[0] =8355840
but when i dump Y part which size is 8355840 , i got a disordered image, so i want to know if my method is correct? if not, what's the correct method to get a yuv image? Thanks!
isp_yuv.yuv.txt (8.0 MB)