Khadas Docs

Amazing Khadas, always amazes you!

User Tools

Site Tools


products:sbc:edge2:applications:hardware-encoding

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
products:sbc:edge2:applications:hardware-encoding [2022/11/04 09:13]
frank
products:sbc:edge2:applications:hardware-encoding [2022/11/07 22:24]
frank
Line 23: Line 23:
 2. Encoding format ''NV12'' to ''H264''. 2. Encoding format ''NV12'' to ''H264''.
  
-``shell+```shell
 khadas@Khadas:~$ gst-launch-1.0 -v filesrc location=./test.yuv ! videoparse width=1920 height=1080 format=nv12 ! mpph264enc ! h264parse ! queue ! filesink location=./test.h264 khadas@Khadas:~$ gst-launch-1.0 -v filesrc location=./test.yuv ! videoparse width=1920 height=1080 format=nv12 ! mpph264enc ! h264parse ! queue ! filesink location=./test.h264
 Setting pipeline to PAUSED ... Setting pipeline to PAUSED ...
Line 35: Line 35:
  
 ``` ```
 +
 +3. Get data from USB camera and encode.
 +
 +```shell
 +khadas@Khadas:~$ gst-launch-1.0 v4l2src device=/dev/video33 io-mode=mmap num-buffers=300 ! image/jpeg, width=1920, height=1080, framerate=30/1 ! mppjpegdec ! mpph264enc ! filesink location=./test.h264
 +```
 +
 Other encoding formats are used similarly. Just replace the corresponding encoder. Other encoding formats are used similarly. Just replace the corresponding encoder.
  
Last modified: 2024/05/21 06:18 by jacobe