252 unsigned int screen_width, screen_height;
253 getScreenSize(screen_width, screen_height);
254 double wscale = std::max<double>(1., ceil((2. *
static_cast<double>(width)) /
static_cast<double>(screen_width)));
255 double hscale = std::max<double>(1., ceil((2. *
static_cast<double>(height)) /
static_cast<double>(screen_height)));
256 unsigned int scale = std::max<unsigned int>(1u, std::max<unsigned int>(
static_cast<unsigned int>(wscale),
static_cast<unsigned int>(hscale)));