Commit db3d7e85 authored by Alexander Alekhin's avatar Alexander Alekhin

Merge pull request #1692 from alalek:build_eliminate_gcc8_warnings

parents e7aa0aa2 b9d83609
......@@ -237,7 +237,8 @@ public:
if (p.y >= size.height)
p.y = size.height - 1;
memcpy(&samples[i * stride + j * nSamples], &bm.samples[p.y * stride + p.x * nSamples], sizeof(BackgroundSampleType) * nSamples);
for (int k = 0; k < nSamples; k++)
samples[i * stride + j * nSamples + k] = bm.samples[p.y * stride + p.x * nSamples + k];
}
}
......
......@@ -294,7 +294,7 @@ int main(int argc, char* argv[])
*/
cv::waitKey(10);
}
}catch(cv::Exception e)
} catch(const cv::Exception& e)
{
std::cerr<<"Error using Retina : "<<e.what()<<std::endl;
}
......
......@@ -994,8 +994,8 @@ static void spread(const Mat& src, Mat& dst, int T)
int height = src.rows - r;
for (int c = 0; c < T; ++c)
{
orUnaligned8u(&src.at<unsigned char>(r, c), static_cast<const int>(src.step1()), dst.ptr(),
static_cast<const int>(dst.step1()), src.cols - c, height);
orUnaligned8u(&src.at<unsigned char>(r, c), static_cast<int>(src.step1()), dst.ptr(),
static_cast<int>(dst.step1()), src.cols - c, height);
}
}
}
......
......@@ -4,5 +4,8 @@ include(CMake/Installation.cmake)
set(BUILD_SHARED_LIBS OFF) # Force static libs for 3rdparty dependencies
ocv_warnings_disable(CMAKE_CXX_FLAGS -Winconsistent-missing-override -Wsuggest-override)
if(CV_GCC AND CMAKE_CXX_COMPILER_VERSION VERSION_GREATER 8.0)
ocv_warnings_disable(CMAKE_CXX_FLAGS -Wclass-memaccess)
endif()
add_subdirectory(libmv)
\ No newline at end of file
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