DoughRecipeData constructor
DoughRecipeData({})
Creates a recipe. Defaults are implied for any values not specified.
Implementation
factory DoughRecipeData({
double? viscosity,
double? adhesion,
double? expansion,
bool? usePerspectiveWarp,
double? perspectiveWarpDepth,
Duration? entryDuration,
Curve? entryCurve,
Duration? exitDuration,
Curve? exitCurve,
DraggableDoughPrefs? draggablePrefs,
}) {
return DoughRecipeData.raw(
viscosity: viscosity ?? 7000,
adhesion: adhesion ?? 12,
expansion: expansion ?? 1,
usePerspectiveWarp: usePerspectiveWarp ?? false,
perspectiveWarpDepth: perspectiveWarpDepth ?? 0.015,
entryDuration: entryDuration ?? const Duration(milliseconds: 20),
entryCurve: entryCurve ?? Curves.easeInOut,
exitDuration: exitDuration ?? const Duration(milliseconds: 500),
exitCurve: exitCurve ?? Curves.elasticIn,
draggablePrefs: draggablePrefs ?? DraggableDoughPrefs.fallback(),
);
}