ikz87 / picom-shaders Goto Github PK
View Code? Open in Web Editor NEWglsl window shaders for picom
glsl window shaders for picom
When setting up the shaders in my rice, i realized that picom can't apply more than one shader per window, so i had to combine the border shader and the transparency shader to properly work together resulting in code redundancy in the shaders.
So i had this idea, that every shader could be transformed into a simple function that takes the pixel and/or coords and all the configuration options as function arguments.
This would make combining and reordering shaders easy.
Problem is, that glsl doesn't support any #import
stuff so the functions would either need to be in the same file, or imported in some other funky way.
Having it in the same file doesn't remove code redundancy, but importing in other funky ways seems complicated as fuck:
https://stackoverflow.com/questions/25978295/import-function-from-different-shader
https://stackoverflow.com/questions/10754437/how-to-using-the-include-in-glsl-support-arb-shading-language-include
What do you think?
Since you seem to be knowing how to code shaders,
do you think it would be possible to overlay stuff over the windows?
Like for example rounded borders, fixing the problem with picoms rounding features cutting of i3 borders.
(i know xborders exist, but doing it with shaders would be way more elegant)
As far as I have understood shaders, it is generally possible, to draw stuff, but since picoms shaders are just "GLSL fragment shaders", I'm not entirely sure.
Here's a list of them: https://github.com/libretro/docs/blob/master/docs/shader/crt.md
CRT Lottes is a really good one and it is pretty accurate.
Crt Royale is not only accurate, it looks really great and its configurable. there's also CRT Mattias, which isn't that accurate but looks "nostalgic", a lot of artifacts, which a lot of people seem to like.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.