Commit a17bc29
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@main1 parent 0793fab commit a17bc29
File tree
21 files changed
+125
-17
lines changed- LayoutTests
- fast/mediastream
- platform/glib
- webrtc
- Source
- WebCore
- platform/mock
- testing
- WebKit/UIProcess
- API/C
- Cocoa
- Tools/WebKitTestRunner
- InjectedBundle
- Bindings
21 files changed
+125
-17
lines changedLines changed: 4 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2229 | 2229 | | |
2230 | 2230 | | |
2231 | 2231 | | |
| 2232 | + | |
| 2233 | + | |
2232 | 2234 | | |
2233 | 2235 | | |
2234 | 2236 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
150 | 150 | | |
151 | 151 | | |
152 | 152 | | |
153 | | - | |
| 153 | + | |
154 | 154 | | |
155 | 155 | | |
156 | 156 | | |
| |||
164 | 164 | | |
165 | 165 | | |
166 | 166 | | |
167 | | - | |
168 | | - | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
169 | 172 | | |
170 | 173 | | |
171 | | - | |
| 174 | + | |
172 | 175 | | |
173 | 176 | | |
174 | 177 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
700 | 700 | | |
701 | 701 | | |
702 | 702 | | |
| 703 | + | |
| 704 | + | |
| 705 | + | |
| 706 | + | |
| 707 | + | |
| 708 | + | |
| 709 | + | |
| 710 | + | |
| 711 | + | |
| 712 | + | |
| 713 | + | |
| 714 | + | |
| 715 | + | |
| 716 | + | |
| 717 | + | |
703 | 718 | | |
704 | 719 | | |
| 720 | + | |
| 721 | + | |
| 722 | + | |
705 | 723 | | |
706 | 724 | | |
707 | 725 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
93 | 93 | | |
94 | 94 | | |
95 | 95 | | |
| 96 | + | |
96 | 97 | | |
97 | 98 | | |
98 | 99 | | |
| |||
172 | 173 | | |
173 | 174 | | |
174 | 175 | | |
| 176 | + | |
175 | 177 | | |
176 | 178 | | |
177 | 179 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
6247 | 6247 | | |
6248 | 6248 | | |
6249 | 6249 | | |
| 6250 | + | |
| 6251 | + | |
| 6252 | + | |
| 6253 | + | |
| 6254 | + | |
6250 | 6255 | | |
6251 | 6256 | | |
6252 | 6257 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1012 | 1012 | | |
1013 | 1013 | | |
1014 | 1014 | | |
| 1015 | + | |
1015 | 1016 | | |
1016 | 1017 | | |
1017 | 1018 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1164 | 1164 | | |
1165 | 1165 | | |
1166 | 1166 | | |
| 1167 | + | |
1167 | 1168 | | |
1168 | 1169 | | |
1169 | 1170 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
3232 | 3232 | | |
3233 | 3233 | | |
3234 | 3234 | | |
3235 | | - | |
| 3235 | + | |
3236 | 3236 | | |
3237 | 3237 | | |
3238 | | - | |
| 3238 | + | |
3239 | 3239 | | |
3240 | 3240 | | |
3241 | 3241 | | |
| |||
0 commit comments