winit
winit copied to clipboard
Can't create window larger than screen without calling `set_inner_size` afterwards
I have a FullHD screen. When I try to create a window with size larger than 1920x1080, the window that is opened only has size 1920x1080. Only when I then call set_inner_size, the window can be made larger:
let (width, height) = (1920 * 4, 1080 * 4); // 8K
let event_loop = EventLoop::new();
let context = ContextBuilder::new().with_vsync(true).with_depth_buffer(24);
let builder = WindowBuilder::new()
.with_inner_size(PhysicalSize::new(width, height));
let display = Display::new(builder, context, &event_loop).unwrap();
// This is necessary:
let gl_window = display.gl_window();
gl_window.window().set_inner_size(PhysicalSize::new(width, height));
Ideally it should already create the window with the given size, because clearly it is possible to have such a large window. (Btw, my get_max_viewport_dimensions are (16384, 16384).)
What platform are you on, please include this information.
@kchibisov Windows 8.1. GPU specs / GL driver