Repository: flutter
Issue: Rendering Problem with ElevatedButton in FadeTransistion and flutter 3.3.1 (not at 2.8.1)
Labels: engine,a: animation,c: rendering,has reproducible steps,P2,found in release: 3.3,found in release: 3.4,team-engine,triaged-engine

## Steps to Reproduce

CODE:

```
import 'package:flutter/material.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: const MyHomePage(title: 'Flutter Demo Home Page'),
    );
  }
}

class MyHomePage extends StatefulWidget  {
  const MyHomePage({super.key, required this.title});
  final String title;
  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> with TickerProviderStateMixin{
  List<Animation<double>> animations = [];
  late AnimationController controller;

  @override
  void initState() {
    super.initState();
    controller = AnimationController(duration: const Duration(milliseconds: 3000), vsync: this);
    generateAnimations(animations, controller);
    controller.forward();
  }

  AnimationController generateAnimations(List<Animation<double>> animations, AnimationController controller){
    animations.add(createAnimation(0.0, 0.3, controller));
    animations.add(createAnimation(0.1, 0.4, controller));
    animations.add(createAnimation(0.2, 0.5, controller));
    animations.add(createAnimation(0.3, 0.6, controller));
    animations.add(createAnimation(0.4, 0.7, controller));
    animations.add(createAnimation(0.5, 0.8, controller));
    animations.add(createAnimation(0.6, 1.0, controller));
    return controller;
  }

  CurvedAnimation createAnimation(double begin, double end, AnimationController controller) {
    return new CurvedAnimation(
      parent: controller,
      curve: new Interval(begin, end, curve: Curves.easeIn),
    );
  }

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: Text(widget.title),
      ),
      body: Center(
        child: FadeTransition(
          opacity: animations[0],
          child: Column(
            mainAxisAlignment: MainAxisAlignment.center,
            children: <Widget>[
              Expanded(child: FadeTransition(opacity: animations[0], child: getButton())),
              Expanded(child: FadeTransition(opacity: animations[1], child: getButton())),
              Expanded(child: FadeTransition(opacity: animations[2], child: getButton())),
              Expanded(child: FadeTransition(opacity: animations[3], child: getButton())),
              Expanded(child: FadeTransition(opacity: animations[4], child: getButton())),
            ],
          ),
        ),
      ),
    );
  }

  void doAnimation() {
      controller.reverse().then((_) {
        controller.forward();
      });
  }

  ElevatedButton getButton() {
      return ElevatedButton(
        style: ButtonStyle(
          elevation: MaterialStateProperty.resolveWith<double>(
                (Set<MaterialState> states) {
              if (states.contains(MaterialState.focused) || states.contains(MaterialState.pressed)){
                return 5 * .25;
              }
              return 5; // Defer to the widget's default.
            },
          ),
          foregroundColor: MaterialStateProperty.all<Color>(Colors.green),
          overlayColor: MaterialStateProperty.all(Colors.transparent),
          backgroundColor: MaterialStateProperty.resolveWith<Color>((Set<MaterialState> states) {
              if (states.contains(MaterialState.disabled))
                return Colors.grey;
              return Colors.white; // Use the component's default.
            },
          ),
          padding: MaterialStateProperty.all(EdgeInsets.symmetric(horizontal: 12, vertical: 6)),
          shape: MaterialStateProperty.all(getShape()),
        ),
        child: Align(
          alignment: Alignment.centerLeft,
          child: Text("TEST",
            style: TextStyle(fontSize: 25, fontWeight: FontWeight.normal, color: Colors.pink),
            textAlign: TextAlign.start,
            softWrap: true,
            overflow: TextOverflow.visible,
          ),
        ),
        onPressed: doAnimation,
      );
    }

  OutlinedBorder? getShape() {
    new RoundedRectangleBorder(
      borderRadius: BorderRadius.all(Radius.circular(3)),
      side: BorderSide(width: 10, color: Colors.red,
      ),
    );
  }
}
```


I expect a fade-in animation of the buttons at the beginning and a fade-in and fade-out animation when clicking on a button.

But sometimes the buttons have a rendering error while blending in. The rendering problem does not appear when setting the elevation to 0.

![image](https://user-images.githubusercontent.com/49610365/190351204-ee6a4d65-91d5-464a-9bbb-d4a1a7956089.png)

Am I doing something wrong or is there a Problem with the current flutter version (Problem did not exisit with flutter 2.8.1).

Flutter Doctor:

C:\...\flutter_3_3_1\flutter\bin\flutter.bat doctor --verbose
[√] Flutter (Channel stable, 3.3.1, on Microsoft Windows [Version 10.0.19044.1889], locale de-DE)
    • Flutter version 3.3.1 on channel stable at C:\...\flutter_3_3_1\flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 4f9d92fbbd (8 days ago), 2022-09-06 17:54:53 -0700
    • Engine revision 3efdf03e73
    • Dart version 2.18.0
    • DevTools version 2.15.0

[√] Android toolchain - develop for Android devices (Android SDK version 31.0.0)
    • Android SDK at C:\...\AppData\Local\Android\sdk
    • Platform android-33, build-tools 31.0.0
    • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files\Google\Chrome\Application\chrome.exe

[√] Visual Studio - develop for Windows (Visual Studio Community 2019 16.9.5)
    • Visual Studio at C:\Program Files (x86)\Microsoft Visual Studio\2019\Community
    • Visual Studio Community 2019 version 16.9.31229.75
    • Windows 10 SDK version 10.0.19041.0

[√] Android Studio (version 2020.3)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.10+0-b96-7249189)

[√] IntelliJ IDEA Ultimate Edition (version 2021.1)
    • IntelliJ at C:\Program Files\JetBrains\IntelliJ IDEA 2020.3
    • Flutter plugin version 62.0.2
    • Dart plugin version 211.7798

[√] IntelliJ IDEA Ultimate Edition (version 2021.3)
    • IntelliJ at C:\Program Files\JetBrains\IntelliJ IDEA 2021.2.3
    • Flutter plugin version 70.0.3
    • Dart plugin version 213.7371

[√] Connected device (4 available)
    • Android SDK built for x86 (mobile) • emulator-5554 • android-x86    • Android 10 (API 29) (emulator)
    • Windows (desktop)                  • windows       • windows-x64    • Microsoft Windows [Version 10.0.19044.1889]
    • Chrome (web)                       • chrome        • web-javascript • Google Chrome 105.0.5195.102
    • Edge (web)                         • edge          • web-javascript • Microsoft Edge 105.0.1343.33

[√] HTTP Host Availability
    • All required HTTP hosts are available

• No issues found!
Process finished with exit code 0