/
githubmirror
/
omim
Обзор
Документация
Войти
/
githubmirror
/
omim
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
android-95
drape/visual_scale.hpp
17 строк
546 B
Maxim Pimenov
Got rid of the old style std/ includes for several files, mostly in software_renderer/.
23 сен 2019, 17:03
23 сен 2019, 17:03
cf6549a
Код
Авторство
О чём код?
#pragma once namespace dp { inline double VisualScale(double exactDensityDPI) { double constexpr kMdpiDensityDPI = 160.; double const tabletFactor = 1.2; // In case of tablets and iPads increased DPI is used to make visual scale bigger. if (GetPlatform().IsTablet()) exactDensityDPI *= tabletFactor; // For some old devices (for example iPad 2) the density could be less than 160 DPI. // Returns one in that case to keep readable text on the map. return std::max(1.35, exactDensityDPI / kMdpiDensityDPI); } } // namespace dp