Skip to content
pubscout

flutter_quick_video_encoder

1.7.2, released 2 years ago by jamcorder.com

Encode raw RGB images and PCM audio directly to MP4 using hardware h264 encoders.

Repository archived
$ flutter pub add flutter_quick_video_encoder
Source repository

What it does

Encodes raw RGB pixel buffers and PCM audio frames into an MP4 video file using native hardware encoders (AVFoundation on iOS and MediaCodec on Android) without requiring FFmpeg.

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

Use it when

  • You need to generate video files programmatically from raw RGBA frames or widgets.
  • You want hardware-accelerated video encoding without bundled native libraries like FFmpeg.

Skip it when

  • You need to playback existing video files or stream video over a network.
  • You are editing, trimming, or compressing pre-existing video container files rather than rendering from raw frames.

Strengths

  • Zero external dependencies besides Flutter and system libraries.
  • Uses native hardware encoders for fast performance.
  • Supports audio encoding (PCM to m4a/audio tracks).

Weaknesses

  • Requires feeding raw frame buffers manually in a loop rather than processing existing video files.
  • Limited platform support (Android, iOS, macOS only).

Setup

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

Enable the platform configurations for Android, iOS, or macOS as required by your app.

await FlutterQuickVideoEncoder.setup(
    width: 1920,
    height: 1080,
    fps: 60,
    videoBitrate: 2500000,
    audioChannels: 1,
    audioBitrate: 64000,
    sampleRate: 44100,
    filepath: "/documents/video.mp4",
);
for(int i = 0; i < frameCount; i++) {
    Uint8List rgba = _renderVideoFrame(i);
    await FlutterQuickVideoEncoder.appendVideoFrame(rgba);
}
await FlutterQuickVideoEncoder.finish();

Alternatives

Packages that do the same job and could replace flutter_quick_video_encoder.

  • video_player

    Pick video_player if you need to play videos instead of encoding raw pixel data into a new video.