AutoXL.wiggler constructor
const
AutoXL.wiggler({})
AutoXL.wiggler
is intended to wiggle and rotate a little bit
in its place to represent pointer hovers or accelerometer data.
This AutoXL
defaults depth to -1
, meaning each progressive layer
will have a greater parallax factor than the previous.
Implementation
const AutoXL.wiggler({
Key? key,
required this.layers,
this.supportsPointer = true,
this.supportsSensors = true,
this.depth = -1,
this.duration = const Duration(milliseconds: 200),
this.curve = Curves.ease,
this.drag = const Duration(milliseconds: 100),
}) : _threeD = (!supportsPointer && !supportsSensors) ? 0 : 0.0015,
_baseOffset = (!supportsPointer && !supportsSensors) ? 0 : 15.0,
_layerOffset = (!supportsPointer && !supportsSensors) ? 0 : 25.0,
_baseRotation = (!supportsPointer && !supportsSensors) ? 0 : 0.25,
_layerRotation = (!supportsPointer && !supportsSensors) ? 0 : 0.1,
_baseZ = (!supportsPointer && !supportsSensors) ? 0 : 0.1,
_layerZ = (!supportsPointer && !supportsSensors) ? 0 : 0.1,
super(key: key);