I learned about Chafa when I found a video editor that runs in the command line with keyboard control - vic - it just lets you insert split markers and when you exit the video is sliced up into the portions. I really like the low-fi nature of scrobbling through the video, it has low brain overhead.
One of the really cool things about chafa is that it has both sixel and kitty graphic renderers! (and iterm2 images as well) So you can output kitty if the terminal supports it, but fall back to ascii if it doesn’t.
What interests me about it is the unicode mosaic output format that looks higher quality than the usual upper half block or braille character approaches without needing to support a special protocol.
Setting aside the usual compatibility issues with those things.. neither are available from your buildbot. Also while Jupyter does supports images other notebooking ecosystems may not, and anyway you need a file whereas chafa can work with streams.
Why can't we have proper graphics on terminal? years ago I remember being able to use graphics.h to draw on MS-DOS terminal and print letters on it (text mode).
notcurses is probably the best option for getting the best you can out of a random terminal (see https://github.com/dankamongmen/notcurses/blob/master/TERMIN... which details the status of most terminals people use), but the main thing is to choose a decent terminal that meets your needs. I personally use xterm (after using various other terminals, both "modern" and VTE-based), as I'm on Linux, and I need to connect to various devices (e.g. networking gear) where I need a reliable terminal that handles whatever those devices throw at it. The graphical mechanisms that work for me therefore are sixel and tektronic.
Most popular terminals now have support for `kitty` graphics protocol which can smoothly and efficiently render raster images. So chafa is a way to get some backwards compatibility for some types of applications that want to show images but may not support that.
There are multiple graphics mechanisms on terminals (both real, and the virtual ones that have replaced them), the issue is which ones your terminal supports (probably none, given most terminal/libraries are bad at supporting features that have been around since the 80s), and which libraries you are using to draw them.
I use chafa in term.everything[0], and I have nothing but good things to say about it! hpjansson is a great maintainer too, if anything even seems like it's wrong with chafa he will chime in with a fix or a suggestion[1] (I'm not the only one he does this with too [2][3]). I would definitely recommend this lib for anyone doing terminal graphics.
https://github.com/wong-justin/vic
reply