diff --git a/modules/gpu/include/opencv2/gpu/gpu.hpp b/modules/gpu/include/opencv2/gpu/gpu.hpp index 5ff90c9b23..29be204b6a 100644 --- a/modules/gpu/include/opencv2/gpu/gpu.hpp +++ b/modules/gpu/include/opencv2/gpu/gpu.hpp @@ -829,9 +829,9 @@ namespace cv // It queries current active device. static bool checkIfGpuCallReasonable(); + int preset; int ndisp; int winSize; - int preset; // If avergeTexThreshold == 0 => post procesing is disabled // If avergeTexThreshold != 0 then disparity is set 0 in each point (x,y) where for left image diff --git a/modules/gpu/src/color.cpp b/modules/gpu/src/color.cpp index e6be16f265..dc022f437e 100644 --- a/modules/gpu/src/color.cpp +++ b/modules/gpu/src/color.cpp @@ -351,8 +351,7 @@ namespace case CV_XYZ2BGR: case CV_XYZ2RGB: { - typedef void (*func_t)(const DevMem2D& src, int srccn, const DevMem2D& dst, int dstcn, - const void* coeffs, cudaStream_t stream); + typedef void (*func_t)(const DevMem2D& src, int srccn, const DevMem2D& dst, int dstcn, const void* coeffs, cudaStream_t stream); static const func_t funcs[] = {color::XYZ2RGB_gpu_8u, 0, color::XYZ2RGB_gpu_16u, 0, 0, color::XYZ2RGB_gpu_32f}; if (dcn <= 0) dcn = 3; @@ -392,7 +391,7 @@ namespace dst.create(sz, CV_MAKETYPE(depth, dcn)); - const void* coeffs = depth == CV_32F ? (void*)coeffs_f : (void*)coeffs_i; + //const void* coeffs = depth == CV_32F ? (void*)coeffs_f : (void*)coeffs_i; funcs[depth](src, scn, dst, dcn, coeffs_i, stream); break; diff --git a/modules/gpu/src/error.cpp b/modules/gpu/src/error.cpp index c699ed33d7..df4bc17a87 100644 --- a/modules/gpu/src/error.cpp +++ b/modules/gpu/src/error.cpp @@ -67,7 +67,10 @@ namespace error_entry( NPP_NOT_SUPPORTED_MODE_ERROR ), error_entry( NPP_ROUND_MODE_NOT_SUPPORTED_ERROR ), error_entry( NPP_RESIZE_NO_OPERATION_ERROR ), + +#if defined (_MSC_VER) error_entry( NPP_NOT_SUFFICIENT_COMPUTE_CAPABILITY ), +#endif error_entry( NPP_BAD_ARG_ERROR ), error_entry( NPP_LUT_NUMBER_OF_LEVELS_ERROR ), error_entry( NPP_TEXTURE_BIND_ERROR ), @@ -153,4 +156,4 @@ namespace cv } } -#endif \ No newline at end of file +#endif diff --git a/modules/gpu/src/hog.cpp b/modules/gpu/src/hog.cpp index ad4b66e218..5f5ccc4f04 100644 --- a/modules/gpu/src/hog.cpp +++ b/modules/gpu/src/hog.cpp @@ -313,7 +313,7 @@ void cv::gpu::HOGDescriptor::detectMultiScale(const GpuMat& img, vector& f for (size_t i = 0; i < level_scale.size(); i++) { double scale = level_scale[i]; - Size sz = Size_(img.size()) * (1.0/scale); + Size sz(img.cols/scale, img.rows/scale); GpuMat smaller_img; if (sz == img.size()) @@ -328,10 +328,9 @@ void cv::gpu::HOGDescriptor::detectMultiScale(const GpuMat& img, vector& f } detect(smaller_img, locations, hit_threshold, win_stride, padding); - Size scaled_win_size = Size_(win_size) * scale; + Size scaled_win_size(win_size.width * scale, win_size.height * scale); for (size_t j = 0; j < locations.size(); j++) - all_candidates.push_back(Rect(Point2d(locations[j]) * scale, - scaled_win_size)); + all_candidates.push_back(Rect(Point2d((CvPoint)locations[j]) * scale, scaled_win_size)); } found_locations.assign(all_candidates.begin(), all_candidates.end()); @@ -1509,4 +1508,4 @@ std::vector cv::gpu::HOGDescriptor::getPeopleDetector_64x128() return vector(detector, detector + sizeof(detector)/sizeof(detector[0])); } -#endif \ No newline at end of file +#endif