Wayland - Beyond X (The H)
Wayland - Beyond X (The H)
Posted Feb 15, 2012 22:08 UTC (Wed) by nybble41 (subscriber, #55106)In reply to: Wayland - Beyond X (The H) by khim
Parent article: Wayland - Beyond X (The H)
Well, perhaps that does make more sense, at least for TUI applications. (For normal command-line programs its obviously a step backward, since there is no easy way to recover the original text once it's been formatted into a terminal buffer.) However, it could be done with a trivial network-transparent protocol just as easily as with a shared memory buffer. The important point is having low-level access to a very thin terminal, not how you communicate with it. Shared memory is faster due to being zero-copy (though not necessarily by a large margin), while message-passing has fewer locking issues and works better when latency is high. You can always convert one form into the other, though going from shared memory to message-passing tends to much less efficient since the original structure is not preserved.
P.S. TUIs are almost entirely an anachronism by this point. The systems which make regular use of text terminals use them mainly for CLIs, not TUIs, and many of these CLI programs are designed for serialized I/O. If you want low-level access, including direct access to the screen and input events, write a GUI. It really doesn't make sense to design applications around raw VGA-style text buffers only to run them in a terminal emulator running inside X.