Signed-off-by: Sascha Hauer <s.hauer@xxxxxxxxxxxxxx> --- commands/splash.c | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/commands/splash.c b/commands/splash.c index 90f0a0c..29e30ae 100644 --- a/commands/splash.c +++ b/commands/splash.c @@ -18,6 +18,7 @@ static int do_splash(int argc, char *argv[]) int offscreen = 0; u32 bg_color = 0x00000000; bool do_bg = false; + void *buf; memset(&s, 0, sizeof(s)); @@ -58,15 +59,11 @@ static int do_splash(int argc, char *argv[]) return PTR_ERR(sc); } - if (sc->offscreenbuf) { - if (do_bg) - gu_memset_pixel(sc->info, sc->offscreenbuf, bg_color, - sc->s.width * sc->s.height); - else - memcpy(sc->offscreenbuf, sc->fb, sc->fbsize); - } else if (do_bg) { - gu_memset_pixel(sc->info, sc->fb, bg_color, sc->s.width * sc->s.height); - } + buf = gui_screen_render_buffer(sc); + + if (do_bg) + gu_memset_pixel(sc->info, buf, bg_color, + sc->s.width * sc->s.height); ret = image_renderer_file(sc, &s, image_file); if (ret > 0) -- 2.4.6 _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox