We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hi.
Recently, photos on the iPhone are getting a white background? What problem has occurred?
The codes for converting a widget to an image are as follows:
RenderRepaintBoundary? boundary = key1.currentContext?.findRenderObject() as RenderRepaintBoundary?; ui.Image image = await boundary!.toImage(pixelRatio: 3.0); ByteData? byteData = await image.toByteData(format: ui.ImageByteFormat.png); pngBytes = byteData!.buffer.asUint8List(); imageInMemory = pngBytes; inside.value = false; final String dir; if (Platform.isAndroid) { dir = (await getExternalStorageDirectory())?.path ?? ""; } else { dir = (await getApplicationDocumentsDirectory()).path; } final String fileName = "${DateTime.now().millisecondsSinceEpoch}"; final String fullPath = '$dir/$fileName.png'; File capturedFile = File(fullPath); await capturedFile.writeAsBytes(pngBytes!);
The text was updated successfully, but these errors were encountered:
No branches or pull requests
hi.
Recently, photos on the iPhone are getting a white background? What problem has occurred?
The codes for converting a widget to an image are as follows:
The text was updated successfully, but these errors were encountered: