Add window.gldrawablesize
This commit is contained in:
parent
b46b744d71
commit
1a8319b9c0
1 changed files with 7 additions and 0 deletions
|
@ -86,6 +86,13 @@ pub const Window = struct {
|
|||
};
|
||||
return Renderer{ .renderer = renderer };
|
||||
}
|
||||
|
||||
pub fn glDrawableSize(self: Window) struct { w: i32, h: i32 } {
|
||||
var width: c_int = 0;
|
||||
var height: c_int = 0;
|
||||
c.SDL_GL_GetDrawableSize(self.window, &width, &height);
|
||||
return .{ .w = width, .h = height };
|
||||
}
|
||||
};
|
||||
|
||||
pub const RendererFlags = struct {
|
||||
|
|
Loading…
Reference in a new issue