This is pretty cool, though I've seen similar utilities already (there are several active BBS groups on Facebook, and a few of us relatively old timers out there.
To me, a big part of the nostalgia of ANSI as it was through the 80's/90's was the skill it took to get something to look like anything with the block/shading characters, 16 foreground and 8 background colors. Even getting the color pallet right in modern apps is pretty off compared to original DOS, which was based on 252,252,252 being white, from there, the offsets are proper.
It's an interesting time we live in... UHD monitors, with more room than I could have imagined in front of me over 20 years ago, when 640x480 was typical, and 1024x768 was cutting edge... let alone a big color range.
Thanks! I haven't seen one that does 24bit RGB + shape matching, would be interested in pointers (shading chars don't make sense in 24 bit color space).
Unfortunately I had to remove some of the more interesting diagonal shapes because they are wider than the character cell -- despite the monospaced font... :-/
I actually wrote this because I wanted to test my "pure Java" implementation of strict Typescript by running the raytracer example -- without needing to add a windowing library or image encoder: https://github.com/stefanhaustein/typo
It's absolutely useful... I wasn't meaning to seem dismissive of that. It's just that I usually think of a lot of these things in terms of past compatibilities.
This is very cool and produces nice looking output. Well done!
However, I feel like the draw of a tool like this is that it can run in minimalist environments where a GUI is not available. I'm not sure how I feel about having to spin up a JVM to use it.
Thanks! I fully agree. Most of the code probably can be ported to C(++) without much change, it's just a few loops over arrays, except for the image loading part. Best solution might be to extend a similar existing unix tool. Can you recommend any (ideally with the source on github)?
And, while not quite the same thing, if you are a user of iTerm2, it includes the script "imgcat" that will display an image directly in the terminal window.
Maybe somebody should write an RFC... Not sure how complex this would be to support in terminals in general though. After all, you may suddenly need much more information per cell than the 2 ints for the code point and color...
To me, a big part of the nostalgia of ANSI as it was through the 80's/90's was the skill it took to get something to look like anything with the block/shading characters, 16 foreground and 8 background colors. Even getting the color pallet right in modern apps is pretty off compared to original DOS, which was based on 252,252,252 being white, from there, the offsets are proper.
It's an interesting time we live in... UHD monitors, with more room than I could have imagined in front of me over 20 years ago, when 640x480 was typical, and 1024x768 was cutting edge... let alone a big color range.