|
|
|
@ -82,8 +82,8 @@ typedef unsigned char uchar; |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
template<int FACTOR> |
|
|
|
|
__global__ void shrink(const uchar* __restrict__ hogluv, const int inPitch, |
|
|
|
|
uchar* __restrict__ shrank, const int outPitch ) |
|
|
|
|
__global__ void shrink(const uchar* __restrict__ hogluv, const size_t inPitch, |
|
|
|
|
uchar* __restrict__ shrank, const size_t outPitch ) |
|
|
|
|
{ |
|
|
|
|
const int y = blockIdx.y * blockDim.y + threadIdx.y; |
|
|
|
|
const int x = blockIdx.x * blockDim.x + threadIdx.x; |
|
|
|
@ -127,7 +127,7 @@ typedef unsigned char uchar; |
|
|
|
|
__v = static_cast<uchar>((V + 140.f) * (255.f / (122.f + 140.f ))); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
__global__ void bgr2Luv_d(const uchar* rgb, const int rgbPitch, uchar* luvg, const int luvgPitch) |
|
|
|
|
__global__ void bgr2Luv_d(const uchar* rgb, const size_t rgbPitch, uchar* luvg, const size_t luvgPitch) |
|
|
|
|
{ |
|
|
|
|
const int y = blockIdx.y * blockDim.y + threadIdx.y; |
|
|
|
|
const int x = blockIdx.x * blockDim.x + threadIdx.x; |
|
|
|
@ -256,8 +256,8 @@ typedef unsigned char uchar; |
|
|
|
|
|
|
|
|
|
// ToDo: use textures or uncached load instruction. |
|
|
|
|
__global__ void magToHist(const uchar* __restrict__ mag, |
|
|
|
|
const float* __restrict__ angle, const int angPitch, |
|
|
|
|
uchar* __restrict__ hog, const int hogPitch, const int fh) |
|
|
|
|
const float* __restrict__ angle, const size_t angPitch, |
|
|
|
|
uchar* __restrict__ hog, const size_t hogPitch, const int fh) |
|
|
|
|
{ |
|
|
|
|
const int y = blockIdx.y * blockDim.y + threadIdx.y; |
|
|
|
|
const int x = blockIdx.x * blockDim.x + threadIdx.x; |
|
|
|
|