Skip to content

Commit b55bf35

Browse files
committed
Merge branch 4.x
2 parents 6f820b0 + cb495d9 commit b55bf35

File tree

7 files changed

+611
-4
lines changed

7 files changed

+611
-4
lines changed

modules/cudev/test/CMakeLists.txt

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,20 +19,24 @@ if(OCV_DEPENDENCIES_FOUND)
1919
if(NOT ENABLE_CUDA_FIRST_CLASS_LANGUAGE)
2020
ocv_check_windows_crt_linkage()
2121
set(target_libs ${target_libs} ${CUDA_LIBRARIES})
22+
set(test_cudev_cuda_options "")
2223
if(CUDA_VERSION VERSION_LESS "11.0")
2324
# Windows version does not support --std option
2425
if(UNIX OR APPLE)
25-
ocv_update(OPENCV_CUDA_OPTIONS_opencv_test_cudev "-std=c++11")
26+
list(APPEND test_cudev_cuda_options "-std=c++11")
2627
endif()
2728
else()
2829
if(CUDA_VERSION VERSION_LESS "12.8")
29-
ocv_update(OPENCV_CUDA_OPTIONS_opencv_test_cudev "-std=c++14")
30+
list(APPEND test_cudev_cuda_options "-std=c++14")
3031
else()
31-
ocv_update(OPENCV_CUDA_OPTIONS_opencv_test_cudev "-std=c++17")
32+
list(APPEND test_cudev_cuda_options "-std=c++17")
33+
if(WIN32)
34+
list(APPEND test_cudev_cuda_options "-Xcompiler=/Zc:preprocessor")
35+
endif()
3236
endif()
3337
ocv_warnings_disable(CMAKE_CXX_FLAGS -Wdeprecated-declarations)
3438
endif()
35-
CUDA_ADD_EXECUTABLE(${the_target} ${OPENCV_TEST_${the_module}_SOURCES} OPTIONS ${OPENCV_CUDA_OPTIONS_opencv_test_cudev})
39+
CUDA_ADD_EXECUTABLE(${the_target} ${OPENCV_TEST_${the_module}_SOURCES} OPTIONS ${test_cudev_cuda_options})
3640
else()
3741
ocv_add_executable(${the_target} ${OPENCV_TEST_${the_module}_SOURCES})
3842
endif()

modules/fastcv/include/opencv2/fastcv.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@
3737
#include "opencv2/fastcv/fft_dsp.hpp"
3838
#include "opencv2/fastcv/edges_dsp.hpp"
3939
#include "opencv2/fastcv/blur_dsp.hpp"
40+
#include "opencv2/fastcv/color.hpp"
4041

4142
/**
4243
* @defgroup fastcv Module-wrapper for FastCV hardware accelerated functions
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
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+
5+
6+
#ifndef OPENCV_FASTCV_COLOR_HPP
7+
#define OPENCV_FASTCV_COLOR_HPP
8+
9+
#include <opencv2/core.hpp>
10+
11+
namespace cv
12+
{
13+
namespace fastcv
14+
{
15+
16+
enum ColorConversionCodes {
17+
// FastCV-specific color conversion codes (avoid collision with OpenCV core)
18+
COLOR_YUV2YUV444sp_NV12 = 156, //!< FastCV: YCbCr420PseudoPlanar to YCbCr444PseudoPlanar
19+
COLOR_YUV2YUV422sp_NV12 = 157, //!< FastCV: YCbCr420PseudoPlanar to YCbCr422PseudoPlanar
20+
COLOR_YUV422sp2YUV444sp = 158, //!< FastCV: YCbCr422PseudoPlanar to YCbCr444PseudoPlanar
21+
COLOR_YUV422sp2YUV_NV12 = 159, //!< FastCV: YCbCr422PseudoPlanar to YCbCr420PseudoPlanar
22+
COLOR_YUV444sp2YUV422sp = 160, //!< FastCV: YCbCr444PseudoPlanar to YCbCr422PseudoPlanar
23+
COLOR_YUV444sp2YUV_NV12 = 161, //!< FastCV: YCbCr444PseudoPlanar to YCbCr420PseudoPlanar
24+
COLOR_YUV2RGB565_NV12 = 162, //!< FastCV: YCbCr420PseudoPlanar to RGB565
25+
COLOR_YUV422sp2RGB565 = 163, //!< FastCV: YCbCr422PseudoPlanar to RGB565
26+
COLOR_YUV422sp2RGB = 164, //!< FastCV: YCbCr422PseudoPlanar to RGB888
27+
COLOR_YUV422sp2RGBA = 165, //!< FastCV: YCbCr422PseudoPlanar to RGBA8888
28+
COLOR_YUV444sp2RGB565 = 166, //!< FastCV: YCbCr444PseudoPlanar to RGB565
29+
COLOR_YUV444sp2RGB = 167, //!< FastCV: YCbCr444PseudoPlanar to RGB888
30+
COLOR_YUV444sp2RGBA = 168, //!< FastCV: YCbCr444PseudoPlanar to RGBA8888
31+
COLOR_RGB2YUV_NV12 = 169, //!< FastCV: RGB888 to YCbCr420PseudoPlanar
32+
COLOR_RGB5652YUV444sp = 170, //!< FastCV: RGB565 to YCbCr444PseudoPlanar
33+
COLOR_RGB5652YUV422sp = 171, //!< FastCV: RGB565 to YCbCr422PseudoPlanar
34+
COLOR_RGB5652YUV_NV12 = 172, //!< FastCV: RGB565 to YCbCr420PseudoPlanar
35+
COLOR_RGB2YUV444sp = 173, //!< FastCV: RGB888 to YCbCr444PseudoPlanar
36+
COLOR_RGB2YUV422sp = 174, //!< FastCV: RGB888 to YCbCr422PseudoPlanar
37+
};
38+
39+
CV_EXPORTS_W void cvtColor(InputArray src, OutputArray dst, int code);
40+
41+
}}; //cv::fastcv namespace end
42+
43+
#endif // OPENCV_FASTCV_COLOR_HPP

0 commit comments

Comments
 (0)