Commit Graph
30 Commits
Author SHA1 Message Date
Kovid Goyal 9fe22a5c27 Do a single pass over the cell vertex shader to set the defines 2022-02-04 14:34:41 +05:30
Kovid Goyal 3c2e521dd7 Make blending of foreground more efficient
Avoids an unnecessary reversal of premultiplication when rendering
interleaved.  Also fixes rendering on wayland which for some reason was
using a different blend function than X11. Fixes #4120
2021-10-14 21:31:20 +05:30
Kovid Goyal 083a0ae5fc ... 2021-05-16 09:33:06 +05:30
Kovid Goyal a1125b5cc8 Move draw_bg multiplication into vertex shader 2020-01-21 07:58:34 +05:30
Kovid Goyal d8ed135b46 Clean up rendering of cell backgrounds 2020-01-12 13:20:23 +05:30
Kovid Goyal f44c3a4606 Forgot to update comment describing render pipeline 2020-01-12 10:26:25 +05:30
Kovid Goyal 714bee7f45 Only use an extra draw call for the background when drawing interleaved cells if it is actually required 2020-01-12 09:37:16 +05:30
Kovid Goyal 789d649b5c defaultbg should be a local variable 2020-01-11 16:59:50 +05:30
Fredrick Brennan 8020657d8c Allow drawing images below cells w/background 2020-01-11 16:56:59 +05:30
Kovid Goyal 721beb9202 More docs for the cell fragment shader 2019-06-14 11:11:43 +05:30
Kovid Goyal a5aca35f1c Simplify and document the operation of the cell fragment shader
Also get rid of the unneccessary double bg_alpha followed by divide by
alpha step when rendering interleaved and premult
2019-06-12 10:22:47 +05:30
Kovid Goyal a827f4190c Merge branch 'fix_white_background_transparency' of https://github.com/Luflosi/kitty 2019-01-14 13:10:15 +05:30
Luflosi 490d4455af Fix white background color not allowing transparency 2019-01-08 16:14:01 +01:00
Kovid Goyal 4a8562a85f Fix setting background_opacity causing window margins/padding to be slightly different shade from background
Fixes #1221
2018-12-11 08:36:03 +05:30
Luflosi 96229becd1 Make final_color computation consistent across cases 2018-11-22 11:36:29 +01:00
Kovid Goyal 074614bc8e Fix incorrect text-antialiasing when using very low background opacity
Fix #1005
2018-11-22 10:26:40 +05:30
Kovid Goyal f8395e36a1 Draw underlines under the text instead of over it 2018-09-03 09:48:53 +05:30
Kovid Goyal 490ae248f8 Render all cursor shapes in the cell shader 2018-07-19 14:05:15 +05:30
Kovid Goyal 6f2d63eb87 Implement SGR dim
kitty now supports the SGR DIM escape code, which makes text fade into
the background. It works by alpha blending the text color into the
background color. Fixes #446
2018-05-20 10:43:26 +05:30
Kovid Goyal b01c3483de Add an option to fade text in inactive windows
Fixes #256
2017-12-28 10:36:48 +05:30
Kovid Goyal b8faba2a16 More trailing space removal 2017-12-20 08:50:09 +05:30
Kovid Goyal 8d7515bd9b Basic color emoji rendering working
Still need to downscale color bitmaps to fit into cells
2017-12-09 12:01:43 +05:30
Kovid Goyal b51100195a Dont use FBO's unless absolutely necessary
Negative z-index images dont need FBO based rendering when the
background is opaque. Finishes up support for background_opacity.

Fixes #31
2017-12-01 12:16:16 +05:30
Kovid Goyal be6151730d Fix SPECIAL stage in interleaved rendering 2017-12-01 12:16:15 +05:30
Kovid Goyal f85c050235 Get background_opacity working, at the cost of breaking negative z-index image rendering.
Image rendering will need to use an FBO since OpenGL cannot do proper alpha compositing.
As a first step, the interleaved shaders now generate premultiplied colors as opengl can only alpha blend pre-multipled colors
2017-12-01 12:16:14 +05:30
Kovid Goyal 1fb81d2265 Fix incorrect blending of foreground and background colors when negative z-index images are present
Also optimize the blending calculation a bit by using the mix() function
and just adding the text and strike alphas.
2017-12-01 12:16:14 +05:30
Kovid Goyal e1650d5df7 Implement interleaved drawing of cells 2017-10-04 16:11:20 +05:30
Kovid Goyal ead73c8209 Prepare for two stage rendering of cells 2017-10-04 14:15:51 +05:30
Kovid Goyal a44e3a3a50 Ensure line numbers reported by the GLSL compiler are correct 2017-09-15 10:45:08 +05:30
Kovid Goyal fe3e51a00d Move the GLSL shaders into their own files 2017-08-21 16:39:34 +05:30