From f625c00f5a3bea9519c81f0ab6c91cdf11ec0828 Mon Sep 17 00:00:00 2001 From: Anton Karpov Date: Wed, 5 Aug 2026 15:48:52 +0300 Subject: [PATCH] dnn: fix the parameter names documented for memset The four memset overloads in cuda4dnn document their first parameter as src while it is called dest, and the directions are the wrong way round: the output buffer is marked [in] and the 8-bit fill value is marked [out]. The prose above two of them already says dest, only the tags disagree. --- modules/dnn/src/cuda4dnn/csl/memory.hpp | 8 ++++---- modules/dnn/src/cuda4dnn/csl/pointer.hpp | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/modules/dnn/src/cuda4dnn/csl/memory.hpp b/modules/dnn/src/cuda4dnn/csl/memory.hpp index 683ed62059..5477716f37 100644 --- a/modules/dnn/src/cuda4dnn/csl/memory.hpp +++ b/modules/dnn/src/cuda4dnn/csl/memory.hpp @@ -178,8 +178,8 @@ namespace cv { namespace dnn { namespace cuda4dnn { namespace csl { /** sets device memory block to a specific 8-bit value * - * \param[in] src device pointer - * \param[out] ch 8-bit value to fill the device memory with + * \param[out] dest device pointer + * \param[in] ch 8-bit value to fill the device memory with * * Exception Guarantee: Basic */ @@ -243,8 +243,8 @@ namespace cv { namespace dnn { namespace cuda4dnn { namespace csl { /** sets device memory block to a specific 8-bit value asynchronously * - * \param[in] src device pointer - * \param[out] ch 8-bit value to fill the device memory with + * \param[out] dest device pointer + * \param[in] ch 8-bit value to fill the device memory with * \param stream CUDA stream that has to be used for the memory operation * * Exception Guarantee: Basic diff --git a/modules/dnn/src/cuda4dnn/csl/pointer.hpp b/modules/dnn/src/cuda4dnn/csl/pointer.hpp index 4d7a232093..b2275dc8db 100644 --- a/modules/dnn/src/cuda4dnn/csl/pointer.hpp +++ b/modules/dnn/src/cuda4dnn/csl/pointer.hpp @@ -307,8 +307,8 @@ namespace cv { namespace dnn { namespace cuda4dnn { namespace csl { /** sets \p n elements to \p ch in \p dest * - * \param[in] src device pointer - * \param[out] ch 8-bit value to fill the device memory with + * \param[out] dest device pointer + * \param[in] ch 8-bit value to fill the device memory with * * Pre-conditions: * - memory pointed by \p dest must be large enough to hold \p n elements @@ -388,8 +388,8 @@ namespace cv { namespace dnn { namespace cuda4dnn { namespace csl { /** sets \p n elements to \p ch in \p dest asynchronously * - * \param[in] src device pointer - * \param[out] ch 8-bit value to fill the device memory with + * \param[out] dest device pointer + * \param[in] ch 8-bit value to fill the device memory with * \param stream CUDA stream that has to be used for the memory operation * * Pre-conditions: