文档章节

[翻译中] 使用Wayland替代X, 大幅提高图形速度

八宝粥
 八宝粥
发布于 2013/06/17 11:55
字数 1359
阅读 964
收藏 1

在五月24号, 树莓派基金会执行总监Eben Upton宣布了开源开发板的推荐Linux分支, Raspbian, 将会支持一个定制的Wayland显示管理器.

尽管树莓派的博通BCM2835嵌入式系统被只有700MHz的ARM11处理器所限制, 但它还是有一个令人印象深刻的图形处理单元(GPU), VideoCore 4. Wayland窗口界面针对VideoCore进行了优化, 相比现在的X窗口, Upton认为会在显示上有大幅的速度和性能提升.

Wayland on Raspberry Pi

Wayland的树莓派版本, 研发经费主要由树莓派基金会负责, 相关的Weston基准合成器后台开发主要由Collabora负责, Weston方面由Pekka Paalanen提供帮助. Wayland/Weston窗口界面已经可用了, 不久便将作为稳定的Raspbian技术预览. Upton在昨天的一个Linux.com的邮件采访中表示, Wayland在未来几个月后就会完全整合在Raspbian中. 尽管X继续支持使用XWayland, 但是Upton在公告中表示:"我们已经决定完全放弃X".

The lightweight, Debian-based Raspbian, which uses the LXDE GUI environment, was already optimized for the Raspberry Pi's ARMv6-architecture ARM11 CPU. The most recent version of Raspbian ("Wheezy") was upgraded earlier this year to Debian 7.0 and Linux 3.6.11, and shows dramatic performance improvements, according to benchmarks published May 28 on Phoronix. (It should be noted that several commenters questioned the Phoronix interpretation of the results, however, so we'll wait for confirmation.)

Raspbian is now joined by a new ARMv6 optimized Fedora 18 Remix for the Pi called Pidora. Released last week by the Seneca Centre for Development of Open Technology (CDOT), Pidora offers much improved performance on the RPi compared to earlier RPi-focused remixes, and features numerous packages from Fedora 18 (see our earlier article on Pidora).

The RPi version of Wayland/Weston should make it easier for Pidora and other RPi-supporting distributions like ArchLinux and Risc OS to build their own Wayland display managers, said Upton. (A recent TechRadar roundup review of RPi-ready distros also included Plan 9 and Android 2.3, although both received poor marks.)

Wayland取得进展

Typically, we think of the Raspberry Pi as an embedded hacker platform for headless gizmos. (For a glimpse of the RPI's range, see this recent Reddit thread on RPi projects, which includes everything from prosthetic knees to wood engraving machines.) Yet, about half of all RPi projects make extensive use of the microHDMI port for running an external monitor, including most educational applications.

The aging X Window interface used by current Linux distributions -- including Raspbian, which incorporates X11 by way of its Openbox window manager -- is not optimized for the hardware video scaler (HVS) in the RPi's VideoCore 4 GPU. As a result, much of the GPU's power, including throughput of up to 500 megapixels per second and blending throughput of 1 gigapixel per second, are unavailable. The ARM11 processor is left to do much of the work, leading to poor graphics performance and shaky window manipulation.

Several Linux distributions are looking to replace X with modern display servers such as Wayland, or in the case of the Ubuntu project, Canonical's own homegrown Mir. Wayland and Mir are simpler and more flexible than X, and offer built-in support for the now almost ubiquitous hardware-accelerated graphics.

The Fedora project's three-year old plan to replace X with Wayland has finally gathered steam. The first beta version of Fedora 19 (“Schrödinger's Cat”), released May 28, includes a GNOME-based GTK+ UI toolkit that supports a preliminary version of Wayland with Weston. There may be good reasons why the Fedora project has been dragging its feet on Wayland. Potential headaches in replacing X11 are discussed in this April post on LWN.net.

Now, it's Debian's turn to go Wayland, at least in its Raspbian incarnation. In addition to promising generally better graphics display performance, Wayland/Weston gives RPi users some "neat features," according to Upton's announcement. These are said to include "non-rectangular windows, fades for windows which don’t have input focus and an Exposé-like scaled window browser." The performance is good enough that Upton expects Wayland to replace X11 as the default in Raspbian later this year.

RPi's Eben Upton on Wayland/Weston

Eben Upton Raspberry PiWe dove a little deeper in our email interview with Upton, as follows. Most of the terms he mentions are explained in this overview of Wayland/Weston on the RPi by Collabora's Daniel Stone, as well as this description of Weston on RPi by Pekka Paalanen. (Editor's Note: Be sure to catch Eben Upton's keynote talk at LinuxCon North America, Sept. 16-18 in New Orleans.)

Q: Why Wayland now?

