expansion static method

Matrix4 expansion(
  1. DoughTransformerContext context
)

A utility method which creates a Matrix4 that scales widgets by a factor of the DoughRecipe.expansion property.

Implementation

static Matrix4 expansion(DoughTransformerContext context) {
  final scaleMag = ui.lerpDouble(
    1,
    context.recipe.expansion,
    context.t,
  );
  return Matrix4.identity()..scale(scaleMag);
}