SmartFaceCamera class

Inheritance

Constructors

SmartFaceCamera({ImageResolution imageResolution = ImageResolution.medium, CameraLens? defaultCameraLens, bool enableAudio = true, bool autoCapture = false, bool showControls = true, bool showCaptureControl = true, bool showFlashControl = true, bool showCameraLensControl = true, String? message, CameraFlashMode defaultFlashMode = CameraFlashMode.auto, CameraOrientation? orientation = CameraOrientation.portraitUp, TextStyle messageStyle = const TextStyle(fontSize: 14, height: 1.5, fontWeight: FontWeight.w400), required void onCapture(File? image), void onFaceDetected(Face? face)?, @Deprecated('Use [captureControlBuilder]') Widget? captureControlIcon, CaptureControlBuilder? captureControlBuilder, Widget? lensControlIcon, FlashControlBuilder? flashControlBuilder, MessageBuilder? messageBuilder, IndicatorShape indicatorShape = IndicatorShape.defaultShape, String? indicatorAssetImage, IndicatorBuilder? indicatorBuilder, bool autoDisableCaptureControl = false, FaceDetectorMode performanceMode = FaceDetectorMode.fast, Key? key})
const

Properties

autoCapture bool
Set true to capture image on face detected.
final
autoDisableCaptureControl bool
Set true to automatically disable capture control widget when no face is detected.
final
captureControlBuilder → CaptureControlBuilder?
Use this to build custom widgets for capture control.
final
captureControlIcon Widget?
Use this to render a custom widget for capture control.
final
defaultCameraLens CameraLens?
Use this to set initial camera lens direction.
final
defaultFlashMode CameraFlashMode
Use this to set initial flash mode.
final
enableAudio bool
Set false to disable capture sound.
final
flashControlBuilder → FlashControlBuilder?
Use this to build custom widgets for flash control based on camera flash mode.
final
hashCode int
The hash code for this object.
no setterinherited
imageResolution ImageResolution
Use this to set image resolution.
final
indicatorAssetImage String?
Use this to pass an asset image when IndicatorShape is set to image.
final
indicatorBuilder → IndicatorBuilder?
Use this to build custom widgets for the face indicator
final
indicatorShape IndicatorShape
Use this to change the shape of the face indicator.
final
key Key?
Controls how one widget replaces another widget in the tree.
finalinherited
lensControlIcon Widget?
Use this to render a custom widget for camera lens control.
final
message String?
Use this pass a message above the camera.
final
messageBuilder → MessageBuilder?
Use this to build custom messages based on face position.
final
messageStyle TextStyle
Style applied to the message widget.
final
onCapture → void Function(File? image)
Callback invoked when camera captures image.
final
onFaceDetected → (void Function(Face? face)?)
Callback invoked when camera detects face.
final
orientation CameraOrientation?
Use this to lock camera orientation.
final
performanceMode FaceDetectorMode
Use this to set your preferred performance mode.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
showCameraLensControl bool
Set false to hide camera lens control icon.
final
showCaptureControl bool
Set false to hide capture control icon.
final
showControls bool
Set false to hide all controls.
final
showFlashControl bool
Set false to hide flash control control icon.
final

Methods

createElement() StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() State<SmartFaceCamera>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) String
Returns a one-line detailed description of the object.
inherited
toStringShort() String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited