[AI Development Lab] [控制中心插件] 一款面向 Deepin / UOS v25 桌面的动态视频壁纸插件
Tofloor
poster avatar
努力的人儿
deepin
2026-08-15 14:23
Author

Deepin 社区「10 亿 Token 奖池,写出属于你的 deepin 桌面插件」活动参赛作品

方向三:方向一 控制中心插件

项目简介

deepin-meme-plugin 是面向 Deepin / UOS v25 桌面的动态视频壁纸插件,由「桌面边缘插件」与「控制中心插件」两部分组成,让桌面壁纸动起来的同时,提供友好的管理界面与强大的视频兼容能力。本来打算做趣味桌面壁纸的,包含动效和音效结合,奈何token已用爆表了,精力有限,暂时搁置。

申明

本项目视频都是我从网上下载的,且本项目不涉及盈利目的,如涉及侵权,请联系我删除处理。

项目地址

https://github.com/liujianqiang-niu/deepin-meme-plugin/tree/master

目前只支持amd64架构,可直接通过deb包安装再deepin/uos v25环境

https://github.com/liujianqiang-niu/deepin-meme-plugin/releases

上图

在控制中心,个性化里面,支持预览以及一键启用

1.png

支持手动上传,并自动转码,并显示进度条

2.png

桌面展示,实际是动图

5.png

桌面展示,实际是动图

7.png

主要特性

🎬 视频壁纸渲染

  • FFmpeg 高性能解码:支持 H264 / H265 / AV1 / VP9 等主流视频编码。
  • 多级硬件加速:软解 + VAAPI + CUDA 三级解码模式,auto 模式下自动探测最优硬件路径。
  • 桌面嵌入渲染:视频帧直接嵌入桌面 root 窗口,与桌面融为一体,无独立窗口干扰。
  • 多屏支持:多显示器场景下共享同一渲染资源,保持画面同步。
  • 流畅帧率控制:默认跟随视频源帧率,支持自定义帧率上限(1 ~ 240 FPS),解码超负荷时自动丢帧保实时。

🖼️ 显示模式

支持 5 种铺屏方式,适配不同分辨率与画幅:

模式 说明
铺满(fill) 等比放大裁切,无黑边(默认)
自适应(fit) 完整显示,可能带黑边
拉伸(stretch) 拉满屏幕,可能变形
居中(center) 原始像素居中,不缩放
平铺(tile) 重复铺满屏幕

⚙️ 控制中心管理

「控制中心 → 个性化 → 动态壁纸」提供一站式管理:

  • 一键启用:开关控制动态壁纸的启用与停用。
  • 视频上传:支持 mp4 / mkv / webm / avi / mov 等常见格式。
  • 智能自动转码:上传非 H264 视频(如 AV1 / HEVC)自动转码为 H264 MP4,保证兼容性。
  • 转码进度条:转码过程实时显示进度,可随时取消。
  • 壁纸预览:点击「预览」可在管理页直接播放查看效果。
  • 壁纸管理:预置壁纸与用户上传壁纸统一网格展示,支持应用与删除。

🖱️ 桌面右键菜单

桌面空白处右键即可快速「设置动态壁纸 / 打开设置」,无需进入控制中心。

🧩 预置壁纸

内置 5 个精选动态壁纸视频资源(含 4K 分辨率),开箱即用。

预置视频均为 H264 MP4 编码,单文件小于 50 MB(可直接从源码仓库 data/res/ 目录获取):

文件 分辨率 大小
【哲风壁纸】二次元-仙鹤_3840x2160.mp4 3840 × 2160 10.4 MB
【哲风壁纸】二次元-动态壁纸_3840x2160.mp4 3840 × 2160 5.3 MB
【哲风壁纸】亡灵-动态-头骨.mp4 1920 × 1080 9.6 MB
【哲风壁纸】光之巨人-光线技能_1920x1080.mp4 1920 × 1080 5.9 MB
【哲风壁纸】动态-奇幻-恐怖.mp4 1920 × 1080 4.1 MB

打包时这些视频随 deepin-meme-plugin-data 包安装至 /usr/share/deepin-meme-wallpapers/,构建流程直接从 data/res/ 使用现成文件,不受仓库历史大小影响。

🌐 国际化

内置中英文翻译,随系统语言自动适配。

使用说明

  1. 打开「控制中心 → 个性化 → 动态壁纸」。
  2. 打开「启用动态壁纸」开关。
  3. 从列表中点击「预览」查看效果,或直接点击「应用」设为壁纸。
  4. 点击「选择视频上传」导入本地视频,非 H264 格式将自动转码并显示进度。
  5. 桌面空白处右键亦可快速设置动态壁纸。

配置

本插件使用 DConfig 统一管理配置,应用 ID 为 org.deepin.meme,边缘插件与控制中心插件共享同一套配置数据。

配置项一览

键 类型 默认值 配置入口 说明
enabled bool false 控制中心开关 是否启用动态壁纸
currentVideo string "" 控制中心「应用」 当前动态壁纸视频绝对路径
decodeMode string "software" 配置文件 解码模式:software / cuda / vaapi / auto
fillMode string "fill" 配置文件 铺屏方式:fill / fit / stretch / center / tile

其中 enabled 与 currentVideo 可由控制中心界面直接操作并自动写回配置;decodeMode 与 fillMode 暂未提供图形化入口,需通过下述配置方式进行设置。

配置方式

DConfig 采用「默认值 → 系统级覆盖 → 用户级覆盖」的优先级,默认值由 schema(/usr/share/dsg/configs/org.deepin.meme/org.deepin.meme.json)提供,用户配置写入 override 文件。

用户级配置(仅当前用户生效,推荐)

mkdir -p ~/.config/deepin/org.deepin.meme
cat > ~/.config/deepin/org.deepin.meme/override.json <<'EOF'
{
    "decodeMode": "auto",
    "fillMode": "fit"
}
EOF

系统级配置(对所有用户生效,需 root)

sudo mkdir -p /etc/dsg/configs/org.deepin.meme
sudo tee /etc/dsg/configs/org.deepin.meme/override.json > /dev/null <<'EOF'
{
    "decodeMode": "vaapi",
    "fillMode": "fill"
}
EOF

修改配置后,重启桌面服务使边缘插件重新读取:

systemctl --user restart dde-shell-plugin@org.deepin.ds.desktop.service

提示:也可通过 dconf-editor 等 DConfig 图形工具查看与修改各键值。

配置项详解

decodeMode(解码模式)

值 说明
software 纯软件解码,兼容性最好,CPU 占用高
cuda NVIDIA 独显硬件解码
vaapi 核显 / 通用硬件解码
auto 自动探测:优先 CUDA → VAAPI → 软件解码回退

fillMode(铺屏方式)

值 说明
fill 等比放大裁切,铺满屏幕无黑边(默认)
fit 完整显示整个画面,可能有黑边
stretch 拉伸至满屏,可能变形
center 原始像素居中显示,不缩放
tile 重复平铺铺满屏幕

环境要求

依赖 版本要求
Qt6 >= 6.8
Dtk6 >= 6.7
FFmpeg libavformat / libavcodec / libavutil / libswscale
dde-file-manager 运行依赖
dde-control-center >= 6.1
ffmpeg(命令行) 上传转码依赖

构建与安装

源码构建

cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_INSTALL_PREFIX=/usr
cmake --build build -j$(nproc)

Debian 打包

dpkg-buildpackage -us -uc -b

生成两个安装包:

  • deepin-meme-plugin:两个插件二进制(边缘插件 + 控制中心插件)。
  • deepin-meme-plugin-data:预置视频资源与 DConfig schema。

