google_mlkit_selfie_segmentation 0.2.0 copy "google_mlkit_selfie_segmentation: ^0.2.0" to clipboard
google_mlkit_selfie_segmentation: ^0.2.0 copied to clipboard

Flutter plugin to use Google's ML Kit Selfie Segmentation API to easily separate the background from users within a scene and focus on what matters.

Google's ML Kit Selfie Segmentation for Flutter #

Pub Version analysis Star on Github License: MIT

A Flutter plugin to use Google's ML Kit Selfie Segmentation API to easily separate the background from users within a scene and focus on what matters.

Getting Started #

Before you get started read about the requirements and known issues of this plugin here.

Usage #

Selfie Segmenter #

Create an instance of InputImage

Create an instance of InputImage as explained here.

final InputImage inputImage;

Create an instance of SelfieSegmenter

final segmenter = SelfieSegmenter(
  mode: SegmenterMode.stream,
  enableRawSizeMask: true,
);

Process image

final mask = await segmenter.processImage(inputImage);

Release resources with close()

segmenter.close();

Example app #

Find the example app here.

Contributing #

Contributions are welcome. In case of any problems look at existing issues, if you cannot find anything related to your problem then open an issue. Create an issue before opening a pull request for non trivial fixes. In case of trivial fixes open a pull request directly.

21
likes
0
pub points
88%
popularity

Publisher

verified publisherflutter-ml.dev

Flutter plugin to use Google's ML Kit Selfie Segmentation API to easily separate the background from users within a scene and focus on what matters.

Repository (GitHub)
View/report issues

License

unknown (LICENSE)

Dependencies

flutter, google_mlkit_commons

More

Packages that depend on google_mlkit_selfie_segmentation