Please test on something outside 60hz monitors.
You can add trace(refreshRatesCounts); before estimatedRefreshRate = possibleRefreshRates[index]; line to see how many correct hz matches you get after one second (for me its like 55-59 and 0 for other possible refresh rates).
Another impl option is infinite fps value fixed size array (10-100 items) and move calculation logic to Display.get_frequency call.
Please test on something outside 60hz monitors. You can add
trace(refreshRatesCounts);
beforeestimatedRefreshRate = possibleRefreshRates[index];
line to see how many correct hz matches you get after one second (for me its like 55-59 and 0 for other possible refresh rates). Another impl option is infinite fps value fixed size array (10-100 items) and move calculation logic toDisplay.get_frequency
call.Closes https://github.com/Kode/Kha/issues/1388