Skip to content

Latest commit

 

History

History
77 lines (56 loc) · 1.67 KB

README.md

File metadata and controls

77 lines (56 loc) · 1.67 KB

Description

A color constancy filter that applies color correction based on the grayworld assumption.

For more info.

This is a port of the FFmpeg filter grayworld.

Requirements:

  • AviSynth+ 3.6 or later and/or VapourSynth R55 or later

  • Microsoft VisualC++ Redistributable Package 2022 (can be downloaded from here) (Windows only)

AviSynth+ usage:

grayworld (clip input, int "opt", int "cc")

VapourSynth usage:

grwrld.grayworld(clip input, int "opt", int "cc")

Parameters:

  • input
    A clip to process.
    Must be in RGB(A) 32-bit planar format and in linear light.

  • opt
    Sets which cpu optimizations to use.
    -1: Auto-detect.
    0: Use C++ code.
    1: Use SSE2 code.
    2: Use AVX2 code.
    3: Use AVX512 code.
    Default: -1.

  • cc
    Color correction mode.
    0: Mean.
    1: Median. This mode is not affected by extreme values in luminance or chrominance.
    Default: 0.

Building:

  • Windows
    Use solution files.

  • Linux

    Requirements:
        - Git
        - C++17 compiler
        - CMake >= 3.16
    

    CMake options:

    -DBUILD_AVS_LIB=ON  # Build library for AviSynth+.
    -DBUILD_VS_LIB=ON   # Build library for VapourSynth.
    
    git clone https://github.com/Asd-g/AviSynthPlus-grayworld && \
    cd AviSynthPlus-grayworld && \
    mkdir build && \
    cd build && \
    
    cmake ..
    make -j$(nproc)
    sudo make install