diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2020-02-21 22:40:35 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2020-02-21 22:40:35 +0000 |
| commit | f0fc82f0987166b3fe4724e50da05ba611231c67 (patch) | |
| tree | 4e5a171dd1081af70e3e482d3969be8168177363 /terminal.h | |
| parent | Merge branch 'master' into sixel-graphics (diff) | |
sixel: wip: maintain a list of finished, and "active" sixel images
In unhook, add the generated image to a list of finished sixel images,
along with positioning and size information.
When rendering, loop this list of images, and render the images (or
parts of) that are visible.
When scrolling, check if any part of the images cover the re-cycled
lines, and if so, remove the *entire* image from the list.
This means we have the following limitations:
* The renderer always renders the whole (visible area of) the
image(s). There are times when this isn't necessary - for example,
when the image is scrolled inside the visible area.
* It would be nice if we could crop the image when parts of it is
scrolled out.
Diffstat (limited to 'terminal.h')
| -rw-r--r-- | terminal.h | 12 |
1 files changed, 10 insertions, 2 deletions
@@ -175,6 +175,14 @@ struct ptmx_buffer { size_t idx; }; +struct sixel { + void *data; + pixman_image_t *pix; + int width; + int height; + struct coord pos; +}; + struct terminal { struct fdm *fdm; const struct config *conf; @@ -357,10 +365,10 @@ struct terminal { unsigned int param; unsigned param_idx; - - pixman_image_t *pix; } sixel; + tll(struct sixel) sixel_images; + bool hold_at_exit; bool is_shutting_down; void (*shutdown_cb)(void *data, int exit_code); |
