Weston 8: kiosk-shell background is black but should be grey

Terry Barnaby terry1 at beam.ltd.uk
Wed Oct 5 08:52:14 UTC 2022


On 05/10/2022 09:41, Marius Vlad wrote:
> On Tue, Oct 04, 2022 at 11:07:11AM +0100, Terry Barnaby wrote:
>> On 04/10/2022 09:56, Alexandros Frantzis wrote:
>>> On Tue, Oct 04, 2022 at 08:55:22AM +0100, Terry Barnaby wrote:
>>>>   From what I can see the kiosk-shell in Weston 9.0 should draw a grey (0.5,
>>>> 0.5, 0.5) solid colour background. However on my NXP embedded system it
>>>> shows as black.
>>>>
>>>> Should the kiosk-shell in Weston 9.0 actually draw grey ?
>>>>
>>>> If so is there some configuration I'm missing or is there a bug with that
>>>> release ?
>>>>
>>>> Terry
>>> Hi Terry,
>>>
>>> kiosk-shell until some point after 9.0.0 (until commit 73aaf14e to be
>>> precise), has a hardcoded grey background. I just verified this works
>>> fine with 9.0.0, at least with an Intel GPU.
>>>
>>> The aforementioned commit changes the default background to black and
>>> allows reading a background color value from the .ini file, like
>>> desktop-shell does.
>>>
>>> If you are not seeing a grey background, could it be the case that the
>>> Weston version you are using is not actually pure 9.0.0 but is based on
>>> some commit after 9.0.0 (so really version 9.0.9x) that also includes the
>>> background-color support?
>>>
>>> The first lines of your Weston log should provide information about the
>>> exact version/build you are running. What do the lines say?
>>>
>>> In the email subject you wrote "Weston 8", is this a typo?
>>>
>>> Thanks,
>>> Alexandros
>> Hi Alexandros,
>>
>> Thanks for the reply, Yes, the "Weston 8" in the subject was a typo, sorry.
>>
>> The Weston 9 used is that in the NXP Yocto hardknot release.
>>
>> Actually looking at the Yocto sources for that, it is actually based on an
>> NXP GIT at: git://source.codeaurora.org/external/imx/weston-imx.git,
>> e73c641e076aa68e8ef69dbd56c7a252117b2c83 with some additional minor patches.
>> I assumed it was based directly on the upstream Weston GIT. So as the
>> background colour should be grey in the upstream 9.0.0 release I suspect
>> some issues in the NXP modifications and/or hardware interface.
>>
>> So I will ask on the NXP forums on this.
> I see you're using g2d, maybe try turning that off and see if it's still
> black? Would be really nice if could update this thread once you find
> out the issue, it could help others too.

I actually did that earlier this morning after looking at the NXP Weston 
code, and the background colour worked after that, so definitely an NXP 
Weston 9 issue with the g2d mods.

I have asked on the NXP forums, but I don't hold out much hope of any info.

I will probably try their latest 10 or "main" version somehow, but I am 
wary of dependency hell through the whole Linux->application stack 
especially as we are just about there with this project apart from not 
being able to move an application to a second monitor :(.


>> But just for info:
>>
>> Looking at the kiosk-shell code it does not have the config file
>> background-color support. In general I have no issues with Weston on this
> Support for changing the background was added, like Alexandros said,
> in 9.0.x which made in into weston 10.
>
> Fyi, code that added background intially had an issue where the two
> channels were swapped, but was rectififed a bit later on
> (but that's fixed in weston 10).

I have looked at that code, and it "appears" to function the same as the 
default grey code apart from getting the config parameter.

All I need to do at this stage is find some way of clearing the output 
on the first monitor when the application moves as its old screen GUI 
display is left rendered on that monitor after my code moves the view x 
pos to the second monitor (output).


>> platform, its just when trying to implement a switch of the output device
>> for a full screen application, I need to redraw the background on the old
>> output and I found that this wasn't working and it actually should have been
>> grey anyway.
>>
>> The first log lines say:
>>
>> Date: 2022-10-04 BST
>> [10:39:31.437] weston 9.0.0
>>                 https://wayland.freedesktop.org
>>                 Bug reports to:
>> https://gitlab.freedesktop.org/wayland/weston/issues/
>>                 Build: lf-5.10.52-2.1.0-rc2-0-ge73c641e+
>> [10:39:31.451] Command line: /usr/bin/weston --log=/run/user/0/weston.log
>> --modules=systemd-notify.so
>> [10:39:31.452] OS: Linux, 5.10.52-lts-5.10.y-ds200i-00007-ge17e4a8d84dd, #34
>> SMP PREEMPT Wed Aug 31 09:58:42 BST 2022, aarch64
>> [10:39:31.461] Using config file '/etc/xdg/weston/weston.ini'
>> [10:39:31.462] Output repaint window is 16 ms maximum.
>> [10:39:31.469] Loading module '/usr/lib/libweston-9/drm-backend.so'
>> [10:39:31.487] initializing drm backend
>> [10:39:31.496] logind: session control granted
>> [10:39:32.513] dbus connection send fail and will retry
>> [10:39:32.518] using /dev/dri/card1
>> [10:39:32.518] DRM: supports atomic modesetting
>> [10:39:32.518] DRM: does not support GBM modifiers
>>
>>
>> /etc/xdg/westong.conf has:
>>
>> [core]
>> #gbm-format=argb8888
>> #gbm-format=rgb565
>> idle-time=0
>> use-g2d=1
>> xwayland=true
>> repaint-window=16
>> #enable-overlay-view=1
>>
>> # DS200i startup
>> shell=kiosk-shell.so
>> #shell=ds200i-shell.so
>> #shell=fullscreen-shell.so
>>
>> [shell]
>> #size=1920x1080
>>
>> [libinput]
>> touchscreen_calibrator=true
>>
>> #[output]
>> #name=HDMI-A-1
>> #mode=1920x1080 at 60
>> #transform=rotate-90
>>
>> #[output]
>> #name=HDMI-A-2
>> #mode=off
>> #       WIDTHxHEIGHT    Resolution size width and height in pixels
>> #       off             Disables the output
>> #       preferred       Uses the preferred mode
>> #       current         Uses the current crt controller mode
>> #transform=rotate-90
>>
>> [screen-share]
>> command=@bindir@/weston --backend=rdp-backend.so --shell=fullscreen-shell.so
>> --no-clients-resize
>>
>> [launcher]
>> icon=/home/root/.nxp-demo-experience/icon/icon_demo_launcher.png
>> path=/usr/bin/demoexperience
>>
>> [launcher]
>> icon=/usr/share/weston/terminal.png
>> path=/usr/bin/weston-terminal
>>
>> Terry
>>



More information about the wayland-devel mailing list