mirror of
https://github.com/rustdesk/rustdesk.git
synced 2026-09-18 02:10:59 +03:00
docs(cursor): explain image decoding and Retina sampling
This commit is contained in:
@@ -2995,7 +2995,9 @@ class PredefinedCursor {
|
||||
|
||||
() async {
|
||||
_image?.dispose();
|
||||
// PNG stores straight alpha; let the codec prepare the pixels for ui.Image.
|
||||
// Native registration uses this ui.Image. The RGBA bytes from img2 are
|
||||
// straight alpha, but PixelFormat.rgba8888 requires premultiplied alpha.
|
||||
// Decode the PNG directly to preserve translucent cursor colors.
|
||||
final codec = await ui.instantiateImageCodec(pngBytes);
|
||||
final ui.Image nativeImage;
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user