Commit Graph

35 Commits (21822f98e743ff5bfca650048d1ae14396389b3f)

Author SHA1 Message Date
nick black 2037cdfacb move libav.c to nc_err_e #532 4 years ago
nick black 67100dc5e9
Process menu/HUD input in demo_nanosleep() #509 4 years ago
Nick Black c6a9997554
Normalize ncplane_at_* / ncplane_set_base() (#479)
* ncplane_at_* and ncplane_at_cursor_*

We had notcurses_at_yx() expanding into three distinct parts of
the cell structure, and ncplane_at_yx() / ncplane_at_cursor()
writing directly to a cell. It was annoying to remember which
was which. The latter two now have a signature matching
notcurses_at_yx(), while the old functionality has been moved
to ncplane_at_yx_cell() and ncplane_at_cursor_yx(). #476
4 years ago
nick black ae1421db15
ncvisual_render() API change/documentation #422
ncvisual_render() now returns the number of cells emitted
rather than just 0/-1. -1 is still returned on failure.
Rather than 0 for length meaning "all possible length", it
now means 0, and -1 means "all possible length". All demos,
tests, and PoCs have been updated. #422
4 years ago
nick black 126145e417
demo: convert to new notcurses_stddim_yx() where appropriate #365 4 years ago
nick black bae60a98e7
demo: all demos can be interrupted via demo_render() 4 years ago
nick black 54c57b3487 s/CELL_STYLE/NCSTYLE/ throughout 4 years ago
Nick Black da0283ac25
Selector widget #166, subtitles #95 (#301)
Get rid of annoying empty line in notcurses-view (and ncvisuals at offsets in general)
Implement most of the Selector widget. Need to add styling and scrolling still. #166
Reenable ubuntu focal build
Subtitles! We decode them, and display them in notcurses-view. If ncvisual_simple_streamer() is provided an extra ncplane, it will use it to display subtitles. #95
We now build Python by default, as things are working much better.
ncplane_set_base() now takes channel, attrword, and EGC, so you can usually avoid having to set up and release a cell. ncplane_set_base_cell() takes over duty from ncplane_set_base() for ease of conversion.
notcurses-demo and notcurses-view now both accept a 0 for delay multiplier, meaning 'go as fast as you possibly can'. Very small multipliers (e.g. 0.00001) no longer cause floating point exceptions.
fading routines no longer cause floating point exceptions on very small timescales.
4 years ago
nick black 4ece4a9075
demo: skip demos which we don't have support for 5 years ago
nick black bb0cdb2b88
demo: add demo_nanosleep() for HUD 5 years ago
nick black b02acd8631
Curry a void* to fader callbacks #284 5 years ago
nick black b2dcc7cdf2 demo: push delaymult through to ncvisuals 5 years ago
nick black dd7f8eff4b
ncvisual_stream: add timescale param 5 years ago
nick black 1a2cccaa18 fold out ncplane_move_cursor_yx() wherever possible #257 5 years ago
nick black bd27e056e7 don't ncvisual_decode+stream #246 5 years ago
nick black 32ff214be2
update demos for ncplane_aligned #237 5 years ago
nick black 2ea4f77875
introduce ncplane_aligned() #237 5 years ago
nick black 014afa348b rename ncplane default -> base #236 5 years ago
nick black c21a04137c curry a void* through ncvisual_stream #113 5 years ago
nick black fb0e03fe89 UMOK: fadecb for faders #162 5 years ago
nick black 91a00b3400 ULTRAMEGAOK: feed the HUD #162 5 years ago
nick black 7f82ac6f16 ULTRAMEGAOK: mouse-moveable HUD #162 5 years ago
Nick Black 63ada9289c
Implement CELL_ALPHA_BLEND, improve transparency semantics #191 (#219)
* channels_blend() introduced
* implement CELL_ALPHA_BLEND #191
* maxcolor demo: slidingpanel
* much improved transparency semantics #191
* maxcolor: show all transparencies #191
5 years ago
nick black 452e1d302e
output API enhancements #210 #209
Allow -1 in move specification to remain where we are on that
axis (#210), necessary for context-sensitive aligned output.
Add _aligned forms to printf and vprintf. Invert various output
functions so that simpler form is static inline wrapper around
more complicated form, rather than complicated form being a
static inline composition, facilitating atomic move+output. All
output forms now have a simple form (no alignment, placement at
cursor), an _aligned() form, and a _yx() form.
5 years ago
nick black 046d0314b9
add links to useful man pages 5 years ago
nick black fe7b6bbf89
Samoa, tula'i ma sisi ia lau fu'a, lou pale lea! 5 years ago
Nick Black 3ad2124246
Partial visual renders #170 (#193)
* ncvisual_render() accept four bounding dims #175
* ncvisual_render(): partial renders #175
5 years ago
Nick Black 0e0925a84e
Planereel exploration app, panelreel logic fixes (#188)
* planereels tester #180
* suppress_banner in all tests
* tabletcb: start passing back tablet
* properly initialize fbbytes stat
* panelreel: logic fixes #178
* install all testing data
5 years ago
nick black 15ac1d0411
outro: balance up messages for centering 5 years ago
Nick Black 2de07f8a48
Per-line damage map, ~50% increase in FPS on notcurses-demo (#144)
Implement a fairly conservative, line-granularity, two-level damage map. One on the overall notcurses object is dirtied by planar moves, creations, deletions, and resizes. One on each ncplane is dirtied by glyph output, media rendering, fades, and erasure. #83 This has some definite false positives: a hidden plane which moves will damage a bunch of lines unnecessarily. For now, don't do things like that :D.

Extra byte per line per plane, shouldn't be a problem.

Two new stats for cell elisions and emissions

Allow keypress to interrupt view-demo

ncvisual_stream() now allows a callback per frame

Allow ncvisual_open() to create its own, perfectly-sized, ncplane #128

Typical performance prior to this PR:

4655 renders, 18.3s total (0.000305s min, 0.196s max, 0.0039s avg 253.9 fps)
401046.505KB total (9.688KB min, 139.697KB max, 86.15KB avg)
Emits/elides: def 1082115/116196 fg 10547624/7236460 bg 10602717/6208644
 Elide rates: 9.70% 40.69% 36.93%
4680 renders, 18.4s total (0.000285s min, 0.15s max, 0.0039s avg 255.0 fps)
403078.188KB total (9.688KB min, 139.697KB max, 86.13KB avg)
Emits/elides: def 1088994/116196 fg 10604983/7267750 bg 10655426/6237472
 Elide rates: 9.64% 40.66% 36.92%
4699 renders, 17.8s total (0.000227s min, 0.192s max, 0.0038s avg 263.8 fps)
403266.907KB total (9.688KB min, 139.697KB max, 85.82KB avg)
Emits/elides: def 1086511/116196 fg 10601709/7359116 bg 10661910/6326744
 Elide rates: 9.66% 40.97% 37.24%

After this PR:

5625 renders, 15s total (9.36e-05s min, 0.187s max, 0.0027s avg 375.2 fps)
168365.640KB total (0.930KB min, 139.600KB max, 29.93KB avg)
Emits/elides: def 310575/116196 fg 4486002/4473416 bg 4116835/4630666
 Elide rates: 27.23% 49.93% 52.94%
Cells emitted; 9928000 elided: 12572000 (55.88%)
5642 renders, 14.2s total (9.17e-05s min, 0.154s max, 0.0025s avg 397.0 fps)
168669.009KB total (0.605KB min, 139.600KB max, 29.90KB avg)
Emits/elides: def 310819/116196 fg 4499833/4482134 bg 4118562/4652470
 Elide rates: 27.21% 49.90% 53.04%
Cells emitted; 9962160 elided: 12605840 (55.86%)
5650 renders, 14.3s total (0.000118s min, 0.143s max, 0.0025s avg 395.7 fps)
169461.884KB total (0.860KB min, 139.600KB max, 29.99KB avg)
Emits/elides: def 305431/116196 fg 4515396/4456376 bg 4149967/4613668
 Elide rates: 27.56% 49.67% 52.65%
Cells emitted; 9945200 elided: 12654800 (55.99%)

on netcurses-demo, we're eliding about half of the total cells via this damage map. that's pretty fucking sweet! FPS increase of about 50% -- I'll take that any day of the fuckin' week, boyo. w00t!

https://www.youtube.com/watch?v=XbGs_qK2PQA
5 years ago
Nick Black 8bd8055f72
Distinct fg/bg alpha channels #139 (#141)
* improved alpha macros
* demo: use new alpha macros
* add ncplane_set_*_alpha()
* explicitly set fg for uniblock
* outro: background is a space #139
* distinct alpha channels for fg/bg #139
* rename 'background' cell to 'default' #142
* doc palette fades
5 years ago
Nick Black ff463d464e
Channels API sanity #119 (#138)
* orthogonalize channel/channels/cells APIs #119
* sync README.md with new ncplane channels api #119
5 years ago
nick black 21c4a9a2eb
demos: use ncalign_center throughout 5 years ago
nick black 66fa8854f3 outro effects 5 years ago
nick black 5e5abd7cbd extract outro 5 years ago