From 1fab84cd461e061b70e492534b91a4025f68e324 Mon Sep 17 00:00:00 2001 From: Dean Lee Date: Thu, 11 Mar 2021 22:01:44 +0800 Subject: [PATCH] LapConv::Update: use CL_TRUE instead of true (#20311) old-commit-hash: 8abc85ea5ebbdd74416c981cbd82f3207fbf47fc --- selfdrive/camerad/imgproc/utils.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/selfdrive/camerad/imgproc/utils.cc b/selfdrive/camerad/imgproc/utils.cc index 466c29dc65..5e04a27cd3 100644 --- a/selfdrive/camerad/imgproc/utils.cc +++ b/selfdrive/camerad/imgproc/utils.cc @@ -89,7 +89,7 @@ uint16_t LapConv::Update(cl_command_queue q, const uint8_t *rgb_buf, const int r const size_t global_work_size[] = {(size_t)width, (size_t)height}; const size_t local_work_size[] = {CONV_LOCAL_WORKSIZE, CONV_LOCAL_WORKSIZE}; - CL_CHECK(clEnqueueWriteBuffer(q, roi_cl, true, 0, roi_buf.size() * sizeof(roi_buf[0]), roi_buf.data(), 0, 0, 0)); + CL_CHECK(clEnqueueWriteBuffer(q, roi_cl, CL_TRUE, 0, roi_buf.size() * sizeof(roi_buf[0]), roi_buf.data(), 0, 0, 0)); CL_CHECK(clSetKernelArg(krnl, 0, sizeof(cl_mem), (void *)&roi_cl)); CL_CHECK(clSetKernelArg(krnl, 1, sizeof(cl_mem), (void *)&result_cl)); CL_CHECK(clSetKernelArg(krnl, 2, sizeof(cl_mem), (void *)&filter_cl)); @@ -98,7 +98,7 @@ uint16_t LapConv::Update(cl_command_queue q, const uint8_t *rgb_buf, const int r CL_CHECK(clEnqueueNDRangeKernel(q, krnl, 2, NULL, global_work_size, local_work_size, 0, 0, &conv_event)); CL_CHECK(clWaitForEvents(1, &conv_event)); CL_CHECK(clReleaseEvent(conv_event)); - CL_CHECK(clEnqueueReadBuffer(q, result_cl, true, 0, + CL_CHECK(clEnqueueReadBuffer(q, result_cl, CL_TRUE, 0, result_buf.size() * sizeof(result_buf[0]), result_buf.data(), 0, 0, 0)); return get_lapmap_one(result_buf.data(), width, height);