Upton: Wayland has become much more mature over the last few months: It was much easier for Pekka to add support for DispmanX (our back-end compositor interface) in March/April by writing a new renderer than it was last year, when the preferred route was to use overlay planes. XWayland seems to have moved forward as well (and we're investing quite a lot of our own money in this), so we have a good backward-compatibility story.

Q: Were there any other options considered, including a Mir-style homegrown display manager?

Upton: We did consider traditional X acceleration, but it's very hard to bootstrap the level of competence required to do this well from a standing start. A homegrown display manager was a non-starter: We don't see the rationale for yet another fork, and unless you're a giant corporation like Canonical you'd be pushing water uphill to get adoption. Wayland is just such a good fit both for our hardware and for the sorts of things our users want to do.

Q: Will Raspbian continue to support X sessions as well, or is this a wholesale change?

Upton: We'll continue to support X for the foreseeable future, but we won't be investing specifically in improving X performance.

Q: Is this only for Raspbian, or do you foresee other supported distributions adding Wayland support?

Upton: I'd love to see other distributions supporting Wayland. Everything that's being done for Raspbian is going upstream, so I don't see any reason why this couldn't happen.

Q: What kind of graphics improvements do you expect in the full release for Wayland/Weston on Raspbian, and where do expect to see it pay off the most?

Upton: Things like 60fps window dragging have a large impact on the perceived quality of the user experience, but the real payoffs for us are the ability to add zero-copy hardware accelerated surfaces for 3D graphics and video playback. Obviously this is something we could have done with overlays and conventional X acceleration, but Wayland gives us a much simpler, cleaner route to almost the same destination. One nice fringe benefit is that we'll be able to present the wacky big-endian framebuffer format used by the Squeak Smalltalk VM (and hence by MIT's Scratch educational programming language) directly without having an ARM-side format conversion.

Q: Is Wayland on Raspbian primarily aimed at educational applications?

Upton: For us this is about improving the Pi's usability as a general-purpose computer, whether that's for education or as a "first PC" for the developing world. We figure at least 50% of our current volume is going into headless applications; it will be interesting to see how this changes over time as Wayland/Weston, and our other OSS investments like Pixman, Squeak, PyPy and LibreOffice, roll into the platform.

© 著作权归作者所有

八宝粥
粉丝 50
博文 24
码字总数 35970
作品 0
程序员
私信 提问
Linux图形界面正在发生根本性的变化

此文来自袁萌的博客最新文章,全文如下: 实际上,现在Linux图形界面已经非常美丽(或漂亮)了,但是,这种美丽的代价过于沉重。尤其是,Linux桌面的精美度与Win 7不相上下(两者就差那么一小...

红薯
2010/11/16
9.3K
30
Qt平台抽象层和图形框架

Qt本身是一个界面框架,虽然也能做很多其它功能,但画图是其主要解决的问题. Qt只是一个应用程序,意味着其画图实现需要依赖特定操作系统平台,在不同平台需要不同实现. 在Qt5中,为了更好的实现移...

心翔
2016/08/28
649
0
HHVM 4.6.0 发布,Facebook 打造的 PHP 虚拟机

HHVM 4.6.0 已发布,此版本将会获得 6 周的支持 ,而且 HHVM 4.1+ 版本也仍被支持。 值得关注的更新: 在许多表达式中均支持 添加 concurrent {} 块以作为比 和 更具可读性的替代方案 添加 ...

局长
05/27
681
2
[翻译完成] 树莓派上安装Weston

树莓派上安装Weston 本文将指导你把Weston装入树莓派. 所有的命令行和编译操作都直接在派上完成. 用Raspbian作为操作系统的时候需要以用户'pi'来运行Weston, 这是因为在本地登录(非ssh)该用户...

八宝粥
2013/06/17
1K
0
全新的X Server--Wayland

Wayland是一个简单的“显示服务器”(Display Server),与X Window属于同一级的事物,而不是仅仅作为X Window下X Server的替代(注:X Window下分X Server和X Client)。也就是说,Wayland...

匿名
2010/11/11
13.4K
0

没有更多内容

加载失败,请刷新页面

加载更多

MongoDB系列-解决面试中可能遇到的MongoDB复制集(replica set)问题

关注我,可以获取最新知识、经典面试题以及微服务技术分享   MongoDB复制集(replica set):MongoDB复制集维护相同数据集的一组mongod进程,复制集是生产部署的基础,具有数据冗余以及高可用...

ccww_
27分钟前
2
0
SpringBoot系列:Spring Boot集成Spring Cache,使用RedisCache

前面的章节,讲解了Spring Boot集成Spring Cache,Spring Cache已经完成了多种Cache的实现,包括EhCache、RedisCache、ConcurrentMapCache等。 这一节我们来看看Spring Cache使用RedisCache。...

杨小格子
35分钟前
2
0
OpenJDK之CountDownLatch

OpenJDK8,本人看的是openJDK。以前就看过,只是经常忘记,所以记录下 图1 CountDownLatch是Doug Lea在JDK1.5中引入的,作用就不详细描述了, await()方法,如果还有线程在执行,那么当前线程...

克虏伯
42分钟前
3
0
简单编程

1.编写一个程序,提示用户输入名和姓,然后以“名,姓”的格式打印出来。 #include<stdio.h>int main(){char name[3];char family[3];printf("Please input your name and family:\n...

电子工程197沈志初
46分钟前
4
0
详解Mysql分布式事务XA(跨数据库事务)

在开发中,为了降低单点压力,通常会根据业务情况进行分表分库,将表分布在不同的库中(库可能分布在不同的机器上)。在这种场景下,事务的提交会变得相对复杂,因为多个节点(库)的存在,可...

slagga
51分钟前
5
0

没有更多内容

加载失败,请刷新页面

加载更多

返回顶部
顶部