From 52d25baceb0530e5d43a7bc8b4ecba9a4ad5eaf5 Mon Sep 17 00:00:00 2001 From: DepthDeluxe Date: Wed, 10 Feb 2016 16:33:36 -0500 Subject: [PATCH] added README.md for the CUDA plugins folder --- openbr/plugins/cuda/README.md | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+), 0 deletions(-) create mode 100644 openbr/plugins/cuda/README.md diff --git a/openbr/plugins/cuda/README.md b/openbr/plugins/cuda/README.md new file mode 100644 index 0000000..4bd35db --- /dev/null +++ b/openbr/plugins/cuda/README.md @@ -0,0 +1,23 @@ +# CUDA Plugins +This folder contains CUDA-accelerated OpenBR plugins. They are structured in the following format. + +## File Structure +We will use a plugin called `CUDAPlugin` as an example. + +Each plugin has 3 files associated with it: a CUDA file, CPP file, and HPP header file. +``` +cudaplugin.cu +cudaplugin.cpp +cudaplugin.hpp +``` +The `.cu` file contains CUDA kernel functions and the corresponding wrapper functions +that directly call the kernel functions. The `.cpp` files contain the OpenBR +standard plugin declaration. Functions in this file call the wrappers. The `.hpp` +contains header declarations for the CUDA wrapper functions so the `.cpp` file +knows how to call them. + +# CUDA Files +All functions for a particular CUDA plugin are defined in a namespace of that +plugin's name which is defined within `br::cuda` namespace. For example, if +we have a plugin called CUDAPlugin, both wrapper and kernel functions should +be globally defined within `br::cuda::cudaplugin`. -- libgit2 0.21.4