Skip to content

Expose Paint.imageFilter from Skia to Flutter, possibly mimicking Paint.maskFilter (willing to make a PR) #101019

@fzyzcjy

Description

@fzyzcjy

Use case

Hi thanks for the lib! I need to draw some complex things (images + Paths) with complex effects (most notably, image filters #100830).

When directly using Skia, I see I can do it like (https://fiddle.skia.org/c/@Image_Filter_Methods):

    paint.setImageFilter(SkImageFilters::Blur(5.0f, 5.0f, nullptr));
    canvas->drawRegion(region, paint);

However, with Flutter's Paint class, it does not expose this method.

p.s. I know ImageFiltered widget can be used, but in my case I need some complex manipulation like filtering, unioning, diffing, etc, so would be best if I could paint it imperatively.

Proposal

Explose Paint.setImageFilter. (See above for details)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions