Skip to content
pubscout

camera_avfoundation

0.11.1, released 4 weeks ago by flutter.dev

iOS implementation of the Flutter camera plugin providing preview, photo, and video capture.

WASM-ready
$ flutter pub add camera_avfoundation
Source repository

What it does

Implements the camera plugin for iOS, adding features like zero‑shutter‑lag still capture, custom video output paths, and video rotation handling. It works behind the scenes when you use the federated `camera` package on iOS.

AI-written summary of version 0.11.1, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need iOS‑specific camera capabilities
  • You require zero‑shutter‑lag photos or custom video file paths
  • You are using the federated `camera` plugin and want the iOS implementation

Skip it when

  • Your app targets only Android/Web and doesn't need iOS support
  • You don't need advanced iOS camera features and prefer a single cross‑platform package

Strengths

  • Full iOS support with latest iOS 17 features
  • Endorsed federated plugin – automatically included with `camera`
  • Allows custom video output paths and zero‑shutter‑lag capture

Weaknesses

  • iOS‑only – no effect on Android or Web
  • Requires manual Info.plist changes for file‑browser visibility
  • Depends on the main `camera` package for a complete solution

Setup

Kind
Plugin (native code)
Effort
Low
Code generation
No
Direct dependencies
3

If using custom video output paths, add LSSupportsOpeningDocumentsInPlace and UISupportsDocumentBrowser keys (set to true) in ios/Runner/Info.plist.

import 'package:camera/camera.dart';

Future<void> record() async {
  final cameras = await availableCameras();
  final controller = CameraController(cameras.first, ResolutionPreset.max);
  await controller.initialize();
  await controller.startVideoRecording();
  // ...
  await controller.stopVideoRecording();
}

Alternatives

Packages that do the same job and could replace camera_avfoundation.

Works with

Packages commonly used together with camera_avfoundation: ones it builds on, ones built on it, and its own family.