Window Manager with transparency X11 / Wayland - linux

I have a specialized display device, which provides an RGBA video sink (meaning: with alpha channel) via the DRM driver interface. I want to run a window manager and a windowed application with transparency (meaning: desktop background is transparent, application can also have transparent areas).
Which window managers support transparency all the way down to the DRM device (can be X11, Wayland, or others...)?
From my own research: Wayland basically supports RGBA but not weston(?), X11 does not support RGBA, however Xrenderlib does - but which desktop supports it?
Thanks and have a great day!

Related

What is difference between ANGLE and Skia Graphics Engine?

ANGLE is an cross-platform graphics engine abstraction layer
developed by Google. ANGLE team has described it as a portable
OpenGL. The API is mainly designed to bring high-performance
OpenGL compatibility to Windows computers and to web
browsers such as Chromium/Google Chrome by translating OpenGL
calls to Direct3D, which has much better driver support.
Skia Graphics Engine is a graphics library written in C++
which abstracts away platform-specific graphics API.
Both are abstraction layer developed by Google to support openGL and both are getting used in Google Chrome.
What exactly is difference between both?
Some context first.
OpenGL is an API to program graphics cards. The API calls to OpenGL get translated into commands for the GPU card in the computer, by the driver of the GPU vendor (usually Nvidia, AMD or Intel).
(other APIs to program GPUs are Direct3D on Windows, Metal on macOS, Vulkan, etc.)
These APIs are somewhat "low-level", in the sense that they give calls to instruct the GPU what to do at a raw "geometry"/"pixels" level; these APIs don't have anything like "draw a rectangle here", or "draw this image there".
Web browsers like Chrome provide the WebGL API for HTML5 pages. WebGL is mostly the OpenGL ES 2.0 API.
ANGLE is a library that converts the OpenGL ES 2.0 API to one of the GPU APIs: you make OpenGL ES 2 calls and ANGLE converts to equivalent calls in desktop OpenGL, or to Direct3D on Windows, or to Metal on macOS.
This gives you a consistent implementation of OpenGL ES 2.0, which Chrome wants for the web. (This is super useful because the Windows OpenGL implementations differ from vendor to vendor, and macOS stopped updating its OpenGL implementation at version 4.1 a long time ago).
Skia is a higher level API that lets you "draw a rectangle here" and "draw this image there" and much more (draw text; draw paths; draw curves; etc.) This is the usual high-level API that you'd get in higher level languages, and on the Web Canvas API.
To implement those calls, Skia converts the drawing commands to lower-level APIs like GL, Metal, etc. One of the APIs that Skia can target is ANGLE, so that Skia drawings get consistent output across platforms.

Linux drawing to display without desktop manager

Lets say i have a Linux (Ubuntu), well NVIDIA packaged one that comes with Jetson boards, and i have HDMI output and DP.
The goal is to: Display Desktop part via HDMI, and display GUI that i made with OpenGL via DP, but without DP ever showing Desktop, if process with GUI exits, the display connected via DP does not show anything until process is restarted.
So far i have researched X server, but most of the materials just talk about X11 protocol, and how to create a window. If i just open a window in full-screen mode, it could work, but until GUI is launched i would see part of Ubuntu desktop there.
The GUI is basically a Monitor with CT Overlay that sends touch input via I2C.

Linux DRM (Direct Rendering Manager) custom resolution and timings

I'm trying to make some kind of video generator in order to test monitors. For this I'm trying to avoid any X and window manager so I'm stuck with a non GUI Linux.
I was able to write directly into the framebuffer device under Linux but I wasn't able to change the resolution at all. Fbset didn't have any effect.
With the help of a tutorial, I was able to change the resolution with DRM but only modes that my screen is telling that it is supporting.
Is there any way to disable the EDID readout at all or inject custom timings?
you can stuff whatever values you want into the drmModeModeInfo structure before initializing drm. so any custom video mode is possible.

Sending touch screen events through X11

I have an embedded application which is using x11 with opengl for windowing and rendering of graphics. The device has a touch screen, which is used for application interaction. Currently, the touch screen driver is implemented in our application space and we handle the events accordingly.
However, I want that the touch events should go to the application via X11 interface.
Can anyone help me understand how this can be achieved ?
Probably the easiest way is the uinput module. This allows you to create a "virtual device" in userspace that can generate events. Those can be caught with the evdev driver by the xserver and sent to your application (o any other window).
See linux uinput: simple example?

Why does the chromecast client declare its height and width as 720p to the receiver app?

Why does the chromecast declare its client height and width to be 720p to the receiver app server?
I am trying to display non-video content and assumed I would be able to use the full 1080p resolution. The device reports to the TV that it is in 1080p 60hz but if you look at the on device developer tools it is only displaying my receiver app as 1280x720.
Is there a way to force the page to render at full resolution?
Chromecast devices have a different Graphics Window size than it's Video window - The Graphics window uses a 1280x720 resolution surface. The window.height and window.width properties are going to report 720 and 1280 respectively. However, Chromecast is capable of displaying video at up to 1080p resolution i.e. 1920x1080. Therefore applications should not use the screen size to select video content resolution.
While the UI layer of Chromecast currently only supports 1280x720, the Google Cast team recommends that developers do not hardcode this screen size as it might change in the future.
In a response to a similar question in the post below John Affaki wrote: "Right now, we have a limitation where the "UI" layer is at 720p even though video can run at 1080p. It's on our roadmap to revisit this, so I'm suggesting that you build your app in a way that will just work if this gets fixed."
https://plus.google.com/100147701757803136741/posts/JDhtJTw7jz5
It's possible this has changed at some point, but despite the pixel size being reported as 1280x720, it is actually rendering at the full resolution. Just like smartphone viewport scaling, except that I don't see a way to disable it.
So, even though it says 1280x720, trust that it is rendering at a higher resolution!
I have uploaded a test image on this question: Getting actual width of Chromecast receiver UI

Resources