| Commit message (Collapse) | Author | Age | Lines | |
|---|---|---|---|---|
| * | sixel: split -> overwrite | Daniel Eklöf | 2020-06-27 | -15/+15 |
| | | ||||
| * | term: erasing characters now splits sixels instead of deleting them | Daniel Eklöf | 2020-06-27 | -12/+22 |
| | | ||||
| * | sixel: delete/split: early(ier) exit when there aren't in sixel images | Daniel Eklöf | 2020-06-27 | -9/+16 |
| | | | | | Avoid unnecessary wrap checks if the sixel image list is empty. | |||
| * | sixel: split: make pixman instantiation generic | Daniel Eklöf | 2020-06-27 | -34/+27 |
| | | ||||
| * | sixel: never generate scrollback wrapping sixel images | Daniel Eklöf | 2020-06-27 | -53/+96 |
| | | | | | | | Instead, split them up into two (or more...). This makes the intersection detection logic *much* simpler. | |||
| * | sixel: refactor handling of wrap-around delete- and split regions | Daniel Eklöf | 2020-06-27 | -39/+99 |
| | | | | | | | | | | Handle these on a higher abstraction level. The low level functions that detect sixel intersections now assume the specified rectangle (or line region) does *not* cross the wrap-around. This is ensured by detecting a wrap-around region before hand, and splitting it up into two, non wrapping regions. | |||
| * | sixel: split_by_rectangle: bug: typo in boundary check | Daniel Eklöf | 2020-06-27 | -1/+1 |
| | | ||||
| * | sixel: split: make sure relative row/column values are bounded | Daniel Eklöf | 2020-06-27 | -4/+4 |
| | | ||||
| * | sixel: split: push front instead of back | Daniel Eklöf | 2020-06-27 | -4/+4 |
| | | | | | | | This reduces the burden on sixel_split_by_rectangle(), which would otherwise consider the newly added/splitted sixels. Since we already know they aren't covered by the specified rectangle, we can skip that. | |||
| * | sixel: add sixel_split_by_rectangle() | Daniel Eklöf | 2020-06-27 | -57/+74 |
| | | | | | | | | | | This function splits a sixel image into up to four pieces. The four pieces correspond to the relative complement (set difference) of the sixel image and the specified rectangle. Use this function when (possibly) overwriting existing sixel images when generating a new one, i.e. in sixel_unhook(). | |||
| * | sixel: hopefully fix erasing of scrollback wrap-around sixels | Daniel Eklöf | 2020-06-27 | -10/+27 |
| | | | | | | | If a sixel image crossed the scrollback wrap around, the logic that detected whether a row, or a row range, intersected with the sixel was incorrect. | |||
| * | sixel: wip: split up image being overwritten, rather than erasing it | Daniel Eklöf | 2020-06-23 | -1/+139 |
| | | | | | | | | | | | Instead of completely erasing a sixel image when it is being "overwritten" (text is printed somewhere within the image, or another sixel image is emitted within the first image), split it up into up to four pieces: 'above', 'below', 'to-the-left' and 'to-the-right'. This is currently very un-optimized, but seems to produce correct results. | |||
| * | sixel: if the client has specified a size, do not change that | Daniel Eklöf | 2020-06-11 | -5/+16 |
| | | | | | | | | | | | | | | We used to auto-resize images to always be a multiple of 6. This is incorrect. The client may, for example, have specified a size to align the image to a cell boundary, which may not be a multiple of 6. Furthermore, in e.g. Jexer, which splits up an image into stripes, that the next image would "overwrite" the previous one. Since the next image was started on a cell row that the previous image had overflowed into. | |||
| * | sixel: only use configured alpha when color matches the default bg | Daniel Eklöf | 2020-06-10 | -4/+11 |
| | | ||||
| * | sixel: don't erase if cursor is *before* the image | Daniel Eklöf | 2020-06-10 | -1/+2 |
| | | ||||
| * | sixel: do not reset palette after each image | Daniel Eklöf | 2020-06-10 | -5/+18 |
| | | | | | | | | | A client can re-use the palette between images. Resetting the palette breaks this. Now we initialize the palette on demand, and resets it when the palette size is changed (by the client). | |||
| * | sixel: log message: fix spelling | Daniel Eklöf | 2020-06-09 | -1/+1 |
| | | ||||
| * | sixel: don't erase image when printing text *next* to it. | Daniel Eklöf | 2020-06-06 | -5/+18 |
| | | ||||
| * | sixel: fix asan runtime warning: left shift of 255 by 24 cannot... | Daniel Eklöf | 2020-06-06 | -4/+4 |
| | | | | | be represented in type 'int' | |||
| * | util.h: new header file defining commonly used macros | Daniel Eklöf | 2020-05-01 | -5/+1 |
| | | ||||
| * | grid: move 'cursor' state from terminal to grid | Daniel Eklöf | 2020-04-16 | -3/+3 |
| | | | | | | This way, the 'normal' and 'alt' grids have their own cursor state, and we don't need to switch between them. | |||
| * | sixel: improve handling of images when reflowing the grids | Daniel Eklöf | 2020-03-13 | -14/+7 |
| | | | | | | | | | | | | Update the sixels' 'row' attribute when re-flowing a grid, to ensure it is rendered at the correct place. This should work in most cases, but will break when the cell size has changed (e.g. font size increase/decrease, or a DPI change). This patch also moves the sixel image list from the terminal struct into the grid struct. The sixels are per-grid after all. | |||
| * | sixel: don't try to dirty an un-allocated row | Daniel Eklöf | 2020-03-06 | -0/+5 |
| | | | | | This may happen e.g. when resizing a grid | |||
| * | sixel: CSI setters also write a reply to the client | Daniel Eklöf | 2020-02-24 | -5/+9 |
| | | ||||
| * | term: term_erase(): call sixel_delete_*() | Daniel Eklöf | 2020-02-24 | -2/+2 |
| | | | | | | This ensures sixel images are removed, regardless of _how_ the screen was erased. | |||
| * | sixel: ensure 'start' row is not outside the grid row range | Daniel Eklöf | 2020-02-24 | -1/+3 |
| | | ||||
| * | sixel: add sixel_delete_at_row and sixel_delete_in_range | Daniel Eklöf | 2020-02-24 | -7/+65 |
| | | | | | | These are utility functions to erase sixel images that are at the specified row, or in a row range. | |||
| * | sixel: destroy_at_cursor(): skip images on 'other' grid | Daniel Eklöf | 2020-02-22 | -0/+3 |
| | | ||||
| * | sixel: track which grid image was created on | Daniel Eklöf | 2020-02-22 | -0/+1 |
| | | ||||
| * | sixel: rename: purge_at_cursor() -> delete_at_cursor() | Daniel Eklöf | 2020-02-22 | -2/+2 |
| | | ||||
| * | sixel: purge images in unhook, rather than in init | Daniel Eklöf | 2020-02-22 | -2/+2 |
| | | | | | | This fixes an issue where the cursor was seen blinking in animated GIFs. | |||
| * | sixel: purge images at current cursor row | Daniel Eklöf | 2020-02-22 | -7/+18 |
| | | | | | | When printing a character, or starting a new sixel image, purge all images that cover the cursor's current row. | |||
| * | sixel: oops | Daniel Eklöf | 2020-02-22 | -2/+2 |
| | | ||||
| * | sixel: don't ever shrink the image | Daniel Eklöf | 2020-02-22 | -3/+9 |
| | | ||||
| * | sixel: add HLS color format support | Daniel Eklöf | 2020-02-22 | -2/+5 |
| | | ||||
| * | sixel: add comments to max_width()/max_height() | Daniel Eklöf | 2020-02-22 | -0/+2 |
| | | ||||
| * | sixel: application configurable image max width/height | Daniel Eklöf | 2020-02-22 | -3/+72 |
| | | ||||
| * | sixel: application configurable palette size (color count) | Daniel Eklöf | 2020-02-22 | -6/+35 |
| | | | | | | This implements the CSI escapes for retrieving and (re)setting the palette size. | |||
| * | sixel: use terminal's background color, not palette[0] | Daniel Eklöf | 2020-02-22 | -3/+3 |
| | | ||||
| * | sixel: finalize: use width/height from image, not row/col pos | Daniel Eklöf | 2020-02-22 | -10/+4 |
| | | ||||
| * | sixel: resize: initialize new rows/columns with the background color | Daniel Eklöf | 2020-02-22 | -9/+15 |
| | | ||||
| * | sixel: mention why we add one | Daniel Eklöf | 2020-02-22 | -1/+3 |
| | | ||||
| * | sixel: clean up state machine | Daniel Eklöf | 2020-02-22 | -91/+97 |
| | | | | | | Use proper state names, and implement the state machine using switch statements. | |||
| * | sixel: use a struct coord for current sixel position | Daniel Eklöf | 2020-02-22 | -24/+22 |
| | | ||||
| * | sixel: rename state SIXEL_SIXEL -> SIXEL_GROUND | Daniel Eklöf | 2020-02-22 | -6/+6 |
| | | ||||
| * | sixel: raster: only resize image buffer if necessary | Daniel Eklöf | 2020-02-22 | -1/+3 |
| | | ||||
| * | sixel: resize image buffer after receiving a "raster" command | Daniel Eklöf | 2020-02-22 | -0/+1 |
| | | ||||
| * | sixel: resize image buffer dynamically | Daniel Eklöf | 2020-02-22 | -23/+80 |
| | | ||||
| * | sixel: add sixel_destroy() | Daniel Eklöf | 2020-02-21 | -4/+13 |
| | | ||||
| * | sixel: always bump row on unhook | Daniel Eklöf | 2020-02-21 | -6/+4 |
| | | ||||
| * | sixel: ugly hack to remove over-written sixel images | Daniel Eklöf | 2020-02-21 | -0/+8 |
| | | ||||
| * | sixel: calculate image height in (cell) rows | Daniel Eklöf | 2020-02-21 | -0/+1 |
| | | ||||
| * | sixel: wip: maintain a list of finished, and "active" sixel images | Daniel Eklöf | 2020-02-21 | -24/+20 |
| | | | | | | | | | | | | | | | | | | | | 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. | |||
| * | sixel: initial support | Daniel Eklöf | 2020-02-21 | -0/+284 |
| This implements basic parsing of sixel data. Lots of limitations and temporary solutions as this is still work-in-progress: * Maximum image size hardcoded to 800x800 * No HLS color format support * Image is always rendered at 0x0 in the terminal | ||||
