perf_undistort.cpp 954 B

123456789101112131415161718192021222324252627282930
  1. // This file is part of OpenCV project.
  2. // It is subject to the license terms in the LICENSE file found in the top-level directory
  3. // of this distribution and at http://opencv.org/license.html
  4. #include "perf_precomp.hpp"
  5. namespace opencv_test {
  6. PERF_TEST(Undistort, InitUndistortMap)
  7. {
  8. Size size_w_h(512 + 3, 512);
  9. Mat k(3, 3, CV_32FC1);
  10. Mat d(1, 14, CV_64FC1);
  11. Mat dst(size_w_h, CV_32FC2);
  12. declare.in(k, d, WARMUP_RNG).out(dst);
  13. TEST_CYCLE() initUndistortRectifyMap(k, d, noArray(), k, size_w_h, CV_32FC2, dst, noArray());
  14. SANITY_CHECK_NOTHING();
  15. }
  16. PERF_TEST(Undistort, DISABLED_InitInverseRectificationMap)
  17. {
  18. Size size_w_h(512 + 3, 512);
  19. Mat k(3, 3, CV_32FC1);
  20. Mat d(1, 14, CV_64FC1);
  21. Mat dst(size_w_h, CV_32FC2);
  22. declare.in(k, d, WARMUP_RNG).out(dst);
  23. TEST_CYCLE() initInverseRectificationMap(k, d, noArray(), k, size_w_h, CV_32FC2, dst, noArray());
  24. SANITY_CHECK_NOTHING();
  25. }
  26. } // namespace