diff options
author | Conrad Meyer <cem@FreeBSD.org> | 2020-04-08 00:22:46 +0000 |
---|---|---|
committer | Conrad Meyer <cem@FreeBSD.org> | 2020-04-08 00:22:46 +0000 |
commit | 2cf32f371d6bad886e491c34d893aad93fcb8d2b (patch) | |
tree | b75c4b8ad71e53930803f3642cfe9c9f56ab333c /www/chromium | |
parent | c89a7d888fe2d08edca19c067f7266524969b5e4 (diff) | |
download | ports-2cf32f371d6bad886e491c34d893aad93fcb8d2b.tar.gz ports-2cf32f371d6bad886e491c34d893aad93fcb8d2b.zip |
www/chromium: Un-remove v4l video capture support
This support was removed in r416521. The revision message did not document the
removal nor justify patching out a major port feature.
This restores that support.
The earlier revision should probably be audited for other patches which (a) add
update burden to this already huge port and (b) remove expected functionality.
PR: 245250
Submitted by: Tamas Szakaly <sghctoma AT gmail.com>
Reported by: yuri@
Approved by: jrm
Differential Revision: https://reviews.freebsd.org/D24330
Notes
Notes:
svn path=/head/; revision=531050
Diffstat (limited to 'www/chromium')
3 files changed, 1 insertions, 93 deletions
diff --git a/www/chromium/Makefile b/www/chromium/Makefile index 052cce8e9c0e..b8d9271e7671 100644 --- a/www/chromium/Makefile +++ b/www/chromium/Makefile @@ -3,6 +3,7 @@ PORTNAME= chromium PORTVERSION= 80.0.3987.163 +PORTREVISION= 1 CATEGORIES?= www java MASTER_SITES= https://commondatastorage.googleapis.com/chromium-browser-official/ \ LOCAL/cpm/chromium/:fonts diff --git a/www/chromium/files/patch-media_capture_video_linux_video__capture__device__factory__linux.cc b/www/chromium/files/patch-media_capture_video_linux_video__capture__device__factory__linux.cc deleted file mode 100644 index 544c35d92c13..000000000000 --- a/www/chromium/files/patch-media_capture_video_linux_video__capture__device__factory__linux.cc +++ /dev/null @@ -1,32 +0,0 @@ ---- media/capture/video/linux/video_capture_device_factory_linux.cc.orig 2019-09-09 21:55:20 UTC -+++ media/capture/video/linux/video_capture_device_factory_linux.cc -@@ -259,6 +259,7 @@ bool VideoCaptureDeviceFactoryLinux::HasUsableFormats( - if (!(capabilities & V4L2_CAP_VIDEO_CAPTURE)) - return false; - -+#if !defined(OS_FREEBSD) - const std::vector<uint32_t>& usable_fourccs = - VideoCaptureDeviceLinux::GetListOfUsableFourCCs(false); - v4l2_fmtdesc fmtdesc = {}; -@@ -267,6 +268,7 @@ bool VideoCaptureDeviceFactoryLinux::HasUsableFormats( - if (base::Contains(usable_fourccs, fmtdesc.pixelformat)) - return true; - } -+#endif - - DVLOG(1) << "No usable formats found"; - return false; -@@ -312,9 +314,13 @@ void VideoCaptureDeviceFactoryLinux::GetSupportedForma - v4l2_format.type = V4L2_BUF_TYPE_VIDEO_CAPTURE; - for (; DoIoctl(fd, VIDIOC_ENUM_FMT, &v4l2_format) == 0; ++v4l2_format.index) { - VideoCaptureFormat supported_format; -+#if !defined(OS_FREEBSD) - supported_format.pixel_format = - VideoCaptureDeviceLinux::V4l2FourCcToChromiumPixelFormat( - v4l2_format.pixelformat); -+#else -+ supported_format.pixel_format = PIXEL_FORMAT_UNKNOWN; -+#endif - - if (supported_format.pixel_format == PIXEL_FORMAT_UNKNOWN) - continue; diff --git a/www/chromium/files/patch-media_capture_video_linux_video__capture__device__linux.cc b/www/chromium/files/patch-media_capture_video_linux_video__capture__device__linux.cc deleted file mode 100644 index 665e4eecd0b6..000000000000 --- a/www/chromium/files/patch-media_capture_video_linux_video__capture__device__linux.cc +++ /dev/null @@ -1,61 +0,0 @@ ---- media/capture/video/linux/video_capture_device_linux.cc.orig 2019-04-30 22:22:52 UTC -+++ media/capture/video/linux/video_capture_device_linux.cc -@@ -37,6 +37,7 @@ int TranslatePowerLineFrequencyToV4L2(PowerLineFrequen - - } // namespace - -+#if !defined(OS_FREEBSD) - // Translates Video4Linux pixel formats to Chromium pixel formats. - // static - VideoPixelFormat VideoCaptureDeviceLinux::V4l2FourCcToChromiumPixelFormat( -@@ -50,6 +51,7 @@ std::vector<uint32_t> VideoCaptureDeviceLinux::GetList - bool favour_mjpeg) { - return V4L2CaptureDelegate::GetListOfUsableFourCcs(favour_mjpeg); - } -+#endif // !defined(OS_FREEBSD) - - VideoCaptureDeviceLinux::VideoCaptureDeviceLinux( - scoped_refptr<V4L2CaptureDevice> v4l2, -@@ -71,6 +73,7 @@ void VideoCaptureDeviceLinux::AllocateAndStart( - const VideoCaptureParams& params, - std::unique_ptr<VideoCaptureDevice::Client> client) { - DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); -+#if !defined(OS_FREEBSD) - DCHECK(!capture_impl_); - if (v4l2_thread_.IsRunning()) - return; // Wrong state. -@@ -98,10 +101,12 @@ void VideoCaptureDeviceLinux::AllocateAndStart( - for (auto& request : photo_requests_queue_) - v4l2_thread_.task_runner()->PostTask(FROM_HERE, std::move(request)); - photo_requests_queue_.clear(); -+#endif // !defined(OS_FREEBSD) - } - - void VideoCaptureDeviceLinux::StopAndDeAllocate() { - DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); -+#if !defined(OS_FREEBSD) - if (!v4l2_thread_.IsRunning()) - return; // Wrong state. - v4l2_thread_.task_runner()->PostTask( -@@ -111,6 +116,7 @@ void VideoCaptureDeviceLinux::StopAndDeAllocate() { - v4l2_thread_.Stop(); - - capture_impl_ = nullptr; -+#endif // !defined(OS_FREEBSD) - } - - void VideoCaptureDeviceLinux::TakePhoto(TakePhotoCallback callback) { -@@ -158,11 +164,13 @@ void VideoCaptureDeviceLinux::SetPhotoOptions( - void VideoCaptureDeviceLinux::SetRotation(int rotation) { - DCHECK_CALLED_ON_VALID_SEQUENCE(sequence_checker_); - rotation_ = rotation; -+#if !defined(OS_FREEBSD) - if (v4l2_thread_.IsRunning()) { - v4l2_thread_.task_runner()->PostTask( - FROM_HERE, base::BindOnce(&V4L2CaptureDelegate::SetRotation, - capture_impl_->GetWeakPtr(), rotation)); - } -+#endif // !defined(OS_FREEBSD) - } - - } // namespace media |