This shows you the differences between two versions of the page.
| Both sides previous revision Previous revision Next revision | Previous revision | ||
|
products:sbc:edge-2l:applications:hardware-encoding [2026/02/26 01:20] gray Modify non-standard placese |
products:sbc:edge-2l:applications:hardware-encoding [2026/05/11 02:45] (current) nick |
||
|---|---|---|---|
| Line 1: | Line 1: | ||
| ====== Edge-2L hardware encoding ====== | ====== Edge-2L hardware encoding ====== | ||
| - | ===== Introduction ===== | + | {{page>products:sbc:edge2:applications: |
| - | + | ||
| - | This document explains how to utilize hardware-accelerated video encoding on the Edge-2L using the Rockchip MPP (Media Process Platform) framework. | + | |
| - | + | ||
| - | ===== Eencoding ===== | + | |
| - | + | ||
| - | <WRAP important | + | |
| - | If you encounter a permission error, try prefixing the commands with '' | + | |
| - | </ | + | |
| - | + | ||
| - | 1. Verify available MPP encoders | + | |
| - | + | ||
| - | First, check that the GStreamer MPP plugins are installed and recognized: | + | |
| - | + | ||
| - | ```shell | + | |
| - | khadas@Khadas:~$ gst-inspect-1.0 | grep mpp | + | |
| - | rockchipmpp: | + | |
| - | rockchipmpp: | + | |
| - | rockchipmpp: | + | |
| - | rockchipmpp: | + | |
| - | rockchipmpp: | + | |
| - | rockchipmpp: | + | |
| - | typefindfunctions: | + | |
| - | + | ||
| - | ``` | + | |
| - | + | ||
| - | 2. Encode a raw YUV (NV12) file to H264 | + | |
| - | + | ||
| - | Encode a raw YUV file (test.yuv) in NV12 format to a raw H.264 elementary stream (test.h264). Adjust the width and height parameters to match your source video resolution. | + | |
| - | + | ||
| - | ```shell | + | |
| - | khadas@Khadas: | + | |
| - | Setting pipeline to PAUSED ... | + | |
| - | Pipeline is PREROLLING ... | + | |
| - | Pipeline is PREROLLED ... | + | |
| - | Setting pipeline to PLAYING ... | + | |
| - | Redistribute latency... | + | |
| - | New clock: GstSystemClock | + | |
| - | 0:00:16.1 / 0:12:05.0 (2.2 %) | + | |
| - | ^Chandling interrupt. (2.8 %) | + | |
| - | + | ||
| - | ``` | + | |
| - | + | ||
| - | 3. Capture and encode from a USB camera | + | |
| - | + | ||
| - | The following examples capture JPEG frames from a USB camera, decode them using the MPP JPEG decoder, and then hardware-encode the video stream to H264. | + | |
| - | + | ||
| - | ```shell | + | |
| - | khadas@Khadas: | + | |
| - | ``` | + | |
| - | + | ||
| - | You can adapt these pipelines for other encoding | + | |