codec-lifecycle

command
v0.0.3 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Mar 16, 2026 License: MIT Imports: 3 Imported by: 0

Documentation

Overview

MediaCodec full lifecycle example.

Demonstrates the complete AMediaCodec state machine for an H.264 video decoder: create, configure, start, the buffer processing loop pattern, flush, stop, and close. The codec transitions through these states:

Created -> Configured -> Started -> (processing) -> Flushed -> Started -> Stopped -> Released

The input/output buffer loop is shown as documented comments because DequeueInputBuffer and DequeueOutputBuffer are not yet wrapped in the idiomatic layer. All other lifecycle methods are exercised for real.

This program must run on an Android device with NDK media support.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL