SDRAM的同步接口需要由一个统一的时钟信号控制,每个时钟周期传输一次数据。DDR SDRAM(也就是DDR)在每个时钟周期内能够传输两次数据,也就将SDRAM的数据传输了提升了一倍。也就是说DDR其实就是具有双倍数据传输率的SDRAM,在DRAM的基础上快上加快。
米尔5eV使用
vcu-demo-camera-encode-streamout.sh -v "/dev/video0" -s 1920x1080 -n 2000 -b 90000 -f --compressed-mode --gop-length 30 --cpb-size 3000 --address 192.168.1.61 -p 1234 -e 100
No camera device found at /dev/video0, please give correct path and try again
cd /usr/bin
cat vcu-demo-functions.sh
//可以看到所有内部函数编写
root@mys_zu5ev:/usr/bin# cat VCU-Examples-ReadMe.txt
Encode input yuv file using 8 encoder elements simultaneously.
Multistream Encoding:
Encode input yuv file using 8 encoder elements simultaneously.
gst-launch-1.0 filesrc location=input_nv12_1920x1080.yuv ! videoparse width=1920 height=1080 format=nv12 framerate=30/1 ! tee name=t t. ! queue ! omxh264enc control-rate=2 target-bitrate=8000 ! video/x-h264, profile=high ! filesink location= ouput_0.h264 t. ! queue ! omxh264enc control-rate=2 target-bitrate=8000 ! video/x-h264, profile=high ! filesink location=ouput_1.h264 t. ! queue ! omxh264enc control-rate=2 target-bitrate=8000 ! video/x-h264, profile=high ! filesink location= ouput_2.h264 t. ! queue ! omxh264enc control-rate=2 target-bitrate=8000 ! video/x-h264, profile=high ! filesink location= ouput_3.h264 t. ! queue ! omxh264enc control-rate=2 target-bitrate=8000 ! video/x-h264, profile=high ! filesink location= ouput_4.h264 t. ! queue ! omxh264enc control-rate=2 target-bitrate=8000 ! video/x-h264, profile=high ! filesink location= ouput_5.h264 t.
! queue ! omxh264enc control-rate=2 target-bitrate=8000 ! video/x-h264, profile=high ! filesink location= ouput_6.h264 t. ! queue ! omxh264enc control-rate=2 target-bitrate=8000 ! video/x-h264, profile=high ! filesink location= ouput_7.h264
For different input yuv formats following changes are required in above pipeline:
4:2:2-8bit (NV16): format=nv16 and profile=high-4:2:2
4:2:0-10bit (NV12_10LE32): format=nv12-10le32 and profile=high-10
4:2:2-10bit (NV16_10LE32): format=nv16-10le32 and profile=high-4:2:2
Note: tee element is used to feed same input file into 8 encoder instances, user can use separate gst-launch-1.0 application to feed different inputs
Openmax Examples
�"omx_decoder –help�" shows all the options for decoder application
�"omx_encoder –help�" shows all the options for encoder application
Decode File to File:
omx_decoder input-file.h265 -hevc -o out.yuv
Encode File to File:
omx_encoder inputfile.yuv --width 352 --height 288 --framerate 30 --avc --out out.h264
(Note: Input YUV file should be in NV12 format)
root@mys_zu5ev:/usr/bin# zynqmp_vcu_encode --help
Usage:
zynqmp_vcu_encode [OPTION?] vcu encode test applicaiton
Dynamic Bitrate Ex: ./zynqmp_vcu_encode -w 3840 -h 2160 -e avc -f 30 -c 2 -g 30 -p '<333, 166, 0>' -o /run/op.h264 -i /run/input.yuv -d BR:100:1000
Dynamic Bframes Ex: ./zynqmp_vcu_encode -w 3840 -h 2160 -e hevc -f 30 -c 2 -g 30 -p '<333, 166, 0>' -b 4 -o /run/op.h265 -i /run/input.yuv -d BFrm:10:2
ROI Ex: ./zynqmp_vcu_encode -w 3840 -h 2160 -e avc -f 30 -c 2 -g 30 -p '<333, 166, 0>' -o /run/op.h264 -i /run/input.yuv -d ROI:10:1200x300:200x200:high -q 1