mirror of
https://github.com/kovidgoyal/kitty.git
synced 2026-10-21 04:32:05 +00:00
Custom shaders: Redraw static effects only on demand
This commit is contained in:
parent
cf33820973
commit
7b41e33399
5 changed files with 18 additions and 6 deletions
|
|
@ -205,7 +205,8 @@ Detailed list of changes
|
|||
- Support for :doc:`/custom-shaders` for adding various graphical effects (:iss:`10344`)
|
||||
|
||||
- Custom shaders: Allow tinting inactive windows toward a configurable color,
|
||||
preserving the tab bar and active window padding.
|
||||
preserving the tab bar and active window padding. Support static effects
|
||||
without periodic redraws.
|
||||
|
||||
- Various throughput performance improvements for a 15-35% real world improvement depending on workload
|
||||
|
||||
|
|
|
|||
|
|
@ -84,6 +84,7 @@ following as :file:`shaders/dim-gray.pipeline` in your kitty config directory an
|
|||
set ``custom_shaders dim-gray`` and ``inactive_text_alpha 1`` in :file:`kitty.conf`::
|
||||
|
||||
startgroup
|
||||
animation_step 0
|
||||
var float HIGHLIGHT_INTENSITY = 0
|
||||
var float BORDER_WIDTH = 0
|
||||
var float INACTIVE_DIM = 0.74
|
||||
|
|
@ -100,7 +101,8 @@ sRGB ``#808080``. The default target is black, preserving the existing dimming
|
|||
effect. The two optional flags preserve the tab bar and include the active
|
||||
window's padding in its unchanged area. Explicit cell backgrounds and images
|
||||
are blended together with text, while transparency and colors reported to
|
||||
terminal applications are preserved.
|
||||
terminal applications are preserved. ``animation_step 0`` makes this static
|
||||
effect redraw only when content or shader events change.
|
||||
|
||||
|
||||
Anatomy of a custom shader
|
||||
|
|
@ -269,7 +271,9 @@ Directives inside a group:
|
|||
How many milliseconds between animation frames. Lower values produce
|
||||
smoother animation at the cost of more GPU draws. Defaults to ``50`` ms
|
||||
(20 fps). The value is clamped to be no smaller than
|
||||
:opt:`repaint_delay`.
|
||||
:opt:`repaint_delay`. Set this to ``0`` for static effects that should
|
||||
redraw only when content or shader events change, without periodic frames.
|
||||
Animation stop events and duration limits still apply.
|
||||
|
||||
``attach``
|
||||
Mark this group as *attached* to the preceding group. An attached group
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue