Commit cac2e9bc authored by Anatoly Baksheev's avatar Anatoly Baksheev

compilation errors under GCC

parent d661b8e3
...@@ -95,17 +95,17 @@ namespace cv ...@@ -95,17 +95,17 @@ namespace cv
__CV_GPU_HOST_DEVICE__ T* ptr(int y = 0) { return (T*)( (char*)data + y * step); } __CV_GPU_HOST_DEVICE__ T* ptr(int y = 0) { return (T*)( (char*)data + y * step); }
__CV_GPU_HOST_DEVICE__ const T* ptr(int y = 0) const { return (const T*)( (const char*)data + y * step); } __CV_GPU_HOST_DEVICE__ const T* ptr(int y = 0) const { return (const T*)( (const char*)data + y * step); }
}; };
template <bool> struct StaticCheck;
template <> struct StaticCheck<true>{};
template<typename T> struct PtrElemStep_ : public PtrStep_<T> template<typename T> struct PtrElemStep_ : public PtrStep_<T>
{ {
PtrElemStep_(const DevMem2D_<T>& mem) : PtrStep_<T>(mem) PtrElemStep_(const DevMem2D_<T>& mem) : PtrStep_<T>(mem)
{ {
step /= elem_size; this->step /= PtrStep_<T>::elem_size;
} }
private: private:
template <bool> struct StaticCheck;
template <> struct StaticCheck<true>{};
StaticCheck<256 % sizeof(T) == 0> ElemStepTypeCheck; StaticCheck<256 % sizeof(T) == 0> ElemStepTypeCheck;
}; };
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment