examples: --unnecessary initial buffer clear

This commit is contained in:
Hermet Park 2024-06-24 20:45:28 +09:00 committed by Hermet Park
parent f202137acd
commit 21f82c08db

View file

@ -294,9 +294,6 @@ struct SwWindow : Window
//Set the canvas target and draw on it. //Set the canvas target and draw on it.
verify(canvas->target((uint32_t*)surface->pixels, surface->w, surface->pitch / 4, surface->h, tvg::SwCanvas::ARGB8888)); verify(canvas->target((uint32_t*)surface->pixels, surface->w, surface->pitch / 4, surface->h, tvg::SwCanvas::ARGB8888));
//Clear the canvas target buffer
verify(canvas->clear(false));
} }
void refresh() override void refresh() override
@ -355,9 +352,6 @@ struct GlWindow : Window
{ {
//Set the canvas target and draw on it. //Set the canvas target and draw on it.
verify(canvas->target(0, width, height)); verify(canvas->target(0, width, height));
//Clear the canvas target buffer
verify(canvas->clear(false));
} }
void refresh() override void refresh() override
@ -453,9 +447,6 @@ struct WgWindow : Window
{ {
//Set the canvas target and draw on it. //Set the canvas target and draw on it.
verify(canvas->target(instance, surface, width, height)); verify(canvas->target(instance, surface, width, height));
//Clear the canvas target buffer
verify(canvas->clear(false));
} }
}; };