Determine if an the contents of an image are photographic or not.
This is a re-implementation of Julio Barba's screen content detection algorithm used in the SVT-AV1 project. A reference implementation can be found here.
This implementation is written in Zig. It accepts PNG, QOI, and NetPBM images (PBM, PGM, PPM, PNM, and PAM) to compute screen content determination.
Usage: scc-detect [--fast] <input-image>The output will be a member of the ScreenContentClass enum, which is printed
to the terminal when using this tool's CLI.
Example inputs are provided in the examples/ directory in this repository.
Providing the --fast flag skips every other block to improve detection speed
at a small accuracy penalty.
OUT_SC_PHOTO: Likely photographic contentOUT_SC_BASIC: Basic screen content detectedOUT_SC_HIVAR: Screen content + high varianceOUT_SC_MED: Stronger screen content indication (relaxed variance requirement)OUT_SC_HIGH: Strongest screen content indication
More information is provided in the annotated C reference implementation.