Commit Graph

2310 Commits

Author SHA1 Message Date
nick black
c6657f763a
prep for 1.5.2 2020-06-14 18:42:36 -04:00
nick black
bea281d120
rust: update for new notcurses_options 2020-06-14 18:16:44 -04:00
nick black
64c4a4be53
unit tests: require utf8 for quadblitter 2020-06-14 17:43:18 -04:00
nick black
8ff0d92ad7
testing-checklist: add LANG=C, needed for debuilder 2020-06-14 17:39:58 -04:00
nick black
0657267274
v1.5.1 2020-06-14 17:17:49 -04:00
nick black
59bf168e55
quadblitter: emit ▌, not ▋, you fool #667 2020-06-14 05:11:11 -04:00
nick black
222c52e10c
view: use quadblitter 2020-06-14 04:31:00 -04:00
nick black
64b07fcd0b
outro: use quadblitter, reset vopts 2020-06-14 04:03:50 -04:00
nick black
cadd0ae283 quadblitter: fix arguments to channel_rgb() #667 2020-06-14 03:54:10 -04:00
nick black
d710bb24b2 unit test for quadblitter #667 2020-06-14 03:54:10 -04:00
nick black
d69d369304 fill out NCBLIT_2x1 Dualblitter unit test #667 2020-06-14 03:54:10 -04:00
nick black
ab4243d9be quadblitter/dualblitter unit test bases 2020-06-14 03:54:10 -04:00
nick black
7c1e9fe3d2
ffmpeg: properly scale #714 2020-06-14 01:07:38 -04:00
Nick Black
0084dbaa6d
qrcode generalization #699 (#713)
Add convenience function ncplane_home(). Add an ncblitter_e param
to ncplane_qrcode(), and split int maxversion into value-result
int* ymax and int* xmax. Write the actual sizes of the resulting
visual into these parameters. Update the qrcode demo. Add the
qrcode PoC. Update demos to ncplane_home(), where possible.

ncplane_qrcode() now takes an ncblitter_e and two value-result int*s
in the place of a single value int. The final size of the displayed qrcode
is written to *ymax and *xmax. If the code can't fit within the specified
dimensions, an error is returned. Standard rules for pluggable blitters
apply regarding fallback etc. #699
2020-06-13 22:24:50 -04:00
nick black
22dc5014cc
notcurses_rasterize: update comment about damagemap 2020-06-13 15:18:04 -04:00
nick black
ee73df3059
dragon: reset static done flag, erp 2020-06-13 00:13:09 -04:00
Nick Black
068b1c952a
Dragon demo #708 (#710)
* define dragon curve demo #708
* demo: distinguish abort from fail, color-wise
* dragon: ncvisual-based #708
2020-06-13 00:06:33 -04:00
nick black
909040eade
christ nick get your head in the game 2020-06-12 16:48:47 -04:00
nick black
ed824fe0d2
eep! #709 2020-06-12 16:44:31 -04:00
nick black
5bbd183db4
rotate_channels: handle top half block #707 2020-06-12 09:23:33 -04:00
nick black
03c748476b
normal: speed up rotation out #599 2020-06-12 09:09:40 -04:00
nick black
4f8f16df8d
qrcode: really remove getrandom() for freebsd < 12 2020-06-12 07:57:11 -04:00
nick black
3e23ca524f normal: improve coloring 2020-06-12 07:26:44 -04:00
nick black
b119cec29e
normal: finally move to pi/4 rotations #599 2020-06-12 04:15:44 -04:00
nick black
dc49bb943b
demo: destory about screen before restarting #706 2020-06-12 02:21:20 -04:00
nick black
e74e7860c5
demo: explicitly set menu/about colors #705 2020-06-12 02:12:47 -04:00
nick black
a069745c49
notcurses-ncreel: remove unused field 'id' 2020-06-12 00:55:07 -04:00
nick black
3936d1b528
adapt callers of ncvisual_geom() 2020-06-12 00:53:34 -04:00
nick black
70183ee283
Rewrite plot tests using C interface #703
The Plot unit tests were reaching directly into the objects,
which meant the implementations couldn't include anything
we didn't want public. This was annoying, so I've changed it.
This required adding ncdplot_sample() and ncuplot_sample(),
which we should have had anyway.
2020-06-12 00:13:01 -04:00
nick black
4d9171aee1
rust: get libnotcurses-sys compiling #704 2020-06-11 23:32:31 -04:00
nick black
185742fd08
Rendering now does tripartite fallback to basecell
Each plane has a "base cell", which like all other cells is
initialized to the null glyph, opaque default foreground color,
and opaque default background color. Prior to this change, at
each cell of a plane, we decided whether to use that cell (the
"viscell") or the base cell depending on whether the viscell had
a non-null glyph. We now evaluate each component independently.
If the viscell has a null glyph, we use the base cell's glyph.
If the viscell has a default foreground, we use the base's fg.
If the viscell has a default background, we use the base's bg.
This was done because (a) it seems more intuitive (if I set a cell
to red, I expect red, not red iff there's a glyph in that cell
for this plane), and (b) because otherwise it was impossible to
do a multicolor overlay without blowing away underlying glyphs
(since without a glyph, you always reduced to the same base cell,
which could have only one fore- and background per render).

Existing code will need to change any instances where cells
lacking glyphs are colored, and those colors are not desired.
Since any such coloring had no effect before, it seems unlikely
that any ought exist (this did bring to light an instance in
the "qrcode" demo where we were staining overmuch of the plane).

This closes #395, the last big open worry regarding our API.
2020-06-11 23:10:03 -04:00
nick black
4391c661be
don't pull logging into plot #703 2020-06-10 09:47:24 -04:00
nick black
f98acad7f6
add NCPLOT_OPTIONS_DETECTMAXONLY #610 2020-06-09 12:02:42 -04:00
nick black
2b89b0850c
jungle/normal: improve behavior under ASCII mode #696 2020-06-09 07:24:47 -04:00
nick black
a10ba4dac6
highgradient: degrade to gradient #700 #696 2020-06-09 06:08:29 -04:00
nick black
20322fe805
demo improvements for ASCII mode (#696)
* eagle: use new ncvisual_geom() to properly zoom
* qrcode: skip for now (#699)
* luigi: draw with spaces, not full blocks
2020-06-09 05:12:30 -04:00
nick black
af46077775
ncvisual_geom: take degradation into account #697
In order to properly determine the scaling of an ncvisual to
be rendered, ncvisual_geom() needs know the blitting method.
For this reason, it took an ncblitter_e argument. It also,
however, needs handle degradation, which means knowing whether
NCVISUAL_OPTIONS_NODEGRADE is in use. It thus really wants the
struct ncvisual_options. Pass and accept it. Closes #697, and
fixes the "yield" demo in ASCII mode (#696).
2020-06-09 05:00:08 -04:00
nick black
827c2f2013
ncplot: don't print spaces #695 2020-06-09 04:46:54 -04:00
nick black
0e1617811f
eagle: require UTF8 for now #697 #696 2020-06-09 04:45:00 -04:00
nick black
7fc38d8fdd
v1.5.0 2020-06-08 06:05:17 -04:00
nick black
470c4f13e2
remove duplicate NEWS entry 2020-06-08 05:26:58 -04:00
nick black
09f3f9097d
input: extract most of main() into input_demo() 2020-06-08 05:14:22 -04:00
nick black
1cd3ffc89a
outro: transparent legend at borrom #687 2020-06-08 04:57:26 -04:00
nick black
1ffd871784
blocks poc: handle std coredump-free #645 2020-06-08 04:37:42 -04:00
nick black
a3369d77a9
outro: plug memory leak post-fade 2020-06-08 03:33:48 -04:00
nick black
c8caa23090
brailleblitter: honor transparency #649 2020-06-08 03:19:42 -04:00
Nick Black
28431914a8
First go at ncplane_puttext() (#690)
Very simple take at ncplane_puttext(), a new function for linebroken text. Also some very basic unit tests. I doubt this works very well yet, but it handles the simplest cases #682. Added nclog(), internal function for logging. #520
2020-06-08 03:01:58 -04:00
nick black
7736e4a7dc all: don't put legend so far away from plane 2020-06-08 01:31:42 -04:00
Marek Habersack
4d2e4e82d3 [C++] API sync
Changed:

 * Visual: tiny reformatting to fit the overall ncpp style
 * Visual: added error guard in `render`
 * Visual: error_guard update in `rotate`

Added:

 * Visual: simple_streamer (`ncvisual_simple_streamer`)
 * Visual: polyfill (`ncvisual_polyfill_yx`)
 * Visual: at (`ncvisual_at_yx`)
 * Visual: set (`ncvisual_set_yx`)
2020-06-07 20:22:13 -04:00
nick black
841c0a4b8f
quadblitter: respect transparency #686 2020-06-07 19:46:03 -04:00