fixed texture binding and warning on linux
This commit is contained in:
parent
40273e6c4f
commit
a2950d5d44
@ -165,7 +165,7 @@ namespace cv { namespace gpu { namespace impl
|
|||||||
grid.y = divUp(src.rows, threads.y);
|
grid.y = divUp(src.rows, threads.y);
|
||||||
|
|
||||||
cudaChannelFormatDesc desc = cudaCreateChannelDesc<uchar4>();
|
cudaChannelFormatDesc desc = cudaCreateChannelDesc<uchar4>();
|
||||||
cudaSafeCall( cudaBindTexture2D( 0, tex_meanshift, src.ptr, desc, src.cols * 4, src.rows, src.step ) );
|
cudaSafeCall( cudaBindTexture2D( 0, tex_meanshift, src.ptr, desc, src.cols, src.rows, src.step ) );
|
||||||
|
|
||||||
meanshift_kernel<<< grid, threads >>>( dst.ptr, dst.step, dst.cols, dst.rows, sp, sr, maxIter, eps );
|
meanshift_kernel<<< grid, threads >>>( dst.ptr, dst.step, dst.cols, dst.rows, sp, sr, maxIter, eps );
|
||||||
cudaSafeCall( cudaThreadSynchronize() );
|
cudaSafeCall( cudaThreadSynchronize() );
|
||||||
|
@ -73,7 +73,7 @@ cv::gpu::StereoBM_GPU::StereoBM_GPU()
|
|||||||
: preset(BASIC_PRESET), ndisp(DEFAULT_NDISP), winSize(DEFAULT_WINSZ), avergeTexThreshold(defaultAvgTexThreshold) {}
|
: preset(BASIC_PRESET), ndisp(DEFAULT_NDISP), winSize(DEFAULT_WINSZ), avergeTexThreshold(defaultAvgTexThreshold) {}
|
||||||
|
|
||||||
cv::gpu::StereoBM_GPU::StereoBM_GPU(int preset_, int ndisparities_, int winSize_)
|
cv::gpu::StereoBM_GPU::StereoBM_GPU(int preset_, int ndisparities_, int winSize_)
|
||||||
: preset(preset_), ndisp(ndisparities_), winSize(winSize_), avergeTexThreshold(defaultAvgTexThreshold)
|
: ndisp(ndisparities_), winSize(winSize_), preset(preset_), avergeTexThreshold(defaultAvgTexThreshold)
|
||||||
{
|
{
|
||||||
const int max_supported_ndisp = 1 << (sizeof(unsigned char) * 8);
|
const int max_supported_ndisp = 1 << (sizeof(unsigned char) * 8);
|
||||||
CV_Assert(0 < ndisp && ndisp <= max_supported_ndisp);
|
CV_Assert(0 < ndisp && ndisp <= max_supported_ndisp);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user