diff options
author | Jens Arnold <amiconn@rockbox.org> | 2005-02-11 22:54:17 +0000 |
---|---|---|
committer | Jens Arnold <amiconn@rockbox.org> | 2005-02-11 22:54:17 +0000 |
commit | af56130a4ac0a046caff495a7ee570e914e4450b (patch) | |
tree | 566a4ec749b56dbfdb3579b4939ac405e527c749 /apps | |
parent | b90594c36bc7f4fa2fdd8121d8c42feb3c58609f (diff) | |
download | rockbox-af56130a4ac0a046caff495a7ee570e914e4450b.tar.gz rockbox-af56130a4ac0a046caff495a7ee570e914e4450b.zip |
Simulators: handle plugins asking for the mp3 buffer the same way as on the target (no separate buffer).
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@5920 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps')
-rw-r--r-- | apps/plugin.c | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/apps/plugin.c b/apps/plugin.c index f7458b71b2..7b26b0dd57 100644 --- a/apps/plugin.c +++ b/apps/plugin.c | |||
@@ -415,21 +415,15 @@ void* plugin_get_buffer(int* buffer_size) | |||
415 | Playback gets stopped, to avoid conflicts. */ | 415 | Playback gets stopped, to avoid conflicts. */ |
416 | void* plugin_get_mp3_buffer(int* buffer_size) | 416 | void* plugin_get_mp3_buffer(int* buffer_size) |
417 | { | 417 | { |
418 | #ifdef SIMULATOR | ||
419 | static unsigned char buf[1700*1024]; | ||
420 | *buffer_size = sizeof(buf); | ||
421 | return buf; | ||
422 | #else | ||
423 | mpeg_stop(); | 418 | mpeg_stop(); |
424 | talk_buffer_steal(); /* we use the mp3 buffer, need to tell */ | 419 | talk_buffer_steal(); /* we use the mp3 buffer, need to tell */ |
425 | *buffer_size = mp3end - mp3buf; | 420 | *buffer_size = mp3end - mp3buf; |
426 | return mp3buf; | 421 | return mp3buf; |
427 | #endif | ||
428 | } | 422 | } |
429 | 423 | ||
430 | #ifndef SIMULATOR | 424 | #ifndef SIMULATOR |
431 | /* Register a periodic time callback, called every "cycles" CPU clocks. | 425 | /* Register a periodic time callback, called every "cycles" CPU clocks. |
432 | Note that this function will be called in interrupt context! */ | 426 | Note that this function will be called in interrupt context! */ |
433 | int plugin_register_timer(int cycles, int prio, void (*timer_callback)(void)) | 427 | int plugin_register_timer(int cycles, int prio, void (*timer_callback)(void)) |
434 | { | 428 | { |
435 | int phi = 0; /* bits for the prescaler */ | 429 | int phi = 0; /* bits for the prescaler */ |