-
Notifications
You must be signed in to change notification settings - Fork 29.7k
Description
Steps to reproduce
bug in Image.asset when specify a color – a thin boundary appears around the image. Depending on the width and height values, it will either render correctly or show the boundary (this tends to happen when dimensions are odd numbers).
This only happens with Impeller enabled; disabling Impeller makes the issue disappear.
Flutter version: 3.32.4
Repro on emulators:
• Pixel 8 Pro (API 30, Android 11)
• Medium Phone (API 35, Android 15.0)
It’s not yet confirmed whether this also occurs on physical devices.
Expected results
Expected behavior: The black image should be rendered correctly without any visible boundary artifacts.
Actual results
Actual behavior: The image is rendered with a black boundary around it. Depending on the device and image, that boundary may appear even more pronounced.
Code sample
Code sample
Scaffold(
...
body: Center(
child: Image.asset(
"assets/images/google.png",
color: Colors.black,
width: 187, // random odd numbers
height: 187, // random odd numbers
),
),
); // ScaffoldScreenshots or Video
Screenshots / Video demonstration
This happens in PNG images and specifying a color causes a bug.
From left to right:
- No color
- Impeller off
- Impeller on
Logs
Logs
log is normalFlutter Doctor output
Doctor output
[✓] Flutter (Channel stable, 3.32.4, on macOS 15.5 24F74 darwin-arm64, locale
ko-KR)
[✓] Android toolchain - develop for Android devices (Android SDK version 35.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 16.4)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2024.3)
[✓] VS Code (version 1.101.0)
[✓] Connected device (6 available)
[✓] Network resources
• No issues found!


