[英]How to get the width and the height in glium?
我在 Rust 中使用了 Glium。 我想得到寬度和高度。
我不能很好地書寫和理解英語,因為我是日本人。 也許我的英語有問題,所以我很抱歉。
正如我在評論部分提到的,有一個Display::get_framebuffer_dimensions
,所以如果你有glium::Display
對象,你可以使用它提取 OpenGL 上下文的尺寸。
pub fn get_framebuffer_dimensions(&self) -> (u32, u32)
在此上下文存儲的后端對象上調用
get_framebuffer_dimensions
。
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.