05-10-2023, 09:32 PM
Yes, Plasma Mobile uses Wayland, kwin_wayland more specifically, so it is no use running another instance of it.
PinePhone app development
|
05-10-2023, 09:32 PM
Yes, Plasma Mobile uses Wayland, kwin_wayland more specifically, so it is no use running another instance of it.
05-11-2023, 07:13 AM
(This post was last modified: 05-11-2023, 07:24 AM by WhiteHexagon.)
OK that helps, thanks. I was running this over SSH and had the bright idea that it might have to be running on the actual device to use wayland/GUI but sadly has the same missing 'wl_shell' interface. I also read that there is a newer (unstable) 'xdg_shell' but I also dont see that on the 'registry' scan (below). Is there somewhere to find a current simple wayland example that works on current Plasma PP-Beta please? chatGPT spat out some garbage Ideally looking for something like a fullscreen blank GL ES starting point please. Is that the right level to work at, or should/could I be looking at direct DRM calls (if that is even possible from this OS level of abstractions).
And a more general question for app development. If I mange to get a wayland app running, how portable would it be, just plasma, or do you think would it run across other PP OS options? I am really appreciating your guidance, but also wondering if there are others doing this, or did I miss the boat for PP app development Code: registry_handle_global interface:wl_compositor
05-11-2023, 04:30 PM
Normally, you do not use Wayland directly in an application, you use a toolkit like Qt (either QtQuick or QtWidgets, though the latter is not well supported for mobile) or GTK.
That said, a Wayland application should work in most mobile desktop environments. Only SXMO uses X11, and even there, there is now also a Wayland-based variant. It is just that it is not very convenient to code for Wayland directly without the toolkit layer (and the toolkit also provides portability to X11 and other platforms).
05-16-2023, 04:21 AM
Thanks again. I only try to target my Apps for the PinePhone and PineTab2 when released (ie not desktop). But GTK has some appeal, especially being written in C, which should make it easy to access from Zig but from what I am reading it sounds like a lot of these toolkits struggle a bit with performance, especially at startup. So far I tried 3 different OS combinations, and they all seem to take a few seconds just to open the most basic 'builtin' apps like calendars and clocks. The mali400 might be a bit old, but it should be able to whack out stuff much faster than what I am seeing. So now I am wondering if Linux is the bottleneck? Even with 'airplane mode' and phone locked, the battery is draining overnight, so I can only assume that Linux must be running quite a bit of stuff in the background? could that be affecting app performance? As I say I am new to Linux, so maybe I am repeating a lot of what is already known, and this is just the price of having such an amazing open platform as the PinePhone I shall take a look at NuttX next, since that will maybe give me a better idea what the device is capable of.
05-17-2023, 10:41 PM
You will quickly get used to leaving the phone plugged overnight so the battery will be full when you wake up.
But for the performance, well, you can always try writing a raw Wayland app and seeing whether it will come up any faster. I suppose it also depends on how many libraries the application is linked to (and I guess the Zig standard library is actually going to be one more library to load that slows things down). |