From f05166ae26eb8165f35e8205b59c36e618d179b8 Mon Sep 17 00:00:00 2001 From: Adeeb Shihadeh Date: Mon, 13 Jun 2022 13:58:22 -0700 Subject: [PATCH] ui.py: update for nv12 --- tools/replay/ui.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/replay/ui.py b/tools/replay/ui.py index 1807fb7747..bbcd49061e 100755 --- a/tools/replay/ui.py +++ b/tools/replay/ui.py @@ -118,7 +118,7 @@ def ui_thread(addr): imgff = np.frombuffer(yuv_img_raw, dtype=np.uint8).reshape((vipc_client.height * 3 // 2, vipc_client.width)) num_px = vipc_client.width * vipc_client.height - bgr = cv2.cvtColor(imgff, cv2.COLOR_YUV2RGB_I420) + bgr = cv2.cvtColor(imgff, cv2.COLOR_YUV2RGB_NV12) zoom_matrix = _BB_TO_FULL_FRAME[num_px] cv2.warpAffine(bgr, zoom_matrix[:2], (img.shape[1], img.shape[0]), dst=img, flags=cv2.WARP_INVERSE_MAP)