Page 1 of 1

XnView on WSL2: Could not load the Qt platform

Posted: Sat Feb 22, 2025 8:32 pm
by dric512
I have WSL2 installed on Windows 11 and try to launch XnView directly from WSL. The goal is to open scripts which are on the Linux side.

I have been able to run it on a previous laptop, but although I was able to install the .deb file and fixed missing dependencies, when I launch it I have the following message:

Code: Select all

0.29.0 (git 9b548e5) - Multimedia Development Kit. Copyright (c) 2016-2024 WangBin(QtAV author) <wbsecg1 at gmail.com>
Build for: Linux x86_64; glibc2.24/2.39 libc++190000; Clang19.0.0 (++20240702031426+43b988821423-1~exp1~20240702151527.1781); 04:26:03 Jul  3 2024
qt.qpa.plugin: Could not load the Qt platform plugin "xcb" in "" even though it was found.
This application failed to start because no Qt platform plugin could be initialized. Reinstalling the application may fix this problem.

Available platform plugins are: linuxfb, minimal, minimalegl, offscreen, vnc, wayland-egl, wayland, wayland-xcomposite-egl, wayland-xcomposite-glx, xcb.
I guess this is because I am missing some packages, but can't find which ones?
I can open other GUI applications with no issue.

Re: XnView on WSL2: Could not load the Qt platform

Posted: Mon Feb 24, 2025 10:17 am
by xnview
do you start xnview.sh?

Re: XnView on WSL2: Could not load the Qt platform

Posted: Tue Feb 25, 2025 8:35 pm
by dric512
No directly `/usr/bin/xnview`.

I installed `qt6-base-dev` and now it opens correctly, not sure why it makes a difference.