feat: adapt for the latest renderer plugin

This commit is contained in:
Kingtous
2023-02-19 15:25:30 +08:00
committed by fufesou
parent ea07b9690e
commit d3455f3ce2
7 changed files with 85 additions and 24 deletions

View File

@@ -1446,14 +1446,15 @@ class FFI {
}
} else if (message is EventToUI_Rgba) {
// Fetch the image buffer from rust codes.
final sz = platformFFI.getRgbaSize(id);
if (sz == null || sz == 0) {
return;
}
final rgba = platformFFI.getRgba(id, sz);
if (rgba != null) {
imageModel.onRgba(rgba);
}
// final sz = platformFFI.getRgbaSize(id);
// if (sz == null || sz == 0) {
// return;
// }
// final rgba = platformFFI.getRgba(id, sz);
// if (rgba != null) {
// imageModel.onRgba(rgba);
// }
// imageModel.onRgba(rgba);
}
}
debugPrint('Exit session event loop');