mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 05:07:35 +00:00
LibAccelGfx+LibWeb: Implement SetClipRect and ClearClipRect commands
This commit is contained in:
parent
9e4d697d23
commit
01d938c77b
5 changed files with 32 additions and 3 deletions
|
@ -417,6 +417,16 @@ void Painter::restore()
|
|||
m_state_stack.take_last();
|
||||
}
|
||||
|
||||
void Painter::set_clip_rect(Gfx::IntRect rect)
|
||||
{
|
||||
GL::enable_scissor_test(rect);
|
||||
}
|
||||
|
||||
void Painter::clear_clip_rect()
|
||||
{
|
||||
GL::disable_scissor_test();
|
||||
}
|
||||
|
||||
void Painter::set_target_bitmap(Gfx::Bitmap& bitmap)
|
||||
{
|
||||
if (m_target_framebuffer.has_value()) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue