TE
科技回声
首页24小时热榜最新最佳问答展示工作
GitHubTwitter
首页

科技回声

基于 Next.js 构建的科技新闻平台,提供全球科技新闻和讨论内容。

GitHubTwitter

首页

首页最新最佳问答展示工作

资源链接

HackerNews API原版 HackerNewsNext.js

© 2025 科技回声. 版权所有。

Unicode 13 sextants advances state-in-the-art terminal rendering

9 点作者 dankamongmen超过 4 年前
I&#x27;m the author of a blingful TUI&#x2F;character graphics library by the name of Notcurses. One of the core competencies of Notcurses is rendering images and video to a terminal (without undue shrinking of the font). Leaving aside asymmetric rendering such as that performed by caca (see Notcurses documentation for an explanation of why I don&#x27;t think this a good general approach), common symmetric rendering techniques include spaces and Unicode half blocks ( and ). This last method is employed by tools like viu and mpv&#x27;s TCT output, and can be considered the general &quot;state of the art&quot;.<p>Notcurses had already gone past this with its Quadblitter, making use of Unicode 3.2&#x27;s quadrant blocks to map 2x2 pixels to a terminal cell. With the advent of Unicode 13&#x27;s Legacy Computing Symbols (and rollout of font support for them), a powerful new symmetric blitting method is made available, mapping 3 rows of 2 columns each to a single cell. This blitter is available as NCBLIT_3x2 in the upcoming Notcurses 2.0.3. I was worried that color loss would be more of a problem, but it ended up looking great!<p>The following images are rendered using all four blitters:<p>https:&#x2F;&#x2F;nick-black.com&#x2F;images&#x2F;worldmap-sexblitter.png (left to right: S, Q, H, ASCII)<p>https:&#x2F;&#x2F;nick-black.com&#x2F;images&#x2F;sexblitter-perfection.png (clockwise from upper left: ASCII, H, Q, S)<p>The algorithm is described here: https:&#x2F;&#x2F;github.com&#x2F;dankamongmen&#x2F;notcurses&#x2F;issues&#x2F;1086<p>code here: https:&#x2F;&#x2F;github.com&#x2F;dankamongmen&#x2F;notcurses&#x2F;blob&#x2F;master&#x2F;src&#x2F;lib&#x2F;blit.c<p>notcurses: https:&#x2F;&#x2F;nick-black.com&#x2F;dankwiki&#x2F;index.php?title=Notcurses<p>hype video: https:&#x2F;&#x2F;www.youtube.com&#x2F;watch?v=cYhZ7myXyyg<p>enjoy! hack on!

1 comment

rbanffy超过 4 年前
People are working to include Kaypro&#x27;s 2x4 mosaics for the next release.