From d66ed313cb4afdb02e4b40399986a03e05bcd87a Mon Sep 17 00:00:00 2001 From: ohnozzy Date: Mon, 25 Apr 2016 11:11:50 +0800 Subject: [PATCH] Add Comment Add documentation for Kernel::run --- modules/core/include/opencv2/core/ocl.hpp | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/modules/core/include/opencv2/core/ocl.hpp b/modules/core/include/opencv2/core/ocl.hpp index bc989a3285..fbaebc7dc9 100644 --- a/modules/core/include/opencv2/core/ocl.hpp +++ b/modules/core/include/opencv2/core/ocl.hpp @@ -567,7 +567,18 @@ public: i = set(i, a6); i = set(i, a7); i = set(i, a8); i = set(i, a9); i = set(i, a10); i = set(i, a11); i = set(i, a12); i = set(i, a13); i = set(i, a14); set(i, a15); return *this; } - + /* + Run the OpenCL kernel. + @param dims the work problem dimensions. It is the length of globalsize and localsize. It can be either 1, 2 or 3. + @param globalsize work items for each dimension. + It is not the final globalsize passed to OpenCL. + Each dimension will be adjusted to the nearest integer divisible by the corresponding value in localsize. + If localsize is NULL, it will still be adjusted depending on dims. + The adjusted values are greater than or equal to the original values. + @param localsize work-group size for each dimension. + @param sync specify whether to wait for OpenCL computation to finish before return. + @param q command queue + */ bool run(int dims, size_t globalsize[], size_t localsize[], bool sync, const Queue& q=Queue()); bool runTask(bool sync, const Queue& q=Queue()); -- GitLab