I am studying the Paint.Net source code from here. The zoom in/out implementation uses following values for scale factors:
private static readonly double[] scales =
{
0.01, 0.02, 0.03, 0.04, 0.05, 0.06, 0.08, 0.12, 0.16, 0.25, 0.33, 0.50, 0.66, 1,
2, 3, 4, 5, 6, 7, 8, 12, 16, 24, 32
};
Source: https://github.com/rivy/OpenPDN/blob/master/src/Core/ScaleFactor.cs
The question I am stuck with is why these hard coded values? I don't wish to limit my question to only these 2-3 lines of code because now I can observe it happening in every other zoomable application. Take an example of chrome. The zoom level in percentage goes like 25, 33, 50, 67, 75, 80, 90, 100, 110, 125, 150, 175, 200.....
I think I am missing out the relation hiding between these numbers. It will be very helpful if one could provide the relevant resources.