Title: [273725] trunk/Source/WebKit
- Revision
- 273725
- Author
- [email protected]
- Date
- 2021-03-02 01:18:12 -0800 (Tue, 02 Mar 2021)
Log Message
Camera capture in iOS with GPUProcess enabled does not always handle orientation well at start up
https://bugs.webkit.org/show_bug.cgi?id=222167
<rdar://problem/74520496>
Reviewed by Eric Carlson.
Before the patch, GPU process orientation monitors were only getting updates after creation of the web process connection.
The initial value was therefore sometimes wrong.
Update this by storing the orientation value in GPU process and initializing it for every web process connection.
Manually tested.
* GPUProcess/GPUProcess.cpp:
(WebKit::GPUProcess::createGPUConnectionToWebProcess):
(WebKit::GPUProcess::setOrientationForMediaCapture):
* GPUProcess/GPUProcess.h:
Modified Paths
Diff
Modified: trunk/Source/WebKit/ChangeLog (273724 => 273725)
--- trunk/Source/WebKit/ChangeLog 2021-03-02 06:59:14 UTC (rev 273724)
+++ trunk/Source/WebKit/ChangeLog 2021-03-02 09:18:12 UTC (rev 273725)
@@ -1,3 +1,21 @@
+2021-03-02 Youenn Fablet <[email protected]>
+
+ Camera capture in iOS with GPUProcess enabled does not always handle orientation well at start up
+ https://bugs.webkit.org/show_bug.cgi?id=222167
+ <rdar://problem/74520496>
+
+ Reviewed by Eric Carlson.
+
+ Before the patch, GPU process orientation monitors were only getting updates after creation of the web process connection.
+ The initial value was therefore sometimes wrong.
+ Update this by storing the orientation value in GPU process and initializing it for every web process connection.
+ Manually tested.
+
+ * GPUProcess/GPUProcess.cpp:
+ (WebKit::GPUProcess::createGPUConnectionToWebProcess):
+ (WebKit::GPUProcess::setOrientationForMediaCapture):
+ * GPUProcess/GPUProcess.h:
+
2021-03-01 Fujii Hironori <[email protected]>
[GTK] Web inspector related tests very slow or timeout in debug mode
Modified: trunk/Source/WebKit/GPUProcess/GPUProcess.cpp (273724 => 273725)
--- trunk/Source/WebKit/GPUProcess/GPUProcess.cpp 2021-03-02 06:59:14 UTC (rev 273724)
+++ trunk/Source/WebKit/GPUProcess/GPUProcess.cpp 2021-03-02 09:18:12 UTC (rev 273725)
@@ -97,6 +97,7 @@
// FIXME: We should refactor code to go from WebProcess -> GPUProcess -> UIProcess when getUserMedia is called instead of going from WebProcess -> UIProcess directly.
auto access = m_mediaCaptureAccessMap.take(identifier);
newConnection->updateCaptureAccess(access.allowAudioCapture, access.allowVideoCapture, access.allowDisplayCapture);
+ newConnection->setOrientationForMediaCapture(m_orientation);
#endif
ASSERT(!m_webProcessConnections.contains(identifier));
@@ -211,6 +212,7 @@
void GPUProcess::setOrientationForMediaCapture(uint64_t orientation)
{
+ m_orientation = orientation;
for (auto& connection : m_webProcessConnections.values())
connection->setOrientationForMediaCapture(orientation);
}
Modified: trunk/Source/WebKit/GPUProcess/GPUProcess.h (273724 => 273725)
--- trunk/Source/WebKit/GPUProcess/GPUProcess.h 2021-03-02 06:59:14 UTC (rev 273724)
+++ trunk/Source/WebKit/GPUProcess/GPUProcess.h 2021-03-02 09:18:12 UTC (rev 273725)
@@ -133,6 +133,7 @@
RefPtr<WorkQueue> m_audioMediaStreamTrackRendererQueue;
RefPtr<WorkQueue> m_videoMediaStreamTrackRendererQueue;
#endif
+ uint64_t m_orientation { 0 };
#endif
#if USE(LIBWEBRTC) && PLATFORM(COCOA)
RefPtr<WorkQueue> m_libWebRTCCodecsQueue;
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes