aboutsummaryrefslogtreecommitdiff
path: root/devel/electron29/files/patch-media_video_video__encode__accelerator__adapter.cc
diff options
context:
space:
mode:
Diffstat (limited to 'devel/electron29/files/patch-media_video_video__encode__accelerator__adapter.cc')
-rw-r--r--devel/electron29/files/patch-media_video_video__encode__accelerator__adapter.cc20
1 files changed, 20 insertions, 0 deletions
diff --git a/devel/electron29/files/patch-media_video_video__encode__accelerator__adapter.cc b/devel/electron29/files/patch-media_video_video__encode__accelerator__adapter.cc
new file mode 100644
index 000000000000..ec5be64bc0e6
--- /dev/null
+++ b/devel/electron29/files/patch-media_video_video__encode__accelerator__adapter.cc
@@ -0,0 +1,20 @@
+--- media/video/video_encode_accelerator_adapter.cc.orig 2024-02-21 00:20:49 UTC
++++ media/video/video_encode_accelerator_adapter.cc
+@@ -154,7 +154,7 @@ VideoEncodeAccelerator::Config SetUpVeaConfig(
+ if (is_rgb)
+ config.input_format = PIXEL_FORMAT_I420;
+
+-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)
++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)
+ if (format != PIXEL_FORMAT_I420 ||
+ !VideoFrame::IsStorageTypeMappable(storage_type)) {
+ // ChromeOS/Linux hardware video encoders supports I420 on-memory
+@@ -479,7 +479,7 @@ void VideoEncodeAcceleratorAdapter::InitializeInternal
+ SetUpVeaConfig(profile_, options_, format, first_frame->storage_type(),
+ supported_rc_modes_, required_encoder_type_);
+
+-#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS)
++#if BUILDFLAG(IS_LINUX) || BUILDFLAG(IS_CHROMEOS) || BUILDFLAG(IS_BSD)
+ // Linux/ChromeOS require a special configuration to use dmabuf storage.
+ // We need to keep sending frames the same way the first frame was sent.
+ // Other platforms will happily mix GpuMemoryBuffer storage with regular