Skip to content
pubscout

nitro_camera

0.0.3, released 2 weeks ago by shreeman.dev

High-performance camera plugin built on the Nitro FFI bridge with zero method-channel overhead.

$ flutter pub add nitro_camera
Source repository

What it does

Provides photo and video capture, code scanning, frame processing, and GPU filters. Built on the Nitro FFI bridge for zero method-channel overhead.

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

Use it when

  • You need high-performance camera capture and live frame processing without method-channel overhead.
  • You require built-in barcode and QR code scanning with background isolate decoding.
  • You want vision-camera-style declarative and imperative camera controls in Flutter.

Skip it when

  • Your target platforms do not include Android or iOS.
  • You only need to pick existing photos and videos from the device gallery rather than capturing live.

Strengths

  • Zero method-channel overhead using the Nitro FFI bridge.
  • Zero-copy frame hand-off and background isolate processing.
  • Comprehensive feature set including photo/video capture, live filters, and code scanning.

Weaknesses

  • Requires platform-specific setup including iOS usage descriptions in Info.plist.
  • Early version release (0.0.3) which may still have evolving APIs.

Setup

Kind
Plugin (native code)
Effort
Medium
Code generation
Yes (build_runner)
Direct dependencies
4

Requires iOS 13.0+ with camera, microphone, and photo library usage descriptions in Info.plist. Android permissions are merged automatically but require runtime requests.

import 'package:flutter/material.dart';
import 'package:nitro_camera/nitro_camera.dart';

class CameraScreen extends StatefulWidget {
  const CameraScreen({super.key});
  @override
  State<CameraScreen> createState() => _CameraScreenState();
}

class _CameraScreenState extends State<CameraScreen> {
  CameraController? _controller;

  @override
  void initState() {
    super.initState();
    _open();
  }

  Future<void> _open() async {
    await CameraController.requestCameraPermission();
    final devices = await CameraController.getAvailableCameraDevices();
    final back = devices.backCamera() ?? devices.first;
    final controller = CameraController(device: back, audio: true);
    await controller.initialize(fps: 30);
    setState(() => _controller = controller);
  }

  @override
  void dispose() {
    _controller?.dispose();
    super.dispose();
  }

  @override
  Widget build(BuildContext context) {
    final c = _controller;
    if (c == null || !c.isInitialized) {
      return const Center(child: CircularProgressIndicator());
    }
    return Stack(
      children: [
        Positioned.fill(child: CameraPreview(controller: c)),
      ],
    );
  }
}

Alternatives

Packages that do the same job and could replace nitro_camera.

  • camera

    Official Flutter camera plugin backed by the Flutter team with broad community usage.

  • mobile_scanner

    Dedicated high-performance QR and barcode scanner plugin if full camera and video controls are unnecessary.

Works with

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