From 4c71f16e8e75b53abeca0c0e8fc6f94ed6162ce7 Mon Sep 17 00:00:00 2001 From: rasher Date: Mon, 16 May 2005 12:07:30 +0000 Subject: [PATCH] Remote support on iRiver git-svn-id: svn://svn.rockbox.org/rockbox/trunk@6477 a1c6a512-1295-4272-9138-f99709370657 --- apps/plugins/logo.c | 52 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 52 insertions(+) diff --git a/apps/plugins/logo.c b/apps/plugins/logo.c index 753b28bf1..080da6a4e 100644 --- a/apps/plugins/logo.c +++ b/apps/plugins/logo.c @@ -24,6 +24,48 @@ #define DISPLAY_HEIGHT LCD_HEIGHT #define RAND_SCALE 5 +#ifdef IRIVER_H100 +#define REMOTE_WIDTH 134 +#define REMOTE_HEIGHT 65 +#define REMOTE_LOGO_WIDTH 91 +#define REMOTE_LOGO_HEIGHT 32 +#define REMOTE_LOGO rockbox91x32 +/* Smaller logo for the remote */ +const unsigned char rockbox91x32[] = { + 0x00, 0x02, 0x7f, 0x02, 0xfa, 0xfa, 0xfa, 0xfa, 0xfa, 0xfa, 0xf8, 0xf8, 0xf0, + 0xe0, 0x80, 0x00, 0x00, 0x80, 0xe0, 0xf0, 0xf0, 0xf8, 0xfa, 0xfa, 0xf4, 0xf4, + 0xe8, 0x90, 0x60, 0x80, 0x60, 0x90, 0xe8, 0xf4, 0xf4, 0xfa, 0xfa, 0xfa, 0xfa, + 0xf4, 0xe8, 0x04, 0xf4, 0xf4, 0xf4, 0x04, 0xfe, 0x04, 0xc0, 0xf0, 0xf4, 0xf4, + 0x34, 0x1e, 0x04, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, + + 0x70, 0x88, 0xf0, 0x00, 0xff, 0xff, 0xff, 0xff, 0x02, 0xc2, 0x3c, 0xc3, 0xff, + 0xff, 0xff, 0x00, 0xfe, 0xff, 0xff, 0x07, 0x01, 0x00, 0xfe, 0x02, 0xfd, 0x07, + 0xff, 0xff, 0xfe, 0x01, 0xfe, 0xff, 0xff, 0x0f, 0x01, 0x00, 0x80, 0x00, 0x01, + 0x03, 0x0f, 0x00, 0xff, 0xff, 0xff, 0xc0, 0xf9, 0xfe, 0xff, 0xff, 0x07, 0x04, + 0x04, 0x04, 0xfc, 0x80, 0x40, 0x40, 0x40, 0x40, 0x40, 0x80, 0x00, 0x00, 0x00, + 0x00, 0x00, 0x80, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0x40, 0xc0, 0x40, 0x40, + 0x40, 0x40, 0x80, 0x00, 0x80, 0x40, 0x80, 0x40, 0x40, 0x40, 0x40, 0xc0, 0x00, + + 0x00, 0x7c, 0xc3, 0x9e, 0x67, 0x37, 0x8f, 0xff, 0x1f, 0xff, 0xff, 0xff, 0xff, + 0xe3, 0x80, 0x00, 0xff, 0xff, 0xff, 0xc0, 0x00, 0x01, 0x03, 0xc1, 0x3f, 0xc1, + 0xff, 0xff, 0xff, 0x01, 0xff, 0xff, 0xff, 0xc1, 0x01, 0x01, 0xff, 0x01, 0x00, + 0x00, 0xc0, 0x00, 0xff, 0xff, 0xff, 0xcf, 0x3f, 0xff, 0xf8, 0xff, 0x00, 0x00, + 0x00, 0x00, 0xe0, 0x10, 0x08, 0x18, 0xe8, 0x10, 0xe0, 0x00, 0x01, 0x02, 0x04, + 0x02, 0x01, 0xe0, 0x10, 0x08, 0x08, 0x18, 0xe8, 0x10, 0xe0, 0x00, 0x01, 0x00, + 0x00, 0xe0, 0x40, 0x01, 0x02, 0x01, 0x40, 0xe0, 0x18, 0xe4, 0x1b, 0x04, 0x03, + + 0x00, 0x00, 0x00, 0x00, 0x77, 0x6e, 0x61, 0x7f, 0x40, 0xff, 0x00, 0x07, 0x1f, + 0x3f, 0x7f, 0x7c, 0x71, 0xcf, 0x5f, 0x3f, 0x7e, 0x7c, 0x7d, 0x7d, 0x7e, 0x3f, + 0x1f, 0x0f, 0x01, 0x00, 0x41, 0x47, 0x5f, 0x7f, 0x7e, 0x7c, 0x7f, 0x7c, 0x7e, + 0x3f, 0x1f, 0x00, 0x7f, 0x7f, 0x7f, 0x01, 0x4e, 0x71, 0xcf, 0x7f, 0x40, 0x40, + 0x40, 0x40, 0x60, 0x21, 0x42, 0x43, 0x42, 0x41, 0x40, 0x20, 0x10, 0x08, 0x04, + 0x08, 0x10, 0x20, 0x41, 0x42, 0x42, 0x43, 0x42, 0x41, 0x40, 0x60, 0x50, 0x40, + 0x40, 0x40, 0x20, 0x50, 0x28, 0x10, 0x20, 0x40, 0x43, 0x44, 0x5b, 0x64, 0x18, +}; +#endif /* IRIVER_H100 */ + #if LCD_WIDTH > 112 #define LOGO_WIDTH 112 #define LOGO_HEIGHT 37 @@ -178,6 +220,13 @@ enum plugin_status plugin_start(struct plugin_api* api, void* parameter) { #ifdef HAVE_LCD_BITMAP rb->lcd_clear_display(); rb->lcd_bitmap(LOGO, x, y, LOGO_WIDTH, LOGO_HEIGHT, false); +#ifdef REMOTE_LOGO + rb->remote_clear_display(); + rb->remote_bitmap(REMOTE_LOGO, + (x * (REMOTE_WIDTH - REMOTE_LOGO_WIDTH)) / (DISPLAY_WIDTH - LOGO_WIDTH), + (y * (REMOTE_HEIGHT - REMOTE_LOGO_HEIGHT)) / (DISPLAY_HEIGHT - LOGO_HEIGHT), + REMOTE_LOGO_WIDTH, REMOTE_LOGO_HEIGHT, false); +#endif #else pgfx_clear_display(); pgfx_bitmap(LOGO, x % 5, y, LOGO_WIDTH, LOGO_HEIGHT, false); @@ -206,6 +255,9 @@ enum plugin_status plugin_start(struct plugin_api* api, void* parameter) { #ifdef HAVE_LCD_BITMAP rb->lcd_update(); +#ifdef REMOTE_LOGO + rb->remote_update(); +#endif #else if (cpos != old_cpos) { rb->lcd_clear_display(); -- 2.11.4.GIT