Skip to content

[image_picker] Improving Bitmap resize performance on Android #118383

@beroso

Description

@beroso

My team noticed a performance issue related to ImageResizer.resizeImageIfNeeded on Android. The method loads the Bitmap even if the resize is not necessary.

Plus the Bitmap.decodeFile operation can use much memory, leading to a runtime crash. So we suggest to use the approach explained on https://developer.android.com/topic/performance/graphics/load-bitmap#load-bitmap

Maybe it's related to other crash issues

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2Important issues not at the top of the work listc: performanceRelates to speed or footprint issues (see "perf:" labels)p: image_pickerThe Image Picker plugin.packageflutter/packages repository. See also p: labels.team-ecosystemOwned by Ecosystem teamtriaged-ecosystemTriaged by Ecosystem team

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions