dankamongmen / notcurses

blingful character graphics/TUI library. definitely not curses.
https://nick-black.com/dankwiki/index.php/Notcurses
Other
3.6k stars 112 forks source link

develop an algorithm for issuing reps or even rectangular reps #1829

Open dankamongmen opened 3 years ago

dankamongmen commented 3 years ago

See #1740 for background information. It occurs to me that recognizing linear or even rectangular regions suitable for mass glyph blitting (the latter can be achieved with DECFRA, where supported). The problem is recognizing worthwhile regions of repetition. Note that the styling and coloring must be consistent throughout the region.

There are two basic approaches I can see:

i think we should forgo the rectangular idea for several reasons:

now, as to whether we do it in render or raster...i think raster makes more sense. everything's running along natural cache-packed structure, it doesn't require any additional state...

dankamongmen commented 3 years ago

is #1408 a duplicate of this? pretty sure it is.

as noted there, rep seems to work with arbitrary utf-8, which could be profitable:

[schwarzgerat](0) $ tput rep E 8
8888888[schwarzgerat](0) $ tput rep ὂ 8
ὂὂὂὂὂὂὂ[schwarzgerat](0) $ tput rep ▅ 8
▅▅▅▅▅▅▅[schwarzgerat](0) $