简体   繁体   English

如何开始编写合成 WM?

[英]How to get started writing a compositing WM?

I would like to write a basic hardware-accelerated window manager, so I've been looking for some documentation on how to get started, but I've only managed to find this tutorial , which uses an outdated version of Clutter and won't build with any version currently available.我想写一个基本的硬件加速窗口管理器,所以我一直在寻找一些关于如何开始的文档,但我只找到了这个教程,它使用了一个过时版本的 Clutter 并且不会使用当前可用的任何版本构建。 Are there any other good resources for how to do this, or alternatively, a really bare-bones compositing WM to look at the source of?是否有任何其他好的资源可以做到这一点,或者,一个真正简单的合成 WM 来查看其来源?

There are two parts in your question: 1) How to write WM 2) how to write composite manager您的问题有两个部分:1)如何编写 WM 2)如何编写复合管理器

Some links to help understand part two (in addition to xcompmgr source):一些有助于理解第二部分的链接(除了 xcompmgr 源):

Window manager, "part one":窗口管理器,“第一部分”:

The original demo compositing manager was xcompmgr , which I'd recommend for understanding the underlying X extensions.最初的演示合成管理器是xcompmgr ,我建议使用它来了解底层 X 扩展。

If you're using OpenGL to do your hardware-accelerated rendering, you'll need to read up on the EXT_texture_from_pixmap extension to avoid copying window contents through userspace.如果您使用 OpenGL 进行硬件加速渲染,则需要阅读EXT_texture_from_pixmap扩展以避免通过用户空间复制窗口内容。 That extension allows you to use hardware-accelerated blits for those copies instead.该扩展允许您对这些副本使用硬件加速的 blit。

You'll probably also be interested in the specification for _NET_WM_SYNC_REQUEST , to allow tear-free rendering synchronized to vertical retrace.您可能还会对_NET_WM_SYNC_REQUEST的规范感兴趣,以允许与垂直回溯同步的无撕裂渲染。

您可以尝试使用 qtile,它可以通过 python 配置进行自定义(这也使得它非常容易上手)您可以在 wayland 和 x11 之间进行选择,尽管它是用 python 编写的,但它非常快

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM