screen_capturer
screen_capturer copied to clipboard
How to return imageBytes without saving image to file or copy it to clipboard ?
i want to know if there is a way to obtain image bytes without saving the images to a file or copying it to the clipboard.?
Future<String> takeScreenShot() async {
CapturedData? capturedData = await screenCapturer.capture(
mode: CaptureMode.window,
imagePath: null,
copyToClipboard: false,
);
String base64 = base64Encode(capturedData!.imageBytes!);
return base64;
}
@dridihaythem in my opinion, there may be performance issues with transferring imageBytes.