native_cutout
0.4.0, released 7 weeks ago by an unverified publisher
On-device background removal for iOS and Android using native vision and segmentation APIs.
What it does
Removes the background from a local image file entirely on-device, producing a transparent PNG. It uses the iOS Vision framework and Google Android ML Kit subject segmentation, supporting optional subject cropping and model download management.
AI-written summary of version 0.4.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- You need to remove image backgrounds locally without external APIs or keys.
- You target iOS 17+ and Android devices with Google Play services.
Skip it when
- You need to run on older iOS versions below 17.0.
- You require background removal to work on the iOS simulator.
Strengths
- Fully on-device processing with no external APIs or upload steps required.
- Provides optional caching, in-memory bytes, and bounding box extraction.
- Includes Android model download progress monitoring and lifecycle helpers.
Weaknesses
- iOS runtime processing requires iOS 17+ and a real device.
- Android model requires an initial on-demand download via Google Play services.
Setup
- Kind
- Plugin (native code)
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 1
No Podfile or AndroidManifest changes required. Android requires Google Play services for on-demand ML Kit model downloads.
import 'package:native_cutout/native_cutout.dart';
final result = await NativeCutout.removeBackground(imagePath);
if (result is CutoutFileSuccess) {
print('Saved to: ${result.path}');
}Alternatives
Packages that do the same job and could replace native_cutout.
- google_ml_kit
Umbrella Flutter plugin for Google's standalone ML Kit APIs.
86Compare - google_mlkit_subject_segmentation
Flutter plugin for Google's ML Kit Subject Segmentation API to separate subjects from backgrounds.
79Compare - google_mlkit_selfie_segmentation
Flutter plugin to use Google's ML Kit Selfie Segmentation API.
87Compare - face_detection_tflite
Advanced face & landmark detection, embedding and segmentation using on-device LiteRT (formerly TensorFlow Lite) models.
80Compare
Works with
Packages commonly used together with native_cutout: ones it builds on, ones built on it, and its own family.