Skip to content

[palette_generator]Fix PaletteGenerator.fromImageProvider region not scaled to fit image size. #200

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Sep 16, 2020

Conversation

akindone
Copy link
Contributor

ui.Image.size is pixel size of Image, but the param size is the dp size of the widget, and region is same the dp size.

static Future<PaletteGenerator> fromImageProvider(
    ImageProvider imageProvider, {
    Size size,
    Rect region,
    int maximumColorCount,
    List<PaletteFilter> filters,
    List<PaletteTarget> targets,
    Duration timeout = const Duration(seconds: 15),
  }) 

Copy link
Contributor

@gspencergoog gspencergoog left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR!

Indeed, this looks like it needed to be fixed.

32384589-a60f0e74-c078-11e7-9bc1-e5b5287aea9d

@gspencergoog gspencergoog merged commit 818c483 into flutter:master Sep 16, 2020
stuartmorgan-g pushed a commit that referenced this pull request Oct 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants