music icon indicating copy to clipboard operation
music copied to clipboard

Debian12Wayland下动画性能问题仍然存在

Open AXFOX opened this issue 1 year ago • 18 comments

上次提过ISSUE了。https://github.com/Sherlockouo/music/issues/66 不过当时QQ邮箱出了点问题,我没看见github的邮件。 image 我的个人感觉是,性能提升好像有,但是不多?😂 任重道远啊,开发者加油。我对Electron一窍不通,帮不了什么忙。


       _,met$$$$$gg.          xfox@ThinkPadE14Gen3 
    ,g$$$$$$$$$$$$$$$P.       -------------------- 
  ,g$$P"     """Y$$.".        OS: Debian GNU/Linux 12 (bookworm) x86_64 
 ,$$P'              `$$$.     Host: 20YEA001CD ThinkPad E14 Gen 3 
',$$P       ,ggs.     `$$b:   Kernel: 6.1.0-17-amd64 
`d$$'     ,$P"'   .    $$$    Uptime: 1 hour, 2 mins 
 $$P      d$'     ,    $$P    Packages: 3259 (dpkg), 6 (flatpak), 8 (snap) 
 $$:      $$.   -    ,d$$'    Shell: bash 5.2.15 
 $$;      Y$b._   _,d$P'      Resolution: 1920x1080 
 Y$$.    `.`"Y$$$$P"'         DE: Plasma 
 `$$b      "-.__              WM: kwin 
  `Y$$                        Theme: Breeze [Plasma], Breeze [GTK2/3] 
   `Y$$.                      Icons: [Plasma], breeze [GTK2/3] 
     `$$b.                    Terminal: konsole 
       `Y$$b.                 CPU: AMD Ryzen 5 5600U with Radeon Graphics (12) @ 2.300GHz 
          `"Y$b._             GPU: AMD ATI Radeon Vega Series / Radeon Vega Mobile Series 
              `"""            Memory: 4448MiB / 14805MiB 

如需提供额外信息请留言,目前通信通畅。我会在晚上回复。

AXFOX avatar Jan 18 '24 16:01 AXFOX

辛苦 晚上录一个视频,帮助debug。如果你会 react 欢迎 contribute。

Sherlockouo avatar Jan 19 '24 03:01 Sherlockouo

是基于2.7.3的吗,这个版本对wayland的性能理论来说是有提升的😊

yuzh0816 avatar Jan 19 '24 09:01 yuzh0816

辛苦 晚上录一个视频,帮助debug。如果你会 react 欢迎 contribute。

https://github.com/Sherlockouo/music/assets/57279704/d668d5ca-b302-4572-a1a6-f3b93801234e

明显掉祯,但是似乎比之前的更好。

AXFOX avatar Jan 19 '24 12:01 AXFOX

是基于2.7.3的吗,这个版本对wayland的性能理论来说是有提升的😊

提升确实有,但是从最终效果来看还是给人卡卡的感觉。还有很大优化空间

AXFOX avatar Jan 19 '24 12:01 AXFOX

尝试使用以下命令行选项启动呢

--enable-features=UseOzonePlatform,WaylandWindowDecorations \
--ozone-platform=wayland \
--ozone-platform-hint=auto

目前怀疑的方向有两个,mesa driver 和 xwayland

在我的 NixOS (hyperland) 上,R3PLAYX 的动效很流畅,不管是 AppImage 还是打包版,你也可以尝试一下 release 为 debian 打的 .deb 包

EndCredits avatar Jan 20 '24 13:01 EndCredits

尝试使用以下命令行选项启动呢

--enable-features=UseOzonePlatform,WaylandWindowDecorations \
--ozone-platform=wayland \
--ozone-platform-hint=auto

目前怀疑的方向有两个,mesa driver 和 xwayland

在我的 NixOS (hyperland) 上,R3PLAYX 的动效很流畅,不管是 AppImage 还是打包版,你也可以尝试一下 release 为 debian 打的 .deb 包

实际上我正是使用deb包 使用如下命令启动: xfox@ThinkPadE14Gen3:~$ /opt/R3PLAYX/desktop --enable-features=UseOzonePlatform,WaylandWindowDecorations --ozone-platform=wayland --ozone-platform-hint=auto 22:32:54 info ›


| |/ / / /_ () / __/ __ __ / |/ / __ __ _____ () _____ | / / / / / / / / / / / / /|_/ / / / / / / / / / / / / | / / / / / __/ / // / / / / / / // / ( ) / / / /
//|| _/ // // _, / // // _,/ // // ___/
/
_/

22:32:54 info › [logger] logger initialized 22:32:54 info › [electron] utils.ts 22:32:54 info › [preload] dirname /opt/R3PLAYX/resources/app.asar/main 22:32:54 info › [preload] userData path: /home/xfox/.config/R3PLAYX 22:32:54 info › [sentry] sentry initializing 22:32:54 info › [sentry] sentry initialized 22:32:54 info › [electron] db.ts 22:32:54 info › [db] Initializing database... 22:32:54 info › [db] Initializing database tables... 22:32:54 info › [db] Database tables initialized. 22:32:54 info › [db] Migrating database.. 22:32:54 info › [db] Database migrated. 22:32:54 info › [db] Database initialized. 22:32:54 info › [electron] cache.ts 22:32:54 info › [electron] store.ts 22:32:54 info › [electron] menu.ts 22:32:54 info › [electron] ipcMain.ts 22:32:54 info › [electron] tray.ts 22:32:54 info › [electron] windowsTaskbar.ts 22:32:54 info › [electron] appServer/routes/r3play/appleMusic.ts 22:32:54 info › [electron] appServer/routes/r3play/audio.ts 22:32:54 info › [electron] appServer/appServer.ts 22:32:54 info › [electron] index.ts 22:32:54 info › [index] Main process start 22:32:54 info › [index] App ready 22:32:54 info › [appServer] http server listening on port 42710 22:32:54 info › checkForUpdates 22:32:54 warn › APPIMAGE env is not defined, current application is not an AppImage 22:32:54 debug › checkForUpdatesAndNotify called, downloadPromise is null 22:32:55 debug › [server] Audio cache hit 531295576

效果和是一致,仍然有很强的迟滞感,还需要提供哪些信息? 另外我再尝试一下AppImage看看效果,后续情况我会继续更新到这个ISSUE 顺带一提,2.7.4的Release文件名和包内版本号忘了改了,而且打包的时候写了一个不太好的包名:desktop image

image

AXFOX avatar Jan 20 '24 14:01 AXFOX

尝试使用以下命令行选项启动呢

--enable-features=UseOzonePlatform,WaylandWindowDecorations \
--ozone-platform=wayland \
--ozone-platform-hint=auto

目前怀疑的方向有两个,mesa driver 和 xwayland

在我的 NixOS (hyperland) 上,R3PLAYX 的动效很流畅,不管是 AppImage 还是打包版,你也可以尝试一下 release 为 debian 打的 .deb 包

实际上我正是使用deb包 使用如下命令启动: xfox@ThinkPadE14Gen3:~$ /opt/R3PLAYX/desktop --enable-features=UseOzonePlatform,WaylandWindowDecorations --ozone-platform=wayland --ozone-platform-hint=auto 22:32:54 info ›


| |/ / / /_ () / __/ __ __ / |/ / __ __ _____ () _____ | / / / / / / / / / / / / /|_/ / / / / / / / / / / / / | / / / / / __/ / // / / / / / / // / ( ) / / / /
//|| _/ // // _, / // // _,/ // // ___/
/
_/

22:32:54 info › [logger] logger initialized 22:32:54 info › [electron] utils.ts 22:32:54 info › [preload] dirname /opt/R3PLAYX/resources/app.asar/main 22:32:54 info › [preload] userData path: /home/xfox/.config/R3PLAYX 22:32:54 info › [sentry] sentry initializing 22:32:54 info › [sentry] sentry initialized 22:32:54 info › [electron] db.ts 22:32:54 info › [db] Initializing database... 22:32:54 info › [db] Initializing database tables... 22:32:54 info › [db] Database tables initialized. 22:32:54 info › [db] Migrating database.. 22:32:54 info › [db] Database migrated. 22:32:54 info › [db] Database initialized. 22:32:54 info › [electron] cache.ts 22:32:54 info › [electron] store.ts 22:32:54 info › [electron] menu.ts 22:32:54 info › [electron] ipcMain.ts 22:32:54 info › [electron] tray.ts 22:32:54 info › [electron] windowsTaskbar.ts 22:32:54 info › [electron] appServer/routes/r3play/appleMusic.ts 22:32:54 info › [electron] appServer/routes/r3play/audio.ts 22:32:54 info › [electron] appServer/appServer.ts 22:32:54 info › [electron] index.ts 22:32:54 info › [index] Main process start 22:32:54 info › [index] App ready 22:32:54 info › [appServer] http server listening on port 42710 22:32:54 info › checkForUpdates 22:32:54 warn › APPIMAGE env is not defined, current application is not an AppImage 22:32:54 debug › checkForUpdatesAndNotify called, downloadPromise is null 22:32:55 debug › [server] Audio cache hit 531295576

效果和是一致,仍然有很强的迟滞感,还需要提供哪些信息? 另外我再尝试一下AppImage看看效果,后续情况我会继续更新到这个ISSUE 顺带一提,2.7.4的Release文件名和包内版本号忘了改了,而且打包的时候写了一个不太好的包名:desktop image

image

包名问题是我的失误😓,之后再更新修复这个问题。

有个问题哈,你说的原仓库是yesplaymusic还是r3的原仓库呢,因为现在这个版本对于性能要求比yesplaymusic要高一些,我看你显存只有1G,感觉似乎性能不够诶😲

yuzh0816 avatar Jan 21 '24 06:01 yuzh0816

尝试使用以下命令行选项启动呢

--enable-features=UseOzonePlatform,WaylandWindowDecorations \
--ozone-platform=wayland \
--ozone-platform-hint=auto

目前怀疑的方向有两个,mesa driver 和 xwayland 在我的 NixOS (hyperland) 上,R3PLAYX 的动效很流畅,不管是 AppImage 还是打包版,你也可以尝试一下 release 为 debian 打的 .deb 包

实际上我正是使用deb包 使用如下命令启动: xfox@ThinkPadE14Gen3:~$ /opt/R3PLAYX/desktop --enable-features=UseOzonePlatform,WaylandWindowDecorations --ozone-platform=wayland --ozone-platform-hint=auto 22:32:54 info ›

| |/ / / /_ () / __/ __ __ / |/ / __ __ _____ () _____ | / / / / / / / / / / / / /|_/ / / / / / / / / / / / / | / / / / / __/ / // / / / / / / // / ( ) / / / / //|| __/ // // __, / // // ,/ // // ___/ // 22:32:54 info › [logger] logger initialized 22:32:54 info › [electron] utils.ts 22:32:54 info › [preload] dirname /opt/R3PLAYX/resources/app.asar/main 22:32:54 info › [preload] userData path: /home/xfox/.config/R3PLAYX 22:32:54 info › [sentry] sentry initializing 22:32:54 info › [sentry] sentry initialized 22:32:54 info › [electron] db.ts 22:32:54 info › [db] Initializing database... 22:32:54 info › [db] Initializing database tables... 22:32:54 info › [db] Database tables initialized. 22:32:54 info › [db] Migrating database.. 22:32:54 info › [db] Database migrated. 22:32:54 info › [db] Database initialized. 22:32:54 info › [electron] cache.ts 22:32:54 info › [electron] store.ts 22:32:54 info › [electron] menu.ts 22:32:54 info › [electron] ipcMain.ts 22:32:54 info › [electron] tray.ts 22:32:54 info › [electron] windowsTaskbar.ts 22:32:54 info › [electron] appServer/routes/r3play/appleMusic.ts 22:32:54 info › [electron] appServer/routes/r3play/audio.ts 22:32:54 info › [electron] appServer/appServer.ts 22:32:54 info › [electron] index.ts 22:32:54 info › [index] Main process start 22:32:54 info › [index] App ready 22:32:54 info › [appServer] http server listening on port 42710 22:32:54 info › checkForUpdates 22:32:54 warn › APPIMAGE env is not defined, current application is not an AppImage 22:32:54 debug › checkForUpdatesAndNotify called, downloadPromise is null 22:32:55 debug › [server] Audio cache hit 531295576 效果和是一致,仍然有很强的迟滞感,还需要提供哪些信息? 另外我再尝试一下AppImage看看效果,后续情况我会继续更新到这个ISSUE 顺带一提,2.7.4的Release文件名和包内版本号忘了改了,而且打包的时候写了一个不太好的包名:desktop image image

包名问题是我的失误😓,之后再更新修复这个问题。

有个问题哈,你说的原仓库是yesplaymusic还是r3的原仓库呢,因为现在这个版本对于性能要求比yesplaymusic要高一些,我看你显存只有1G,感觉似乎性能不够诶😲

我使用web demo的时候很流畅。 我的设备搭载R5 5600U,虽是APU,可vega7倒也没弱到连这点动画特效都带不动。在这种场景下显存和GPU性能并没有太大关系。

AXFOX avatar Jan 21 '24 09:01 AXFOX

我的设备搭载R5 5600U,虽是APU,可vega7倒也没弱到连这点动画特效都带不动

放心哥,我的设备是 R7 4800H ,同为 Vega 7 我这里还挺丝滑的

EndCredits avatar Jan 21 '24 11:01 EndCredits

--use-vulkan --use-gl=egl --enable-zero-copy --enable-hardware-overlays --enable-features=VaapiVideoDecoder,VaapiVideoEncoder,CanvasOopRasterization,VaapiIgnoreDriverChecks --disable-features=UseSkiaRenderer,UseChromeOSDirectVideoDecoder --ignore-gpu-blocklist --ozone-platform=wayland --ozone-platform-hint=auto --enable-wayland-ime

用这些参数施法试试呢

EndCredits avatar Jan 21 '24 11:01 EndCredits

顺便还可以检查一下自己的 Chrome/Chromium 里的 GPU 状态,访问 chrome://gpu 就可以查看

EndCredits avatar Jan 21 '24 11:01 EndCredits

不过这个 deb 在 NixOS 上重新打包的时候确实需要 patch ,因为找不到 libGL ,但我觉得这个问题在 debian 上不应该出现,这应该是一个依赖的

Refs: https://github.com/EndCredits/R3PLAYX-nix/commit/f57b354cda3843376e5e45701248475a0404c238

EndCredits avatar Jan 21 '24 11:01 EndCredits

--use-vulkan --use-gl=egl --enable-zero-copy --enable-hardware-overlays --enable-features=VaapiVideoDecoder,VaapiVideoEncoder,CanvasOopRasterization,VaapiIgnoreDriverChecks --disable-features=UseSkiaRenderer,UseChromeOSDirectVideoDecoder --ignore-gpu-blocklist --ozone-platform=wayland --ozone-platform-hint=auto --enable-wayland-ime

用这些参数施法试试呢

我得下周二晚上再回复你,现在设备不在身边。

AXFOX avatar Jan 21 '24 13:01 AXFOX

--use-vulkan --use-gl=egl --enable-zero-copy --enable-hardware-overlays --enable-features=VaapiVideoDecoder,VaapiVideoEncoder,CanvasOopRasterization,VaapiIgnoreDriverChecks --disable-features=UseSkiaRenderer,UseChromeOSDirectVideoDecoder --ignore-gpu-blocklist --ozone-platform=wayland --ozone-platform-hint=auto --enable-wayland-ime

用这些参数施法试试呢

尝试过了,仍然是卡顿的。

AXFOX avatar Jan 23 '24 13:01 AXFOX

顺便还可以检查一下自己的 Chrome/Chromium 里的 GPU 状态,访问 chrome://gpu 就可以查看 about-gpu-2024-01-23T13-30-32-081Z.txt

AXFOX avatar Jan 23 '24 13:01 AXFOX

会不会是 mesa 版本太低了,我记得 electron 打包用的是 23.1.9,我尝试装个 debian 复现一下,我也是 Vega 7

EndCredits avatar Jan 26 '24 04:01 EndCredits

会不会是 mesa 版本太低了,我记得 electron 打包用的是 23.1.9,我尝试装个 debian 复现一下,我也是 Vega 7

我这边看才22.3.6,我感觉不是低了是高了。😂

xfox@ThinkPadE14Gen3:~$ glxinfo | grep "Mesa"
client glx vendor string: Mesa Project and SGI
OpenGL core profile version string: 4.6 (Core Profile) Mesa 22.3.6
OpenGL version string: 4.6 (Compatibility Profile) Mesa 22.3.6
OpenGL ES profile version string: OpenGL ES 3.2 Mesa 22.3.6

AXFOX avatar Jan 26 '24 05:01 AXFOX

我这边看才22.3.6,我感觉不是低了是高了。😂

对,我的意思是可能就是 Debian 默认的 mesa 版本太低了

EndCredits avatar Jan 26 '24 07:01 EndCredits