Ocean
TestFrameConverterYUVA32.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 #ifndef META_OCEAN_TEST_TESTCV_TEST_FRAME_CONVERTER_YUVA_32_H
9 #define META_OCEAN_TEST_TESTCV_TEST_FRAME_CONVERTER_YUVA_32_H
10 
13 
14 #include "ocean/base/Worker.h"
15 
17 
18 namespace Ocean
19 {
20 
21 namespace Test
22 {
23 
24 namespace TestCV
25 {
26 
27 /**
28  * This class implements a YUVA 32 bit frame converter test.
29  * @ingroup testcv
30  */
31 class OCEAN_TEST_CV_EXPORT TestFrameConverterYUVA32
32 {
33  public:
34 
35  /**
36  * Tests all YUVA 32 bit frame conversion functions.
37  * @param width The width of the original frame in pixel, with range [1, infinity)
38  * @param height The height of the original frame in pixel, with range [1, infinity)
39  * @param testDuration Number of seconds for each test, with range (0, infinity)
40  * @param worker The worker object
41  * @return True, if succeeded
42  */
43  static bool test(const unsigned int width, const unsigned int height, const double testDuration, Worker& worker);
44 
45  /**
46  * Tests the YUVA32 to Y8 conversion.
47  * @param width The width of the original frame in pixel, with range [1, infinity)
48  * @param height The height of the original frame in pixel, with range [1, infinity)
49  * @param conversionFlag The conversion flag that has been applied during conversion
50  * @param testDuration Number of seconds for each test, with range (0, infinity)
51  * @param worker The worker object
52  * @return True, if succeeded
53  */
54  static bool testYUVA32ToY8(const unsigned int width, const unsigned int height, const CV::FrameConverter::ConversionFlag conversionFlag, const double testDuration, Worker& worker);
55 };
56 
57 }
58 
59 }
60 
61 }
62 
63 #endif // META_OCEAN_TEST_TESTCV_TEST_FRAME_CONVERTER_YUVA_32_H
ConversionFlag
Definition of individual conversion flags.
Definition: FrameConverter.h:39
This class implements a YUVA 32 bit frame converter test.
Definition: TestFrameConverterYUVA32.h:32
static bool test(const unsigned int width, const unsigned int height, const double testDuration, Worker &worker)
Tests all YUVA 32 bit frame conversion functions.
static bool testYUVA32ToY8(const unsigned int width, const unsigned int height, const CV::FrameConverter::ConversionFlag conversionFlag, const double testDuration, Worker &worker)
Tests the YUVA32 to Y8 conversion.
This class implements a worker able to distribute function calls over different threads.
Definition: Worker.h:33
The namespace covering the entire Ocean framework.
Definition: Accessor.h:15