From 7a70aac0f0e57c7ac3fda5a5ad1e351cf7bbfaf4 Mon Sep 17 00:00:00 2001 From: MediaPipe Team Date: Wed, 20 Nov 2024 01:16:12 -0800 Subject: [PATCH] Delete YUVImage copy and move operations PiperOrigin-RevId: 698298660 --- mediapipe/framework/formats/yuv_image.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/mediapipe/framework/formats/yuv_image.h b/mediapipe/framework/formats/yuv_image.h index 4aeb75d6b0..30a0f303f5 100644 --- a/mediapipe/framework/formats/yuv_image.h +++ b/mediapipe/framework/formats/yuv_image.h @@ -118,6 +118,12 @@ class YUVImage { YUVImage() = default; ~YUVImage() { Clear(); } + // YUVImage is neither copyable nor movable. + YUVImage(const YUVImage&) = delete; + YUVImage& operator=(const YUVImage&) = delete; + YUVImage(YUVImage&&) = delete; + YUVImage& operator=(YUVImage&&) = delete; + // Convenience constructor YUVImage(libyuv::FourCC fourcc, // std::unique_ptr data_location, //