@[TOC](FPV Camera(RPI3+V2.1) | wfb_ng Release 23.01 | Ubuntu 20.04 xfce软解测试)
与其他Linux桌面系统相比,Xfce消耗更少的CPU,仅使用1%的CPU。因此低CPU是Xfce的独特卖点之一。在FPV Camera(RPI3+V2.1) | wfb_ng Release 23.01 | Intel® Core™2 Duo CPU T6570 @ 2.10GHz 测试上,发现genome在720P 60FPS时,H264解码占用大量CPU资源,因此我们尝试减少桌面系统对CPU的占用率来看看有什么新的发现。
xfce安装
$ sudo apt install tasksel
$ sudo tasksel install xubuntu-desktop
$ sudo apt install xfce4
$ sudo apt install xfce4-goodies
浏览器firefox无法上网,使用chromium替换
$ sudo apt-get remove firefox
$ sudo apt-get install chromium-browser
重启系统使用xfce桌面
$ sudo reboot
gst-launch-1.0 v4l2src do-timestamp=true io-mode=mmap device=/dev/video0 \
extra-controls="controls,image_stabilization=1,h264_profile=4,h264_i_frame_period=60,h264_level=11,power_line_frequency=1,exposure_metering_mong=1,exposure_dynamic_framerate=0,scene_mode=0,video_bitrate_mode=1,video_bitrate=2000000,repeat_sequence_header=1" \
! video/x-h264,profile=high,width=1280,height=720,framerate=30/1,stream-format=byte-stream \
! h264parse disable-passthrough=true ! rtph264pay config-interval=1 pt=96 mtu=1400 aggregate-mode=zero-latency ! udpsink host=127.0.0.1 port=5602 sync=false
gst1280x720@fps30
gst-launch-1.0 v4l2src do-timestamp=true io-mode=mmap device=/dev/video0 \
extra-controls="controls,image_stabilization=1,h264_profile=4,h264_i_frame_period=60,h264_level=11,power_line_frequency=1,exposure_metering_mong=1,exposure_dynamic_framerate=0,scene_mode=0,video_bitrate_mode=1,video_bitrate=2000000,repeat_sequence_header=1" \
! video/x-h264,profile=high,width=1280,height=720,framerate=45/1,stream-format=byte-stream \
! h264parse disable-passthrough=true ! rtph264pay config-interval=1 pt=96 mtu=1400 aggregate-mode=zero-latency ! udpsink host=127.0.0.1 port=5602 sync=false
gst1280x720fxce@fps45
gst-launch-1.0 v4l2src do-timestamp=true io-mode=mmap device=/dev/video0 \
extra-controls="controls,image_stabilization=1,h264_profile=4,h264_i_frame_period=60,h264_level=11,power_line_frequency=1,exposure_metering_mong=1,exposure_dynamic_framerate=0,scene_mode=0,video_bitrate_mode=1,video_bitrate=2000000,repeat_sequence_header=1" \
! video/x-h264,profile=high,width=1280,height=720,framerate=60/1,stream-format=byte-stream \
! h264parse disable-passthrough=true ! rtph264pay config-interval=1 pt=96 mtu=1400 aggregate-mode=zero-latency ! udpsink host=127.0.0.1 port=5602 sync=false
gst1280x720fxce@fps60
gst-launch-1.0 v4l2src do-timestamp=true io-mode=mmap device=/dev/video0 \
extra-controls="controls,image_stabilization=1,h264_profile=4,h264_i_frame_period=60,h264_level=11,power_line_frequency=1,exposure_metering_mong=1,exposure_dynamic_framerate=0,scene_mode=0,video_bitrate_mode=1,video_bitrate=2000000,repeat_sequence_header=1" \
! video/x-h264,profile=high,width=800,height=600,framerate=60/1,stream-format=byte-stream \
! h264parse disable-passthrough=true ! rtph264pay config-interval=1 pt=96 mtu=1400 aggregate-mode=zero-latency ! udpsink host=127.0.0.1 port=5602 sync=false
gst800x600fxce@fps60
gst-launch-1.0 v4l2src do-timestamp=true io-mode=mmap device=/dev/video0 \
extra-controls="controls,image_stabilization=1,h264_profile=4,h264_i_frame_period=60,h264_level=11,power_line_frequency=1,exposure_metering_mong=1,exposure_dynamic_framerate=0,scene_mode=0,video_bitrate_mode=1,video_bitrate=2000000,repeat_sequence_header=1" \
! video/x-h264,profile=high,width=640,height=480,framerate=60/1,stream-format=byte-stream \
! h264parse disable-passthrough=true ! rtph264pay config-interval=1 pt=96 mtu=1400 aggregate-mode=zero-latency ! udpsink host=127.0.0.1 port=5602 sync=false
gst640x480fxce@fps60
gst-launch-1.0 v4l2src do-timestamp=true io-mode=mmap device=/dev/video0 \
extra-controls="controls,image_stabilization=1,h264_profile=4,h264_i_frame_period=60,h264_level=11,power_line_frequency=1,exposure_metering_mong=1,exposure_dynamic_framerate=0,scene_mode=0,video_bitrate_mode=1,video_bitrate=2000000,repeat_sequence_header=1" \
! video/x-h264,profile=high,width=480,height=320,framerate=60/1,stream-format=byte-stream \
! h264parse disable-passthrough=true ! rtph264pay config-interval=1 pt=96 mtu=1400 aggregate-mode=zero-latency ! udpsink host=127.0.0.1 port=5602 sync=false
gst480x320fxce@fps60
第一张:179 - 91 = 88 ms
第二张:331 - 243 = 88 ms
第三张:187 - 107= 80 ms
鉴于该模式下,整体视频出现卡顿,延时测试取消。
第二张:603 - 515 = 88 ms
第三张:499 - 419 = 80 ms
【1】wfb-ng Release 23.01镜像无头烧录&配置(2)
【2】wfb-ng Release 23.01镜像无头烧录&配置(1)
【3】wfb-ng 锁定WiFi接口
【4】Raspbian镜像无头烧录
【5】FPV Camera(RPI3+V2.1) | wfb_ng Release 23.01 | Intel® Core™2 Duo CPU T6570 @ 2.10GHz 测试
【6】How to install a web browser in XFCE?
【7】How install XFCE and remove gnome on Ubuntu 20.0.4 LTS
【8】How to Install XFCE Desktop or Xubuntu in Ubuntu 22.04|20.04
【9】Gnome vs Xfce Differences