summaryrefslogtreecommitdiff
path: root/apps/plugin.c
diff options
context:
space:
mode:
authorJens Arnold <amiconn@rockbox.org>2008-03-24 00:35:53 +0000
committerJens Arnold <amiconn@rockbox.org>2008-03-24 00:35:53 +0000
commit68a21689aef3a81335456476d4d10860ef5bc6b3 (patch)
treea57b6c31e4edd13e178da276344d33b172796456 /apps/plugin.c
parent99c0978faa94b0e2fabe5d06000a10c8d48e7a0c (diff)
downloadrockbox-68a21689aef3a81335456476d4d10860ef5bc6b3.tar.gz
rockbox-68a21689aef3a81335456476d4d10860ef5bc6b3.zip
Consistent naming scheme the various blit functions. * Removed lcd_blit_mono() for colour targets. Plugin API became incompatible, so sort, clean up & bump. * Implemented lcd_blit_mono() for M3.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16775 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugin.c')
-rw-r--r--apps/plugin.c130
1 files changed, 58 insertions, 72 deletions
diff --git a/apps/plugin.c b/apps/plugin.c
index 6862ddb08e..15a7e9127f 100644
--- a/apps/plugin.c
+++ b/apps/plugin.c
@@ -74,6 +74,7 @@ static const struct plugin_api rockbox_api = {
74 /* lcd */ 74 /* lcd */
75 lcd_set_contrast, 75 lcd_set_contrast,
76 lcd_update, 76 lcd_update,
77 lcd_update_rect,
77 lcd_clear_display, 78 lcd_clear_display,
78 lcd_setmargins, 79 lcd_setmargins,
79 lcd_getstringsize, 80 lcd_getstringsize,
@@ -91,6 +92,7 @@ static const struct plugin_api rockbox_api = {
91 lcd_icon, 92 lcd_icon,
92 lcd_double_height, 93 lcd_double_height,
93#else 94#else
95 &lcd_framebuffer[0][0],
94 lcd_set_drawmode, 96 lcd_set_drawmode,
95 lcd_get_drawmode, 97 lcd_get_drawmode,
96 lcd_setfont, 98 lcd_setfont,
@@ -115,21 +117,27 @@ static const struct plugin_api rockbox_api = {
115#if LCD_DEPTH == 16 117#if LCD_DEPTH == 16
116 lcd_bitmap_transparent_part, 118 lcd_bitmap_transparent_part,
117 lcd_bitmap_transparent, 119 lcd_bitmap_transparent,
120 lcd_blit_yuv,
121#if defined(TOSHIBA_GIGABEAT_F) || defined(SANSA_E200) || defined(SANSA_C200) \
122 || defined (IRIVER_H10)
123 lcd_yuv_set_options,
118#endif 124#endif
125#elif (LCD_DEPTH < 4) || !defined(SIMULATOR)
126 lcd_blit_mono,
127 lcd_blit_grey_phase,
128#endif /* LCD_DEPTH */
129 lcd_puts_style,
130 lcd_puts_scroll_style,
119 bidi_l2v, 131 bidi_l2v,
120 font_get_bits, 132 font_get_bits,
121 font_load, 133 font_load,
122 lcd_puts_style,
123 lcd_puts_scroll_style,
124 &lcd_framebuffer[0][0],
125 lcd_blit,
126 lcd_update_rect,
127 gui_scrollbar_draw,
128 font_get, 134 font_get,
129 font_getstringsize, 135 font_getstringsize,
130 font_get_width, 136 font_get_width,
131 screen_clear_area, 137 screen_clear_area,
138 gui_scrollbar_draw,
132#endif 139#endif
140
133 backlight_on, 141 backlight_on,
134 backlight_off, 142 backlight_off,
135 backlight_set_timeout, 143 backlight_set_timeout,
@@ -137,6 +145,7 @@ static const struct plugin_api rockbox_api = {
137 backlight_set_timeout_plugged, 145 backlight_set_timeout_plugged,
138#endif 146#endif
139 gui_syncsplash, 147 gui_syncsplash,
148
140#ifdef HAVE_REMOTE_LCD 149#ifdef HAVE_REMOTE_LCD
141 /* remote lcd */ 150 /* remote lcd */
142 lcd_remote_set_contrast, 151 lcd_remote_set_contrast,
@@ -166,7 +175,11 @@ static const struct plugin_api rockbox_api = {
166 175
167 remote_backlight_on, 176 remote_backlight_on,
168 remote_backlight_off, 177 remote_backlight_off,
178 remote_backlight_set_timeout,
179#if CONFIG_CHARGING
180 remote_backlight_set_timeout_plugged,
169#endif 181#endif
182#endif /* HAVE_REMOTE_LCD */
170#if NB_SCREENS == 2 183#if NB_SCREENS == 2
171 {&screens[SCREEN_MAIN], &screens[SCREEN_REMOTE]}, 184 {&screens[SCREEN_MAIN], &screens[SCREEN_REMOTE]},
172#else 185#else
@@ -181,16 +194,6 @@ static const struct plugin_api rockbox_api = {
181 lcd_remote_bitmap, 194 lcd_remote_bitmap,
182#endif 195#endif
183 196
184#if defined(HAVE_LCD_BITMAP) && (LCD_DEPTH < 4) && !defined(SIMULATOR)
185 lcd_grey_phase_blit,
186#endif
187#if defined(HAVE_LCD_COLOR)
188 lcd_yuv_blit,
189#endif
190#if defined(TOSHIBA_GIGABEAT_F) || defined(SANSA_E200) || defined(SANSA_C200) \
191 || defined (IRIVER_H10)
192 lcd_yuv_set_options,
193#endif
194 /* list */ 197 /* list */
195 gui_synclist_init, 198 gui_synclist_init,
196 gui_synclist_set_nb_items, 199 gui_synclist_set_nb_items,
@@ -233,9 +236,11 @@ static const struct plugin_api rockbox_api = {
233 ata_sleep, 236 ata_sleep,
234 ata_disk_is_active, 237 ata_disk_is_active,
235#endif 238#endif
239 ata_spin,
236 ata_spindown, 240 ata_spindown,
237 reload_directory, 241 reload_directory,
238 create_numbered_filename, 242 create_numbered_filename,
243 file_exists,
239 244
240 /* dir */ 245 /* dir */
241 opendir, 246 opendir,
@@ -243,6 +248,7 @@ static const struct plugin_api rockbox_api = {
243 readdir, 248 readdir,
244 mkdir, 249 mkdir,
245 rmdir, 250 rmdir,
251 dir_exists,
246 252
247 /* kernel/ system */ 253 /* kernel/ system */
248 PREFIX(sleep), 254 PREFIX(sleep),
@@ -256,6 +262,14 @@ static const struct plugin_api rockbox_api = {
256 threads, 262 threads,
257 create_thread, 263 create_thread,
258 remove_thread, 264 remove_thread,
265 thread_wait,
266#if (CONFIG_CODEC == SWCODEC)
267 mutex_init,
268 mutex_lock,
269 mutex_unlock,
270 align_buffer,
271#endif
272
259 reset_poweroff_timer, 273 reset_poweroff_timer,
260#ifndef SIMULATOR 274#ifndef SIMULATOR
261 system_memory_guard, 275 system_memory_guard,
@@ -267,7 +281,15 @@ static const struct plugin_api rockbox_api = {
267#else 281#else
268 cpu_boost, 282 cpu_boost,
269#endif 283#endif
284#endif /* HAVE_ADJUSTABLE_CPU_FREQ */
285#endif /* !SIMULATOR */
286#ifdef HAVE_SCHEDULER_BOOSTCTRL
287 trigger_cpu_boost,
288 cancel_cpu_boost,
270#endif 289#endif
290#ifdef CACHE_FUNCTIONS_AS_CALL
291 flush_icache,
292 invalidate_icache,
271#endif 293#endif
272 timer_register, 294 timer_register,
273 timer_unregister, 295 timer_unregister,
@@ -277,6 +299,13 @@ static const struct plugin_api rockbox_api = {
277 queue_delete, 299 queue_delete,
278 queue_post, 300 queue_post,
279 queue_wait_w_tmo, 301 queue_wait_w_tmo,
302#if CONFIG_CODEC == SWCODEC
303 queue_enable_queue_send,
304 queue_empty,
305 queue_wait,
306 queue_send,
307 queue_reply,
308#endif
280 usb_acknowledge, 309 usb_acknowledge,
281#ifdef RB_PROFILE 310#ifdef RB_PROFILE
282 profile_thread, 311 profile_thread,
@@ -325,13 +354,12 @@ static const struct plugin_api rockbox_api = {
325 utf8seek, 354 utf8seek,
326 355
327 /* sound */ 356 /* sound */
328#if CONFIG_CODEC == SWCODEC
329 sound_default,
330#endif
331 sound_set, 357 sound_set,
332 358 sound_default,
333 sound_min, 359 sound_min,
334 sound_max, 360 sound_max,
361 sound_unit,
362 sound_val2phys,
335#ifndef SIMULATOR 363#ifndef SIMULATOR
336 mp3_play_data, 364 mp3_play_data,
337 mp3_play_pause, 365 mp3_play_pause,
@@ -353,6 +381,8 @@ static const struct plugin_api rockbox_api = {
353 pcm_play_pause, 381 pcm_play_pause,
354 pcm_get_bytes_waiting, 382 pcm_get_bytes_waiting,
355 pcm_calculate_peaks, 383 pcm_calculate_peaks,
384 pcm_play_lock,
385 pcm_play_unlock,
356#ifdef HAVE_RECORDING 386#ifdef HAVE_RECORDING
357 &rec_freq_sampr[0], 387 &rec_freq_sampr[0],
358 pcm_init_recording, 388 pcm_init_recording,
@@ -367,6 +397,11 @@ static const struct plugin_api rockbox_api = {
367 audio_set_output_source, 397 audio_set_output_source,
368 audio_set_input_source, 398 audio_set_input_source,
369#endif 399#endif
400 dsp_set_crossfeed,
401 dsp_set_eq,
402 dsp_dither_enable,
403 dsp_configure,
404 dsp_process,
370#endif /* CONFIG_CODEC == SWCODEC */ 405#endif /* CONFIG_CODEC == SWCODEC */
371 406
372 /* playback control */ 407 /* playback control */
@@ -508,35 +543,6 @@ static const struct plugin_api rockbox_api = {
508 detect_flashed_romimage, 543 detect_flashed_romimage,
509#endif 544#endif
510 led, 545 led,
511#ifdef CACHE_FUNCTIONS_AS_CALL
512 flush_icache,
513 invalidate_icache,
514#endif
515 /* new stuff at the end, sort into place next time
516 the API gets incompatible */
517
518#if (CONFIG_CODEC == SWCODEC)
519 mutex_init,
520 mutex_lock,
521 mutex_unlock,
522#endif
523
524 thread_wait,
525
526#if (CONFIG_CODEC == SWCODEC)
527 align_buffer,
528#endif
529
530 file_exists,
531 dir_exists,
532
533#ifdef HAVE_REMOTE_LCD
534 remote_backlight_set_timeout,
535#if CONFIG_CHARGING
536 remote_backlight_set_timeout_plugged,
537#endif
538#endif /* HAVE_REMOTE_LCD */
539
540#if (CONFIG_CODEC == SWCODEC) 546#if (CONFIG_CODEC == SWCODEC)
541 bufopen, 547 bufopen,
542 bufalloc, 548 bufalloc,
@@ -569,29 +575,9 @@ static const struct plugin_api rockbox_api = {
569 search_albumart_files, 575 search_albumart_files,
570#endif 576#endif
571 577
572#if CONFIG_CODEC == SWCODEC 578 /* new stuff at the end, sort into place next time
573 pcm_play_lock, 579 the API gets incompatible */
574 pcm_play_unlock, 580
575 queue_enable_queue_send,
576 queue_empty,
577 queue_wait,
578 queue_send,
579 queue_reply,
580#ifndef HAVE_FLASH_STORAGE
581 ata_spin,
582#endif
583#ifdef HAVE_SCHEDULER_BOOSTCTRL
584 trigger_cpu_boost,
585 cancel_cpu_boost,
586#endif
587 sound_unit,
588 sound_val2phys,
589 dsp_set_crossfeed,
590 dsp_set_eq,
591 dsp_dither_enable,
592 dsp_configure,
593 dsp_process,
594#endif /* CONFIG_CODEC == SWCODEC */
595}; 581};
596 582
597int plugin_load(const char* plugin, void* parameter) 583int plugin_load(const char* plugin, void* parameter)