安装后自动重启桌面服务以加载新插件,无需手动操作。

安装产物

组件 路径
边缘插件 /usr/lib//dde-file-manager/plugins/desktop-edge/libdd-meme-wallpaper-plugin.so.3.0.0
控制中心插件 /usr/lib//dde-control-center/plugins_v1.1/meme/
预置视频 /usr/share/deepin-meme-wallpapers/
DConfig schema /usr/share/dsg/configs/org.deepin.meme/org.deepin.meme.json
Reply Favorite View the author
All Replies
avatar
努力的人儿
deepin
2026-08-15 14:27
#1

本项目欢迎大佬们继续扩展功能参与贡献!!!applaud

Reply View the author
avatar
Ligocut光剪视频剪辑软件
deepin
Backbone of ecological co-construction group
2026-08-15 16:17
#2

Deepin的控制中心原来还能这样用的....

Reply View the author
avatar
𰻞𰻝面
deepin
2026-08-16 10:54
#3

这个必须点赞!kissing_heart

Reply View the author
avatar
Jokul
deepin
2026-08-16 14:51
#4

这个百姓需求必须点赞like

Reply View the author
avatar
努力的人儿
deepin
2026-08-17 10:06
#5

版本升级到3.1.0 了,修了一点显示bug,deb包已支持amd64/arm64/loong64 ,下载地址如下:

https://github.com/liujianqiang-niu/deepin-meme-plugin/releases#release-3.1.0

Reply View the author
avatar
𰻞𰻝面
deepin
2026-08-17 14:44
#6
努力的人儿:

版本升级到3.1.0 了,修了一点显示bug,deb包已支持amd64/arm64/loong64 ,下载地址如下:

https://github.com/liujianqiang-niu/deepin-meme-plugin/releases#release-3.1.0

优秀!!

Reply View the author
avatar
柒玖
deepin
2026-08-27 16:44
#7

环境:deepin 25.2.1 amd64(Intel N150) deepin-meme-plugin_3.1.0_amd64.deb 包安装
安装运行:顺利
亮点:壁纸与桌面集成良好,桌面右键菜单方便快捷

image.png

问题:1.桌面右键菜单与控制中心开关不完全实时同步,控制中心的开关状态可与右键菜单同步,但右键菜单的动态壁纸开关状态需在控制中心重启后才能同步给控制中心的开关

image.png

2.VA-API硬件解码未生效(设置用户级配置和系统级配置均未生效)

image.png

文件存在且内容无误
image.png

使用intel_gpu_top检查核显占用情况

image.png

相同壁纸及环境下使用VA-API的Fresco可正常硬解

image.png

Reply View the author
avatar
骑🐖追帅哥bot
Moderator
2026-08-28 10:59
#8
柒玖:

环境:deepin 25.2.1 amd64(Intel N150) deepin-meme-plugin_3.1.0_amd64.deb 包安装
安装运行:顺利
亮点:壁纸与桌面集成良好,桌面右键菜单方便快捷

image.png

问题:1.桌面右键菜单与控制中心开关不完全实时同步,控制中心的开关状态可与右键菜单同步,但右键菜单的动态壁纸开关状态需在控制中心重启后才能同步给控制中心的开关

image.png

2.VA-API硬件解码未生效(设置用户级配置和系统级配置均未生效)

image.png

文件存在且内容无误
image.png

使用intel_gpu_top检查核显占用情况

image.png

相同壁纸及环境下使用VA-API的Fresco可正常硬解

image.png

成功参与!

Reply View the author
avatar
r***i@gmail.com
deepin
2026-08-30 13:04
#9
It has been deleted!
avatar
r***i@gmail.com
deepin
2026-08-30 13:04
#10
It has been deleted!
avatar
r***i@gmail.com
deepin
2026-08-30 13:05
#11

Let's start with the conclusion: This plugin has opened up the path of "desktop edge plugin" and is of great value to our type of live wallpaper project.

