From e0b9355aa8659934aef86bb22e0b7d7e082b85f1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niels=20M=C3=B6ller?= Date: Fri, 5 Apr 2019 14:44:10 +0200 Subject: [PATCH] Move enum VideoType out of common_types.h New location is common_video/libyuv/include/webrtc_libyuv.h. Bug: webrtc:5876 Change-Id: Ied439a83417008a086bd496a8d13042398ff1e99 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/131330 Reviewed-by: Karl Wiberg Commit-Queue: Niels Moller Cr-Commit-Position: refs/heads/master@{#27478} --- common_types.h | 21 ------------------- common_video/BUILD.gn | 1 - common_video/libyuv/include/webrtc_libyuv.h | 20 +++++++++++++++++- modules/video_capture/video_capture_defines.h | 1 + 4 files changed, 20 insertions(+), 23 deletions(-) diff --git a/common_types.h b/common_types.h index f93769c8d6..fb677d67bb 100644 --- a/common_types.h +++ b/common_types.h @@ -142,27 +142,6 @@ enum { kRtpCsrcSize = 15 }; // RFC 3550 page 13 // Video specific types // ================================================================== -// TODO(nisse): Delete, and switch to fourcc values everywhere? -// Supported video types. -enum class VideoType { - kUnknown, - kI420, - kIYUV, - kRGB24, - kABGR, - kARGB, - kARGB4444, - kRGB565, - kARGB1555, - kYUY2, - kYV12, - kUYVY, - kMJPEG, - kNV21, - kNV12, - kBGRA, -}; - // TODO(magjed): Move this and other H264 related classes out to their own file. namespace H264 { diff --git a/common_video/BUILD.gn b/common_video/BUILD.gn index fdc586f09f..86b660487b 100644 --- a/common_video/BUILD.gn +++ b/common_video/BUILD.gn @@ -39,7 +39,6 @@ rtc_static_library("common_video") { ] deps = [ - "..:webrtc_common", "../api:scoped_refptr", "../api/task_queue", "../api/video:encoded_image", diff --git a/common_video/libyuv/include/webrtc_libyuv.h b/common_video/libyuv/include/webrtc_libyuv.h index c8c6726a97..80615f3e7e 100644 --- a/common_video/libyuv/include/webrtc_libyuv.h +++ b/common_video/libyuv/include/webrtc_libyuv.h @@ -22,10 +22,28 @@ #include "api/scoped_refptr.h" #include "api/video/video_frame.h" #include "api/video/video_frame_buffer.h" -#include "common_types.h" // NOLINT(build/include) namespace webrtc { +enum class VideoType { + kUnknown, + kI420, + kIYUV, + kRGB24, + kABGR, + kARGB, + kARGB4444, + kRGB565, + kARGB1555, + kYUY2, + kYV12, + kUYVY, + kMJPEG, + kNV21, + kNV12, + kBGRA, +}; + // This is the max PSNR value our algorithms can return. const double kPerfectPSNR = 48.0f; diff --git a/modules/video_capture/video_capture_defines.h b/modules/video_capture/video_capture_defines.h index f69d03ed70..95747a4e43 100644 --- a/modules/video_capture/video_capture_defines.h +++ b/modules/video_capture/video_capture_defines.h @@ -12,6 +12,7 @@ #define MODULES_VIDEO_CAPTURE_VIDEO_CAPTURE_DEFINES_H_ #include "api/video/video_frame.h" +#include "common_video/libyuv/include/webrtc_libyuv.h" #include "modules/include/module_common_types.h" namespace webrtc {