Skip to content

Add pixels0rt filter#241

Open
namikiri wants to merge 2 commits intodyne:masterfrom
namikiri:pixels0rt
Open

Add pixels0rt filter#241
namikiri wants to merge 2 commits intodyne:masterfrom
namikiri:pixels0rt

Conversation

@namikiri
Copy link
Contributor

Pixel sorting, now for all open and awesome video editors!

This filter implements 4-directional pixel sorting based on threshold with direct and reversed sorting order and transparency threshold for using it in masks.

Thresholds are keyframe-friendly and accept values from 0 to 1.

The result looks like this:
изображение

Additionally, this commit adds CMakeCache.txt into .gitignore. I couldn't remove it from the commits so please let me know how to fix that if it's a problem.

Any comments on the code are appreciated.

@namikiri
Copy link
Contributor Author

Optional but might be useful: QML files for Shotcut which I was using during the effect development:
https://gist.github.com/namikiri/84b092891c2717ca70402054968c3b15

They can be made a bit incorrectly as I'm new to QML and just took another effects as examples.

@shadowfax65
Copy link

shadowfax65 commented Jan 10, 2026

@namikiri: What are the values for the different directions? From the QML file I thought 0 (top to bottom), 1 (bottom to top), 2 (left to right), 3 (right to left), but the value range is limited from 0 to 1. The .c file also suggests 0/1/2/3 but when I try this in Kdenlive only 0 (top to bottom) works.

I can get it to work with 0, 0.25, 0.5, and 0.75 ;-)

@namikiri
Copy link
Contributor Author

@shadowfax65

I can get it to work with 0, 0.25, 0.5, and 0.75 ;-)

You have guessed it right! As Frei0r parameter types are BOOL, STRING, COLOR and DOUBLE, I chose the most suitable variant to pass the direction into the filter by dividing the range 0..1 into 4 subranges.

Features:
* 4-directional sorting
* direct and reverse order
* transparency threshold for masking
@luzpaz
Copy link
Contributor

luzpaz commented Jan 30, 2026

Thanks for working on this. Looking forward to this getting merged.

@shadowfax65
Copy link

Thanks for working on this. Looking forward to this getting merged.

Any idea when this will happen, @jaromil?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

Comments