mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-29 04:37:55 +00:00
LibWeb/WebGL: Implement drawingBufferWidth and drawingBufferHeight
This commit is contained in:
committed by
Alexander Kalenik
parent
4dc65c57a0
commit
c199be061a
@@ -171,4 +171,16 @@ JS::Object* WebGLRenderingContext::get_extension(String const&)
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
WebIDL::Long WebGLRenderingContext::drawing_buffer_width() const
|
||||
{
|
||||
auto size = canvas_for_binding()->bitmap_size_for_canvas();
|
||||
return size.width();
|
||||
}
|
||||
|
||||
WebIDL::Long WebGLRenderingContext::drawing_buffer_height() const
|
||||
{
|
||||
auto size = canvas_for_binding()->bitmap_size_for_canvas();
|
||||
return size.height();
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user