[webkit-changes] [WebKit/WebKit] 97f749: Allow mock capture rotation to use the new coordin...

youennf noreply at github.com
Sun Dec 8 11:54:35 PST 2024


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 97f749501de4ef1d4aae3cb822c0da3b426cbea3
      https://github.com/WebKit/WebKit/commit/97f749501de4ef1d4aae3cb822c0da3b426cbea3
  Author: Youenn Fablet <youenn at apple.com>
  Date:   2024-12-08 (Sun, 08 Dec 2024)

  Changed paths:
    A LayoutTests/fast/mediastream/video-rotation-clone-expected.txt
    A LayoutTests/fast/mediastream/video-rotation-clone.html
    M LayoutTests/platform/glib/TestExpectations
    M LayoutTests/webrtc/routines.js
    M Source/WebCore/platform/mock/MockRealtimeVideoSource.cpp
    M Source/WebCore/platform/mock/MockRealtimeVideoSource.h
    M Source/WebCore/testing/Internals.cpp
    M Source/WebCore/testing/Internals.h
    M Source/WebCore/testing/Internals.idl
    M Source/WebKit/UIProcess/API/C/WKPage.cpp
    M Source/WebKit/UIProcess/API/C/WKPagePrivate.h
    M Source/WebKit/UIProcess/Cocoa/UserMediaPermissionRequestManagerProxy.mm
    M Source/WebKit/UIProcess/UserMediaPermissionRequestManagerProxy.h
    M Source/WebKit/UIProcess/WebPageProxy.cpp
    M Source/WebKit/UIProcess/WebPageProxy.h
    M Tools/WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl
    M Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp
    M Tools/WebKitTestRunner/InjectedBundle/TestRunner.h
    M Tools/WebKitTestRunner/TestController.cpp
    M Tools/WebKitTestRunner/TestController.h
    M Tools/WebKitTestRunner/TestInvocation.cpp

  Log Message:
  -----------
  Allow mock capture rotation to use the new coordinator code path
https://bugs.webkit.org/show_bug.cgi?id=283569
rdar://problem/140418270

Reviewed by Jean-Yves Avenard.

We update mock camera rotation testing to pass the camera ID.
This allows to use the rotationAngleForHorizonLevelDisplayChanged code path when the camera ID is given.
We update MockRealtimeVideoSource to support this, like done for AVVideoCaptureSource.

This allows to write a test for the clone camera track bug https://bugs.webkit.org/show_bug.cgi?id=283480.

* LayoutTests/fast/mediastream/video-rotation-clone-expected.txt: Added.
* LayoutTests/fast/mediastream/video-rotation-clone.html: Added.
* LayoutTests/platform/glib/TestExpectations:
* LayoutTests/webrtc/routines.js:
* Source/WebCore/platform/mock/MockRealtimeVideoSource.cpp:
(WebCore::MockRealtimeVideoSource::rotationAngleForHorizonLevelDisplayChanged):
(WebCore::MockRealtimeVideoSource::orientationChanged):
* Source/WebCore/platform/mock/MockRealtimeVideoSource.h:
* Source/WebCore/testing/Internals.cpp:
(WebCore::Internals::mediaStreamTrackPersistentId):
* Source/WebCore/testing/Internals.h:
* Source/WebCore/testing/Internals.idl:
* Source/WebKit/UIProcess/API/C/WKPage.cpp:
(WKPageSetMockCameraOrientationForTesting):
(WKPageSetMockCameraOrientation): Deleted.
* Source/WebKit/UIProcess/API/C/WKPagePrivate.h:
* Source/WebKit/UIProcess/Cocoa/UserMediaPermissionRequestManagerProxy.mm:
(-[WKRotationCoordinatorObserver isMonitoringCaptureDeviceRotation:]):
(WebKit::UserMediaPermissionRequestManagerProxy::isMonitoringCaptureDeviceRotation):
* Source/WebKit/UIProcess/UserMediaPermissionRequestManagerProxy.h:
* Source/WebKit/UIProcess/WebPageProxy.cpp:
(WebKit::WebPageProxy::setMediaCaptureRotationForTesting):
* Source/WebKit/UIProcess/WebPageProxy.h:
* Tools/WebKitTestRunner/InjectedBundle/Bindings/TestRunner.idl:
* Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp:
(WTR::TestRunner::setMockCameraOrientation):
* Tools/WebKitTestRunner/InjectedBundle/TestRunner.h:
* Tools/WebKitTestRunner/TestController.cpp:
(WTR::TestController::resetStateToConsistentValues):
(WTR::TestController::setMockCameraOrientation):
* Tools/WebKitTestRunner/TestController.h:
* Tools/WebKitTestRunner/TestInvocation.cpp:
(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):

Canonical link: https://commits.webkit.org/287518@main



To unsubscribe from these emails, change your notification settings at https://github.com/WebKit/WebKit/settings/notifications


More information about the webkit-changes mailing list