#include <cuda.h>
#include <cuda_runtime.h>
#include <cutil.h>
Functions | |
| void | LKCudaInit (unsigned nLevels, unsigned width, unsigned height) |
| initialization function. function that allocates all cuda arrays needed, according to the level number and the image resolution. | |
| void | LKCudaRun (cudaArray *image1, cudaArray *image2, cudaArray *vX, cudaArray *vY, unsigned nIter, unsigned win, float alpha, bool cc) |
| Lucas & Kanade optical flow computation. | |
| void | LKCudaFree () |
| memory free. | |
| void LKCudaInit | ( | unsigned | nLevels, | |
| unsigned | width, | |||
| unsigned | height | |||
| ) |
initialization function. function that allocates all cuda arrays needed, according to the level number and the image resolution.
| nLevels | number of level (pyramid size), at least equals to 1. | |
| width | width of input images. | |
| height | height of input images. |
| void LKCudaRun | ( | cudaArray * | image1, | |
| cudaArray * | image2, | |||
| cudaArray * | vX, | |||
| cudaArray * | vY, | |||
| unsigned | nIter, | |||
| unsigned | win, | |||
| float | alpha, | |||
| bool | cc | |||
| ) |
Lucas & Kanade optical flow computation.
| image1 | pointer to the first image stored on the GPU. | |
| image2 | pointer to the second image stored on the GPU. | |
| vX | pointer to the x-velocities on CUDA array. | |
| vY | pointer to the y-velocities on CUDA array. | |
| nIter | iteration number. | |
| win | patch size. | |
| alpha | regularization parameter, typically 0.00001f. | |
| cc | if different to 0 vX and vY are used to init the first pyramid level. |
1.5.6