Ocean
Loading...
Searching...
No Matches
TestCVDetectorQRCodes.h
Go to the documentation of this file.
1/*
2 * Copyright (c) Meta Platforms, Inc. and affiliates.
3 *
4 * This source code is licensed under the MIT license found in the
5 * LICENSE file in the root directory of this source tree.
6 */
7
8#pragma once
9
11
12namespace Ocean
13{
14
15namespace Test
16{
17
18namespace TestCV
19{
20
21namespace TestDetector
22{
23
24namespace TestQRCodes
25{
26
27/**
28 * @ingroup testcvdetector
29 * @defgroup testcvdetectorqrcodes Ocean Test CV Detector QR Codes Library
30 * @{
31 * The Ocean Test CV Detector QR Codes Library provides several functions to test the performance and validation of the QR code detection and generation functionalities.
32 * The library is platform independent.
33 * @}
34 */
35
36/**
37 * @namespace Ocean::Test::TestCV::TestDetector::TestQRCodes Namespace of the CV Detector QR Codes Test library.<p>
38 * The Namespace Ocean::Test::TestCV::TestDetector::TestQRCodes is used in the entire Ocean CV Detector QR Codes Test Library.
39 */
40
41// Defines OCEAN_TEST_CV_DETECTOR_QRCODES_EXPORT for dll export and import.
42#if defined(_WINDOWS) && defined(OCEAN_RUNTIME_SHARED)
43 #ifdef USE_OCEAN_TEST_CV_DETECTOR_QRCODES_EXPORT
44 #define OCEAN_TEST_CV_DETECTOR_QRCODES_EXPORT __declspec(dllexport)
45 #else
46 #define OCEAN_TEST_CV_DETECTOR_QRCODES_EXPORT __declspec(dllimport)
47 #endif
48#else
49 #define OCEAN_TEST_CV_DETECTOR_QRCODES_EXPORT
50#endif
51
52/**
53 * Tests the entire Computer Vision Detector QR Codes library.
54 * @param testDuration Number of seconds for each test, with range (0, infinity)
55 * @param worker The worker object to distribute some computation on as many CPU cores as defined in the worker object.
56 * @param testFunctions Optional name of the functions to be tested
57 * @return True, if the entire test succeeded
58 * @ingroup testcvdetector
59 */
60OCEAN_TEST_CV_DETECTOR_QRCODES_EXPORT bool testCVDetectorQRCodes(const double testDuration, Worker& worker, const std::string& testFunctions = "");
61
62/**
63 * Tests the entire Computer Vision Detector QR Codes library.
64 * This function returns directly as the actual test is invoked in an own thread.<br>
65 * Use this function in intended for non-console applications like e.g., mobile devices.
66 * @param testDuration Number of seconds for each test, with range (0, infinity)
67 * @param testFunctions Optional name of the functions to be tested
68 * @ingroup testcvdetector
69 */
70OCEAN_TEST_CV_DETECTOR_QRCODES_EXPORT void testCVDetectorQRCodesAsynchronous(const double testDuration, const std::string& testFunctions = "");
71
72} // namespace TestQRCodes
73
74} // namespace TestDetector
75
76} // namespace TestCV
77
78} // namespace Test
79
80} // namespace Test
This class implements a worker able to distribute function calls over different threads.
Definition Worker.h:33
OCEAN_TEST_CV_DETECTOR_QRCODES_EXPORT void testCVDetectorQRCodesAsynchronous(const double testDuration, const std::string &testFunctions="")
Tests the entire Computer Vision Detector QR Codes library.
OCEAN_TEST_CV_DETECTOR_QRCODES_EXPORT bool testCVDetectorQRCodes(const double testDuration, Worker &worker, const std::string &testFunctions="")
Tests the entire Computer Vision Detector QR Codes library.
The namespace covering the entire Ocean framework.
Definition Accessor.h:15