mirror of
https://github.com/rustdesk/qemu-display.git
synced 2026-10-26 06:00:44 +00:00
rdw: hook 2d drawing
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
This commit is contained in:
1 parent
b87f460871
commit
697fb50c0f
2 files changed
+11
No files matched your search
Binary file not shown.
@@ -150,8 +150,19 @@ mod imp {
|
|||||||
log::debug!("Console event: {:?}", evt);
|
log::debug!("Console event: {:?}", evt);
|
||||||
match evt {
|
match evt {
|
||||||
Scanout(s) => {
|
Scanout(s) => {
|
||||||
|
if s.format != 0x20020888 {
|
||||||
|
log::warn!("Format not yet supported: {:X}", s.format);
|
||||||
|
return Continue(true);
|
||||||
|
}
|
||||||
|
widget.set_display_size(Some((s.width as _, s.height as _)));
|
||||||
|
widget.update_area(0, 0, s.width as _, s.height as _, s.stride as _, &s.data);
|
||||||
}
|
}
|
||||||
Update(u) => {
|
Update(u) => {
|
||||||
|
if u.format != 0x20020888 {
|
||||||
|
log::warn!("Format not yet supported: {:X}", u.format);
|
||||||
|
return Continue(true);
|
||||||
|
}
|
||||||
|
widget.update_area(u.x as _, u.y as _, u.w as _, u.h as _, u.stride as _, &u.data);
|
||||||
}
|
}
|
||||||
ScanoutDMABUF(s) => {
|
ScanoutDMABUF(s) => {
|
||||||
widget.set_display_size(Some((s.width as _, s.height as _)));
|
widget.set_display_size(Some((s.width as _, s.height as _)));
|
||||||
|
|||||||
Reference in new issue
Block a user