Important speedup by not redrawing too much

This commit is contained in:
Vladimir 'phcoder' Serbinenko 2009-11-24 07:17:18 +01:00
parent 4545f150f3
commit 947fa16c8b
11 changed files with 221 additions and 73 deletions

View file

@ -67,12 +67,16 @@ image_is_instance (void *vself __attribute__((unused)), const char *type)
}
static void
image_paint (void *vself)
image_paint (void *vself, const grub_video_rect_t *region)
{
grub_gui_image_t self = vself;
grub_video_rect_t vpsave;
if (! self->bitmap)
return;
grub_video_rect_t vpsave;
if (!grub_video_have_common_points (region, &self->bounds))
return;
grub_gui_set_viewport (&self->bounds, &vpsave);
grub_video_blit_bitmap (self->bitmap, GRUB_VIDEO_BLIT_BLEND,
0, 0, 0, 0,