https://bugs.kde.org/show_bug.cgi?id=528423
Bug ID: 528423
Summary: Cursor metadata is produced by
ScreenCastStream::addCursorMetadata is jagged if
display is scaled
Classification: Plasma
Product: kwin
Version First 6.8.2
Reported In:
Platform: Other
OS: Linux
Status: REPORTED
Severity: normal
Priority: NOR
Component: screencasting
Assignee: [email protected]
Reporter: [email protected]
Target Milestone: ---
Created attachment 198130
--> https://bugs.kde.org/attachment.cgi?id=198130&action=edit
Cursor is jagged a little bit
DESCRIPTION
Cursor metadata is produced by pipewire is jagged a little bit if display is
scaled
STEPS TO REPRODUCE
1. Start screencast using pipewire
2. Get cursor metadata from it
3. Write RGBA pixels somewhere to look at it
OBSERVED RESULT
Cursor looks jagged
EXPECTED RESULT
Cursor looks correct
SOFTWARE/OS VERSIONS
Operating System: NixOS 26.11
KDE Plasma Version: 6.8.2
KDE Frameworks Version: 6.31.0
Qt Version: 6.12.0
Kernel Version: 6.18.60 (64-bit)
Graphics Platform: Wayland
Processors: 32 × Intel® Core™ i9-14900HX
Memory: 32 GiB of RAM (31.0 GiB usable)
Graphics Processor 1: Intel® Graphics
Graphics Processor 2: NVIDIA GeForce RTX 4070 Laptop GPU
ADDITIONAL INFORMATION
The fix is one line actually:
diff --git a/src/plugins/screencast/screencaststream.cpp
b/src/plugins/screencast/screencaststream.cpp
--- a/src/plugins/screencast/screencaststream.cpp
+++ b/src/plugins/screencast/screencaststream.cpp
@@ -880,6 +880,7 @@ void ScreenCastStream::addCursorMetadata(spa_buffer
*spaBuffer, Cursor *cursor)
const QImage image = kwinApp()->cursorImage().image();
if (!image.isNull()) {
QPainter painter(&dest);
+ painter.setRenderHint(QPainter::SmoothPixmapTransform, true);
painter.drawImage(Rect({0, 0}, targetSize), image);
}
}
I compiled kwin using this patch and tested it, kwin produces correct cursor
metadata without any damage
--
You are receiving this mail because:
You are watching all bug changes.