test_misc.cpp 760 B

123456789101112131415161718192021222324252627
  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 "test_precomp.hpp"
  5. namespace opencv_test { namespace {
  6. TEST(CV_ArucoDrawMarker, regression_1226)
  7. {
  8. int squares_x = 7;
  9. int squares_y = 5;
  10. int bwidth = 1600;
  11. int bheight = 1200;
  12. cv::Ptr<cv::aruco::Dictionary> dict = cv::aruco::getPredefinedDictionary(cv::aruco::DICT_4X4_50);
  13. cv::Ptr<cv::aruco::CharucoBoard> board = cv::aruco::CharucoBoard::create(squares_x, squares_y, 1.0, 0.75, dict);
  14. cv::Size sz(bwidth, bheight);
  15. cv::Mat mat;
  16. ASSERT_NO_THROW(
  17. {
  18. board->draw(sz, mat, 0, 1);
  19. });
  20. }
  21. }} // namespace