CameraPickerConfig constructor
const
CameraPickerConfig({
- bool enableRecording = false,
- bool onlyEnableRecording = false,
- bool enableTapRecording = false,
- bool enableAudio = true,
- bool enableSetExposure = true,
- bool enableExposureControlOnPoint = true,
- bool enablePinchToZoom = true,
- bool enablePullToZoomInRecord = true,
- bool enableScaledPreview = true,
- bool shouldDeletePreviewFile = false,
- bool shouldAutoPreviewVideo = false,
- Duration? maximumRecordingDuration = const Duration(seconds: 15),
- Duration minimumRecordingDuration = const Duration(seconds: 1),
- ThemeData? theme,
- CameraPickerTextDelegate? textDelegate,
- int cameraQuarterTurns = 0,
- ResolutionPreset resolutionPreset = ResolutionPreset.max,
- ImageFormatGroup imageFormatGroup = ImageFormatGroup.unknown,
- CameraLensDirection preferredLensDirection = CameraLensDirection.back,
- FlashMode preferredFlashMode = FlashMode.auto,
- DeviceOrientation? lockCaptureOrientation,
- ForegroundBuilder? foregroundBuilder,
- PreviewTransformBuilder? previewTransformBuilder,
- EntitySaveCallback? onEntitySaving,
- CameraErrorHandler? onError,
- XFileCapturedCallback? onXFileCaptured,
- VoidCallback? onMinimumRecordDurationNotMet,
Implementation
const CameraPickerConfig({
this.enableRecording = false,
this.onlyEnableRecording = false,
this.enableTapRecording = false,
this.enableAudio = true,
this.enableSetExposure = true,
this.enableExposureControlOnPoint = true,
this.enablePinchToZoom = true,
this.enablePullToZoomInRecord = true,
this.enableScaledPreview = true,
this.shouldDeletePreviewFile = false,
this.shouldAutoPreviewVideo = false,
this.maximumRecordingDuration = const Duration(seconds: 15),
this.minimumRecordingDuration = const Duration(seconds: 1),
this.theme,
this.textDelegate,
this.cameraQuarterTurns = 0,
this.resolutionPreset = ResolutionPreset.max,
this.imageFormatGroup = ImageFormatGroup.unknown,
this.preferredLensDirection = CameraLensDirection.back,
this.preferredFlashMode = FlashMode.auto,
this.lockCaptureOrientation,
this.foregroundBuilder,
this.previewTransformBuilder,
this.onEntitySaving,
this.onError,
this.onXFileCaptured,
this.onMinimumRecordDurationNotMet,
}) : assert(
enableRecording == true || onlyEnableRecording != true,
'Recording mode error.',
);