% This is a simple script to show the usage of the code
% For any information please write to: marco.fontani@unisi.it

% Load image (convert to grayscale if needed)
im = imread('demoimg.jpg');
if size(im,3)>1
    im = rgb2gray(im);
end

% Process image (contrast enhancement by gamma correction)
gamma = 1.9;
attacked = uint8(255 * (double(im) / 255) .^ gamma);            

% Remove traces from histogram
histogram_universal_antiforensics(attacked,4);