Skip to content

[web] Image.network() drawing black if cacheWidth/cacheHeight set #160199

Description

@milke

Steps to reproduce

Stable version 3.27.0, Image.network() and FadeInImage.memoryNetwork() both draw black if cacheWidth/cacheHeight or imageCacheWidth/imageCacheHeight is set.

In Browser console: WebGL: INVALID_VALUE: texImage2D: The source data has been detached

On another note, I tried removing the cacheWidth/Height and Image eviction didn't work unless I refresh. Calling setState to refresh image didn't work either.

Expected results

I would expect an image to draw normally.

Actual results

The image draws black instead. Calling setState to refresh the image has no effect.

Code sample

N/A

Screenshots or Video

N/A

Logs

Browser console: WebGL: INVALID_VALUE: texImage2D: The source data has been detached

Flutter Doctor output

[✓] Flutter (Channel stable, 3.27.0, on Debian GNU/Linux 12 (bookworm)
    6.1.0-28-amd64, locale en_US.UTF-8)
    • Flutter version 3.27.0 on channel stable at
      /home/steve/development/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 8495dee1fd (27 hours ago), 2024-12-10 14:23:39 -0800
    • Engine revision 83bacfc525
    • Dart version 3.6.0
    • DevTools version 2.40.2
[✓] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at /home/steve/Android/Sdk
    • Platform android-34, build-tools 34.0.0
    • Java binary at: /home/steve/android-studio/jbr/bin/java
    • Java version OpenJDK Runtime Environment (build
      17.0.7+0-17.0.7b1000.6-10550314)
    • All Android licenses accepted.
[✓] Chrome - develop for the web
    • Chrome at google-chrome
[✓] Linux toolchain - develop for Linux desktop
    • Debian clang version 14.0.6
    • cmake version 3.25.1
    • ninja version 1.11.1
    • pkg-config version 1.8.1
[✓] Android Studio (version 2023.1)
    • Android Studio at /home/steve/android-studio
    • Flutter plugin version 77.1.2
    • Dart plugin can be installed from:
      :hammer: https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build
      17.0.7+0-17.0.7b1000.6-10550314)
[✓] VS Code (version 1.95.3)
    • VS Code at /usr/share/code
    • Flutter extension version 3.102.0
[✓] Connected device (2 available)
    • Linux (desktop) • linux  • linux-x64      • Debian GNU/Linux 12 (bookworm)
      6.1.0-28-amd64
    • Chrome (web)    • chrome • web-javascript • Google Chrome 131.0.6778.139
[✓] Network resources
    • All expected network resources are available.
• No issues found!

Metadata

Metadata

Assignees

Labels

a: imagesLoading, displaying, rendering imagesc: regressionIt was better in the past than it is nowc: renderingUI glitches reported at the engine/skia or impeller rendering levele: web_canvaskitCanvasKit (a.k.a. Skia-on-WebGL) rendering backend for Webengineflutter/engine related. See also e: labels.found in release: 3.27Found to occur in 3.27found in release: 3.28Found to occur in 3.28has reproducible stepsThe issue has been confirmed reproducible and is ready to work onplatform-webWeb applications specificallyr: fixedIssue is closed as already fixed in a newer versionteam-webOwned by Web platform team

Type

No type
No fields configured for issues without a type.

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions