Merge pull request #905 from bitwangyaoyao:2.4_TVL1

This commit is contained in:
Roman Donchenko 2013-05-22 12:08:16 +04:00 committed by OpenCV Buildbot
commit 519ee72f6f
2 changed files with 11 additions and 1 deletions

View File

@ -277,9 +277,15 @@ __kernel void arithm_mul_D6 (__global double *src1, int src1_step, int src1_offs
}
#endif
#ifdef DOUBLE_SUPPORT
#define SCALAR_TYPE double
#else
#define SCALAR_TYPE float
#endif
__kernel void arithm_muls_D5 (__global float *src1, int src1_step, int src1_offset,
__global float *dst, int dst_step, int dst_offset,
int rows, int cols, int dst_step1, float scalar)
int rows, int cols, int dst_step1, SCALAR_TYPE scalar)
{
int x = get_global_id(0);
int y = get_global_id(1);

View File

@ -472,4 +472,8 @@ void ocl_tvl1flow::warpBackward(const oclMat &I0, const oclMat &I1, oclMat &I1x,
args.push_back( make_pair( sizeof(cl_int), (void*)&u2_offset_y));
openCLExecuteKernel(clCxt, &tvl1flow, kernelName, globalThread, localThread, args, -1, -1);
releaseTexture(I1_tex);
releaseTexture(I1x_tex);
releaseTexture(I1y_tex);
}