-
-
Notifications
You must be signed in to change notification settings - Fork 266
Home
Gautier edited this page Sep 7, 2022
·
2 revisions
You can keep all available photo sizes by implementing selectDefaultSize. Because every devices has differents photos sizes we have to wait our plugin has init to give you all available formats. By default selectDefaultSize will select the max available size.
/// initialize the photoSize to null as you don't know available sizes yet
ValueNotifier<Size> photoSize = ValueNotifier(null);
/// you can keep a list of all available sizes from the selectDefaultSize callback
List<Size> availableSizes;
CameraAwesome(
selectDefaultSize: (availableSizes) {
this.availableSizes = availableSizes;
// after this photoSize.value will be availableSizes[0]
return availableSizes[0];
},
photoSize: photoSize,
...
)
in progress