MATLAB scripts I used when writing the blog artical about aosp auto brightness.
This is simply a reproduce of codes in BrightnessMappingStrategy.java.
Extract your auto brightness overlays here into each table.
% Tables extracted from overlays.
lux = [
];
brightness = [
];
screen_brightness = [
];
screen_backlight = [
];
Set the user data point here to emulate a user input.
% Ambient light and user brightness you want to input.
% Note that brightness must be normalized to [0f, 1f].
user_lux = 12000;
user_backlight = 0.8;
Run it and see the figures.
Basically the last figure ( figure 6 ) is the final auto brightness curve generated from user input. And the other figures are mean to help you understand how each step work.