pouët.net

TextFX7

category: general [glöplog]
 
I spent some time after The Turing Machines Didn't Care working on making my rgb->text converters better.

Note that originally I did not mean to use rgb->text converters explicitly, but to do some neater tricks, but I really, really didn't have time =)

Anyway, some of you may be interested in reading about the research I did, and the results, as well: http://iki.fi/sol/textfx.

I may do a 'final version' of "turing" using the latest and greatest, but I'm waiting for the results from TMDC first..
added on the 2009-01-13 21:14:46 by sol_hsa sol_hsa
Looking good!
added on the 2009-01-13 21:55:24 by mrdoob mrdoob
read it a couple of days ago (your site is very nice imho) - nice work! i might use it at some point if i figure out how to link it into a c# app.

btw, i was thinking, wouldn't it be possible to make a default windows shortcut to textmode demos for ones that do use the old dos palette and ship it with such demos? is that cheating? in the tmdc sense?
added on the 2009-01-13 22:06:40 by skrebbel skrebbel
i mean, make a windows shortcut file with the DOS colour settings of course.
added on the 2009-01-13 22:07:06 by skrebbel skrebbel
This looks really interesting! Nice conversions.
Fantastic reading. The BruteForce mode is interesting.
added on the 2009-01-14 08:59:23 by cTrix cTrix
nice implementation :)
perhaps one day i'll get around to write something for TMDC :P
added on the 2009-01-14 11:43:01 by Gargaj Gargaj
hm. do you precalculate your glyph brightness ratio or do you do it during loading? (i mean sad as it is, the font ain't granted to be the one you're using)
added on the 2009-01-14 11:45:33 by Gargaj Gargaj
(by "precalculate" i mean calculate it once and then store it as data)
added on the 2009-01-14 11:46:52 by Gargaj Gargaj
And now that I'm a bit more awake... Great that you have done that. It also pissed me off the people using libCaca while libCaca just had the character ramp thing instead of finding the best character for the pixels on the screen.
added on the 2009-01-14 12:16:45 by mrdoob mrdoob
@Gargaj: The font data is based on the default console font, as there's no (sane) way of capturing the current one. For the rest, read the article.
added on the 2009-01-14 12:24:36 by sol_hsa sol_hsa
sol: that's what i thought - ever considered something like printing the character set out, taking a screenshot (via the DC of the window) and using that?
added on the 2009-01-14 12:34:10 by Gargaj Gargaj
@Gargaj: no.
added on the 2009-01-14 12:58:30 by sol_hsa sol_hsa
there should at least be ways to get the BIOS font data, but the BIOS font is only used in fullscreen. Then again, I'm still in the DOS days with my knowledge, so I don't know if this can still be applied to windows consoles.
I eventually concluded that trying to make a general purpose color converter was not the best idea to make textmode look good :)
Trying different color distance functions and introducing all kinds of tweaks still results in unwanted ugly grays popping up in some conditions.
Instead what I mostly do is map color intensity to a pallete function, which results in 8bit palleted color style techniques and makes all kinds of nice transitions possible.
added on the 2009-01-14 14:50:12 by paulius paulius
sol: when i compile in visualstudio2005 with charset:'unicode' instead of 'not set' my codepage gets weird.
adding
Code:SetConsoleOutputCP( 437 );
has no effect on the chars. Do you know a way to fix this?
added on the 2009-01-19 22:19:38 by the_Ye-Ti the_Ye-Ti
@the_Ye-Ti: No, I'm just assuming someone at Microsoft hates textmode demos =)
added on the 2009-01-20 08:36:30 by sol_hsa sol_hsa
Codepages are obsolete when using unicode, you can't have both.
added on the 2009-01-20 10:36:25 by Claw Claw
wow, the problems arising are pretty similar to writing a converter for c64 pics :)

btw, I think paulius might have a strong point there, tho cranking up saturation and contrast will make those grays go away, and make everything nicer with 16 colors believe me :)
added on the 2009-01-20 12:35:28 by Oswald Oswald
Hey guys, about bitmaps fonts, you might want to look at this project: http://ansilove.sf.net

It's an ANSi to PNG converter written in PHP. I dumped the PC fonts (80x25 and 80x50 modes) along with some amiga ones (Topaz and stuff), and you can find the PNGs files with all charsets in all the 16 possible colors on a transparent background in the "fonts" directory.
added on the 2009-01-20 14:58:13 by Cleaner Cleaner
@oswald: I did a koala painter-style graphics filter for photoshop, it was much easier than the text mode problem =) (search for koalizer, or browse through my site)
added on the 2009-01-20 17:07:34 by sol_hsa sol_hsa

login