summaryrefslogtreecommitdiffstats
path: root/video/out/vo_tct.c
Commit message (Collapse)AuthorAgeFilesLines
* terminal: add terminal_set_mouse_input functionnanahi8 days1-2/+2
| | | | This function is used to enable/disable mouse input for win32 and unix.
* vo_{tct,sixel,kitty}: implement mouse supportnanahi8 days1-0/+2
|
* bstr: change bstr0_s to bstr0_lit, restrict it only for string literalsKacper Michajłow2024-04-081-10/+10
| | | | | | | | | Allows to avoid non-portable strlen usage. Also avoid "initializer element is not constant" warnings on older GCC that doesn't like explicit type specification in aggregate initialization. Co-authored-by: NRK <nrk@disroot.org> Co-authored-by: nanahi <130121847+na-na-hi@users.noreply.github.com>
* vo_tct: reduce lut_item size and generate it without snprintfKacper Michajłow2024-04-071-6/+11
|
* vo_tct: use fwrite when appropriateKacper Michajłow2024-04-071-11/+9
|
* vo_tct: add synchronized output supportKacper Michajłow2024-04-071-0/+4
| | | | See-Also: https://gist.github.com/christianparpart/d8a62cc1ab659194337d73e399004036
* vo_tct: add --vo-tct-buffering optionKacper Michajłow2024-04-071-9/+36
|
* misc/bstr: add bstr0_s for static initializationKacper Michajłow2024-04-071-12/+12
|
* vo_tct: write frame fully instead of every pixelKacper Michajłow2024-04-071-48/+44
| | | | | | | This is multiple times faster than just writing every pixel sequence separately. Especially on slower terminal emulators. In general no need to stress I/O, while we can just prepare the frame to print and do it once.
* vo: fully replace draw_image with draw_frameDudemanguy2023-10-011-5/+6
| | | | | | | | | | | | 0739cfc20934ac7772ab71dbae7ecba4ba10fda4 added the draw_frame API deprecated draw_image internally. VOs that still used draw_image were around, but really there's no reason to not just "upgrade" them anyway. draw_frame is what the "real" VOs that people care about (gpu/gpu-next) use. So we can just simplfy the code a bit now. VOCTRL_REDRAW_FRAME is also no longer needed so that can be completely deleted as well. Note that several of these VOs are legacy crap anyway (e.g. vaapi) and maybe should just be deleted but whatever. vo_direct3d was also completely untested (not that anyone should ever use it).
* options: transition options from OPT_FLAG to OPT_BOOLChristoph Heinrich2023-02-211-2/+2
| | | | | | c78482045444c488bb7948305d583a55d17cd236 introduced a bool option type as a replacement for the flag type, but didn't actually transition and remove the flag type because it would have been too much mundane work.
* video: replace sprintf usagesfan52023-01-121-1/+1
|
* osdep/terminal.h: Rename screen buffer controlsMia Herkt2022-12-201-2/+2
| | | | SAVE/RESTORE were a bit misleading.
* vo_tct: Use newer options APIMia Herkt2022-12-191-28/+24
|
* osdep/terminal: Move common esc codes to terminal.hMia Herkt2022-12-191-26/+22
|
* vo_tct: Use the alternate buffer to restore termMia Herkt2022-12-191-3/+7
|
* vo_tct: add resize capabilityCloud116652021-08-261-0/+7
| | | | No performance penalty added by getting the terminal size every frame.
* vo_tct: fix --vo-tct-256Avi Halachmi (:avih)2021-08-161-3/+3
| | | | | | | | | | | | | | | This is a regression from cbbd81bb (the previous commit): print_seq1 (which prints a sequence with 1 parametric byte value) is used with 256 colors output, and apparently was never tested. Two issues were introduced at the offending commit: 1. The ";5" part was incorrectly removed from the strings ESC_COLOR256_{BG,FG} (affects both *nix and Windows). 2. On windows only - a semicolon was not used after the prefix. Both issues resulted in an invalid 256 colors sequences and output.
* vo_tct: optimize print function on non-windows platformsCloud116652021-08-161-14/+57
| | | | Using fwrite on non-windows platforms yields a ~25% performance increase.
* vo_tct: fix half-block on windowsAvi Halachmi (:avih)2021-08-161-0/+1
| | | | | | | On windows the UTF-8 strings are translated to wchar_t when printed to the console, and some escape sequences are also translated, however, this only works when printf is mapped to mp_printf, and for that to happen we need to include osdep/io.h .
* vo_tct: don't leak the frame referenceAvi Halachmi (:avih)2020-11-291-0/+5
| | | | | | The reference is allocated at reconfig (and leaked at least once), but could theoretically be called more than once by mpv, or in the future when the tct code is enhanced to hande e.g. pan-and-scan changes.
* vo_tct: remove unused variableAvi Halachmi (:avih)2020-11-291-7/+0
|
* video/out/vo_tct: query terminal size genericallyAvi Halachmi (:avih)2020-04-231-7/+3
| | | | | terminal_get_size also works on windows. This is useful because now tct also works on Windows with native VT console.
* options: change option macros and all option declarationswm42020-03-181-6/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change all OPT_* macros such that they don't define the entire m_option initializer, and instead expand only to a part of it, which sets certain fields. This requires changing almost every option declaration, because they all use these macros. A declaration now always starts with {"name", ... followed by designated initializers only (possibly wrapped in macros). The OPT_* macros now initialize the .offset and .type fields only, sometimes also .priv and others. I think this change makes the option macros less tricky. The old code had to stuff everything into macro arguments (and attempted to allow setting arbitrary fields by letting the user pass designated initializers in the vararg parts). Some of this was made messy due to C99 and C11 not allowing 0-sized varargs with ',' removal. It's also possible that this change is pointless, other than cosmetic preferences. Not too happy about some things. For example, the OPT_CHOICE() indentation I applied looks a bit ugly. Much of this change was done with regex search&replace, but some places required manual editing. In particular, code in "obscure" areas (which I didn't include in compilation) might be broken now. In wayland_common.c the author of some option declarations confused the flags parameter with the default value (though the default value was also properly set below). I fixed this with this change.
* video/out/vo_tct: Use octal escape sequence instead of non-standard \eMichael Forney2019-11-181-9/+9
|
* sws_utils: shuffle around some shitwm42019-10-311-3/+2
| | | | | | | | | | | Purpose uncertain. I guess it's slightly better, maybe. The move of the sws/zimg options from VO opts (vo_opt_list) to the top-level option list is tricky. VO opts have some helper code in vo.c, that sends VOCTRL_SET_PANSCAN to the VO on every VO opts change. That's because updating certain VO options used to be this way (and not just the panscan option). This isn't needed anymore for sws/zimg options, so explicitly move them away.
* sws_utils: don't force callers to provide option structwm42018-01-181-1/+1
| | | | | | | mp_sws_set_from_cmdline() has the only purpose to respect the --sws- command line options. Instead of forcing callers to get the option struct containing these, let callers pass mpv_global, and get it from the option core code directly. This avoids minor annoyances later on.
* vo_tct: check ioctl resultrr-2017-02-201-6/+6
|
* vo_tct: support also 256 colors outputAvi Halachmi (:avih)2016-10-251-9/+55
|
* vo_tct: optional custom size, support non-posix with 80x25 defaultAvi Halachmi (:avih)2016-10-251-5/+31
| | | | Also, replace the UTF8 half block char at the source code with C escape.
* vo_tct: introduce modern caca alternativerr-2016-10-201-0/+234