I am the developer of Fresco (a Linux live wallpaper project, also GPL-3.0, https://github.com/DibbayajyotiRoy/fresco), and the interface is in Chinese. #7Foundation 79 mentioned us in the comparison test, so sharing the pit we stepped into first can be considered a small reward.[](https://github.com/DibbayajyotiRoy/fresco)

## A test result that can support your thinking

We tested on Deepin 25: After setting the DDE wallpaper to fully transparent PNG, the desktop window of dde-shell is****Synthetic to black**** on, rather than compositing to the window below it. We put a solid red window underneath, completely invisible. That is, **Any window stacked under that desktop window will never be seen**.

Therefore, external processes only have the option of "lifting their own window onto the desktop window", and if the DDE wallpaper and desktop icon are drawn in the same window, lifting it will inevitably cover the icon. We can only use a compromise for now: give way for a few seconds when clicking on the desktop to make the icon appear.

This line in your plugin is exactly the one we haven't found yet:'bwp->setProperty(DesktopFrameProperty::kPropWidgetLevel, 5.1);`

Cooperate with hiding 'kPropWidgetName == "background"\The child control of ', with the wallpaper below and the icon above, 5.1 falls exactly in the middle of the two, and this level is out of reach outside the process. This path is right; according to our measurements,**It is the only way to display both video and desktop icons**.

## Regarding the VA-API issue on the #7th floor

I took the liberty of taking a look 'decoder.cpp', hard solving this part itself is written correctly:`av_hwdevice_ctx_create` → `get_format` → `av_hwframe_transfer_data` All of them. So it's more likely **Configuration did not reach the decoder**, not that there is a problem with the decoding path. Two directions to check first:

  1. User-level override path written in README `~/.config/deepin/org.deepin.meme/override.json' may not be the location where the DSG actually reads the user configuration. Can be 'WallpaperEnginePrivate::playOptions()' The final parsed 'decodeMode' Type a log to confirm that the plugin got 'vaapi` Or it fell back to \software`. This step can directly distinguish between "configuration not read" and "hard solution failed to fall back".
  2. The edge plugin and the control center plugin are two processes. After the DConfig is modified, is the edge plugin side actually reread (that is, in the README 'systemctl --user restart dde-shell-plugin@org.deepin.ds.desktop.service` That step).

Also, let me state an expectation in advance to avoid being too happy: even if VA-API is enabled normally, because the "embedded QWidget" architecture requires CPU side-by-side graphics, each frame still needs to be `av_hwframe_transfer_data` Return to memory, then `sws_scale' into BGRA. Decoding itself is on the GPU, but this readback overhead cannot be saved. This is not a problem of implementation, but an inherent cost of this path. If we go down this path, we'll have to pay the same amount of money.

If these two are placed in the warehouse issue for easier tracking, I can open one and ask here first to avoid being presumptuous.

## Two questions

  1. If we submit contributions to decoding this area (such as stabilizing the hard solution path and opening the configuration link), is it convenient for you to accept PR?
  2. Do you think this layered approach to desktop edge plugins is suitable for reuse by other wallpaper programs? We are considering making a Deepin plugin for Fresco that uses the same interface; it would be better to do it together or contribute directly to your side than to do it separately.

Regardless, this plugin desires a thumbs up it answers a question we haven't been able to resolve since 1.1.3.

Reply View the author
avatar
努力的人儿
deepin
2026-09-02 15:04
#12
r***i@gmail.com:

Let's start with the conclusion: This plugin has opened up the path of "desktop edge plugin" and is of great value to our type of live wallpaper project.

I am the developer of Fresco (a Linux live wallpaper project, also GPL-3.0, https://github.com/DibbayajyotiRoy/fresco), and the interface is in Chinese. #7Foundation 79 mentioned us in the comparison test, so sharing the pit we stepped into first can be considered a small reward.[](https://github.com/DibbayajyotiRoy/fresco)

## A test result that can support your thinking

We tested on Deepin 25: After setting the DDE wallpaper to fully transparent PNG, the desktop window of dde-shell is****Synthetic to black**** on, rather than compositing to the window below it. We put a solid red window underneath, completely invisible. That is, **Any window stacked under that desktop window will never be seen**.

Therefore, external processes only have the option of "lifting their own window onto the desktop window", and if the DDE wallpaper and desktop icon are drawn in the same window, lifting it will inevitably cover the icon. We can only use a compromise for now: give way for a few seconds when clicking on the desktop to make the icon appear.

This line in your plugin is exactly the one we haven't found yet:'bwp->setProperty(DesktopFrameProperty::kPropWidgetLevel, 5.1);`

Cooperate with hiding 'kPropWidgetName == "background"\The child control of ', with the wallpaper below and the icon above, 5.1 falls exactly in the middle of the two, and this level is out of reach outside the process. This path is right; according to our measurements,**It is the only way to display both video and desktop icons**.

## Regarding the VA-API issue on the #7th floor

I took the liberty of taking a look 'decoder.cpp', hard solving this part itself is written correctly:`av_hwdevice_ctx_create` → `get_format` → `av_hwframe_transfer_data` All of them. So it's more likely **Configuration did not reach the decoder**, not that there is a problem with the decoding path. Two directions to check first:

  1. User-level override path written in README `~/.config/deepin/org.deepin.meme/override.json' may not be the location where the DSG actually reads the user configuration. Can be 'WallpaperEnginePrivate::playOptions()' The final parsed 'decodeMode' Type a log to confirm that the plugin got 'vaapi` Or it fell back to \software`. This step can directly distinguish between "configuration not read" and "hard solution failed to fall back".
  2. The edge plugin and the control center plugin are two processes. After the DConfig is modified, is the edge plugin side actually reread (that is, in the README 'systemctl --user restart dde-shell-plugin@org.deepin.ds.desktop.service` That step).

Also, let me state an expectation in advance to avoid being too happy: even if VA-API is enabled normally, because the "embedded QWidget" architecture requires CPU side-by-side graphics, each frame still needs to be `av_hwframe_transfer_data` Return to memory, then `sws_scale' into BGRA. Decoding itself is on the GPU, but this readback overhead cannot be saved. This is not a problem of implementation, but an inherent cost of this path. If we go down this path, we'll have to pay the same amount of money.

If these two are placed in the warehouse issue for easier tracking, I can open one and ask here first to avoid being presumptuous.

## Two questions

  1. If we submit contributions to decoding this area (such as stabilizing the hard solution path and opening the configuration link), is it convenient for you to accept PR?
  2. Do you think this layered approach to desktop edge plugins is suitable for reuse by other wallpaper programs? We are considering making a Deepin plugin for Fresco that uses the same interface; it would be better to do it together or contribute directly to your side than to do it separately.

Regardless, this plugin desires a thumbs up it answers a question we haven't been able to resolve since 1.1.3.

To be upfront about my availability, I should mention that due to work and family commitments, I can only set aside a limited amount of free time for development. That said, I’m genuinely glad to have you involved.

To address your questions:


  1. We would be absolutely delighted to accept a PR from you to fix the aforementioned issue. You are also very welcome to participate further and help expand other features of this project.
    
  2. Regarding the layered approach and its reusability for other wallpaper programs—I do think it has good potential. If you're considering making a Deepin plugin for Fresco using the same interface, I believe it would be much more efficient to collaborate on it directly within this repository (or jointly) rather than working separately.
    
    Looking forward to our cooperation!
Reply View the author
avatar
redeagle
deepin
2026-09-11 09:29
#13

agree

Reply View the author
avatar
Linux大宝
deepin
2026-10-16 16:55
#14
建议加载单一视频更改为加载文件夹
Reply View the author