Commit 0d0a4574 authored by Xaver Hugl's avatar Xaver Hugl
Browse files

Revert "screencast: make context current in tryEnqueue"

This reverts commit 1fd1c037,
because it can make KWin freeze

(cherry picked from commit 98936140)
parent 6325cd46
Pipeline #151163 passed with stage
in 14 minutes and 31 seconds
......@@ -504,10 +504,8 @@ void ScreenCastStream::tryEnqueue(pw_buffer *buffer)
// we need to insert a fence into the command stream and enqueue the pipewire buffer
// only after the fence is signaled; otherwise stream consumers will most likely see
// a corrupted buffer.
if (auto scene = Compositor::self()->scene()) {
if (kwinApp()->platform()->supportsNativeFence()) {
Q_ASSERT_X(eglGetCurrentContext(), "tryEnqueue", "no current context");
m_pendingFence = new EGLNativeFence(kwinApp()->platform()->sceneEglDisplay());
if (!m_pendingFence->isValid()) {
qCWarning(KWIN_SCREENCAST) << "Failed to create a native EGL fence";
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment