Add YuvImage as a GpuBuffer storage backend.

PiperOrigin-RevId: 505128789
This commit is contained in:
MediaPipe Team
2023-01-27 08:51:31 -08:00
committed by Copybara-Service
parent e059d55d29
commit 1df4511e9d
3 changed files with 45 additions and 0 deletions
+29
View File
@@ -441,6 +441,21 @@ cc_library(
],
)
cc_library(
name = "gpu_buffer_storage_yuv_image",
srcs = ["gpu_buffer_storage_yuv_image.cc"],
hdrs = ["gpu_buffer_storage_yuv_image.h"],
visibility = ["//visibility:public"],
deps = [
":gpu_buffer_format",
":gpu_buffer_storage",
"//mediapipe/framework/formats:yuv_image",
"//third_party/libyuv",
"@com_google_absl//absl/log",
"@com_google_absl//absl/log:check",
],
)
cc_library(
name = "gpu_buffer_storage_ahwb",
srcs = ["gpu_buffer_storage_ahwb.cc"],
@@ -1187,3 +1202,17 @@ mediapipe_cc_test(
"//mediapipe/framework/port:gtest_main",
],
)
mediapipe_cc_test(
name = "gpu_buffer_storage_yuv_image_test",
size = "small",
srcs = ["gpu_buffer_storage_yuv_image_test.cc"],
exclude_platforms = [
"ios",
],
deps = [
":gpu_buffer_format",
":gpu_buffer_storage_yuv_image",
"//mediapipe/framework/port:gtest_main",
],
)