mirror of
https://github.com/rustdesk/qemu-display.git
synced 2025-08-17 16:25:39 +00:00
rdw: hook 2d drawing
Signed-off-by: Marc-André Lureau <marcandre.lureau@redhat.com>
This commit is contained in:
parent
b87f460871
commit
697fb50c0f
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 _)));
|
||||||
|
Loading…
x
Reference in New Issue
Block a user