Skip to content

imageProvider ignores dimensions of ResizeImage #7

Description

@IvanDeluxe

Hi :)

First of all, thanks for the amazing package ❤

I cannot find information about this anywhere -- I'm getting unexpected results for the following code:

    final originalImage = AssetImage(silhouette['path']); // w100 h200
    final image = ResizeImage(
      originalImage,
      height: 100, // set the height to 100
    );
    
    return ImagePixels(
      imageProvider: image,
      builder: (context, img) {
        if (!img.hasImage) {
          return SizedBox();
        }
        
        print('${img.width}'); // 100
        print('${img.height}'); // 200

Is there a way to make ResizeImage work with ImagePixels?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions