[FFmpeg-devel] [PATCH v2 7/8] avfilter/sleet: Add sleet filter

Moritz Barsnick barsnick at gmx.net
Fri Sep 3 11:23:42 EEST 2021


On Tue, Aug 31, 2021 at 22:49:12 +0000, Soft Works wrote:
> As for the "sleet" filter: Yes - it is totally useless for practical
> use. I had explained why I added it in the 0/8 message:
>
> > Why leet? Real world use is surely questionable, but it has two advantages
> > that make it a great choice for testing:
> > You can see from almost every single line whether it has been filtered,
> > and the text is still readable which allows to verify that timings are
> > still valid.

Okay, I get that case, though it seems a bit special. Isn't this just a
debug feature for developers then?

> Much more useful examples for textsub>>textsub filters would be like:
>
> - Censoring filter
> - Translation filter (lingual)
> - Include Actor Name filter
>
> Though, I wanted to have something super-simple for demonstration of the
> new ability to have textsub>>textsub filters.

Well, at least it demonstrates the boilerplate required for a simple
S->S filter, which touches only text (no timings or positioning or so).
A review of this boilerplate would be great.

For the sake of review:
- You need to add documentation to doc/filters.texi.
- You need to bump MINOR in libavfilter/version.h.

> Maybe an "sallcaps" filter makes slightly more sense than "sleet"?

For the sake of usability, I would rather have suggested something like
"tr" (https://linux.die.net/man/1/tr,
https://www.geeksforgeeks.org/perl-tr-operator/), where you can specify
the replacement list. That said, tr has some funky shortcuts ("[a-z]
[A-Z]" for uppercase, which may be harder to implement). Or actual
regular expression support.

What I suggest is still not really useful for a user, though. Or is it?

Cheers,
Moritz


More information about the ffmpeg-devel mailing list