Commit graph

89 commits

Author SHA1 Message Date
Christian Soffke
36cef88d47 PictureFlow: id3 functions refactoring
- Move multiple-id3 functionality into lib
- Extract retrieve_id3 function

In preparation for using these functions
from the Properties plugin.

Change-Id: I7252581340680e32df763f1f4b41646a055fe19e
2023-01-19 15:12:57 -05:00
William Wilgus
a7703e4926 gui lists add callback for owner drawn items
allow the guts of gui_sync_list to be used with owner drawn items

WIP

printcell_helper--

goal: allow data to be displayed in a spreadsheet format  with an easy to use interface

printcell_set_columns(gui_synclist, title, icon)
 sets title and calculates cell widths
 each column is identified by '$' character
 ex 3 columns title = "Col1$Col2$Col3"
also accepts $*WIDTH$
 ex 3 columns varying width title = "$*64$Col1$*128$Col2$Col3
printcell_enable(gui_synclist, enable)
 sets the printcell function enabled

After setting the columns and enabling the printcell function
 items can be added to the list like normal
 column items are supplied delimited by '$'
 ex item = "Item1$item2$item3"
 they will be placed in cells defined by set_columns and scroll if the cell is too small

--Fixed for 1 bit & 2 bit displays

Change-Id: I49bd7903005d7a54e93af4379b0cdea63c860656
2022-01-01 23:56:51 -05:00
William Wilgus
b39acee3ab rb_info plugin and button,action+context name helper
rb_info is just a test plugin

just some info from the running rockbox install

the real star here is the generator scripts to make actions_helper.c and button_helper.c

Change-Id: I23f7bbdae3f2cffca2490c4df40bb13b0b5d5064
2021-11-22 21:39:45 -05:00
William Wilgus
965572705b plugin lib/arg_helper parse 'command line' args
add a helper function to allow plugins to parse the parameter string
passed into plugins
support included for bool, char, string and numbers+decimals

Change-Id: I39f35c8bd3c21b83097a538c19f46d362c468fa4
2021-08-27 05:19:28 +00:00
William Wilgus
b56372bbcb Plugin Api add core bitmaps
share all the core icons with plugins
these are all small mono icons like usb plug icon or
play, fast forward, rewind icons

--include the icon_helper function

Change-Id: I385028815a4dd368515f491a9e19dee3d500252d
2021-08-26 12:55:34 +00:00
Solomon Peachy
278522f811 plugins: Enable overlay features for all targets
Change-Id: I8dfbdf903c1fb82541382709a50e411f1bcdaa5d
2020-10-09 13:30:05 +00:00
Solomon Peachy
658026e626 [4/4] Remove HAVE_LCD_BITMAP, as it's now the only choice.
Note:  I left behind lcd_bitmap in features.txt, because removing it
would require considerable work in the manual and the translations.

Change-Id: Ia8ca7761f610d9332a0d22a7d189775fb15ec88a
2020-07-24 21:20:13 +00:00
Solomon Peachy
0c4f89370d [2/4] get rid of HAVE_LCD_CHARCELLS
HAVE_LCD_BITMAP is now redundant.

lcd_bitmap is always-on in features.txt so manual and lang strings
don't have to change

Change-Id: I08eeb20de48099ffc2dc23782711af368c2ec794
2020-07-24 21:20:13 +00:00
Solomon Peachy
092c340a20 [1/4] Remove SH support and all archos targets
This removes all code specific to SH targets

Change-Id: I7980523785d2596e65c06430f4638eec74a06061
2020-07-24 21:20:13 +00:00
William Wilgus
cb94b3ae2e keyboard add ability to specify temporary custom layouts
rb core allows you to load custom keyboard layouts

this patch adds the ability to load a keyboard layout in a buffer
the custom layout is temporary and does not overwrite the current layout

use like so:

    unsigned short kbd[64];
    unsigned short *kbd_p = kbd;
    if (!kbd_create_layout("ABCD1234\n", kbd, sizeof(kbd)))
        kbd_p = NULL;

    rb->kbd_input(buf,sizeof(buf), kbd_p);

Change-Id: I7be2bd4a1b4797a147fa70228a9749dc56ac052a
2020-07-22 06:48:28 -04:00
Marcin Bukat
a8423321b8 stdio compat layer for plugins
This is attempt to simplify porting programs to rockbox (as plugins).
Currently this compat layer implements:
fopen(), fclose(), fflush(), fread(), fwrite(), fseek(), fseeko(),
ftell(), ftello(), fgetc(), ungetc(), fputc(), fgets(), clearerr(),
ferror(), feof(), fprintf()

In order to use it you need to include in ported sources
"lib/stdio_compat.h"

Change-Id: I5add615dd19c5af9c767ccbfb1bd5a4e466741cb
2017-12-23 20:54:56 -05:00
Franklin Wei
30d7ead6af One-Time Password client (HOTP and TOTP)
* Implements RFC 4226 (HOTP) and RFC 6238 (TOTP)

* Adds sha1.c to apps/plugins/lib (orignally tools/hmac-sha1.c)

* See manual entry for more information

Change-Id: Ia4a4031b29f97361b541e71438aa7f3ea82212f2
2016-06-05 14:25:09 -04:00
Michael Sevakis
95e23defb0 Make fixepoint.c as a shared library (libfixedpoint.a).
Change-Id: Icc10d6e85f890c432f191233a4d64e09f00be43d
Reviewed-on: http://gerrit.rockbox.org/456
Reviewed-by: Michael Sevakis <jethead71@rockbox.org>
Tested-by: Michael Sevakis <jethead71@rockbox.org>
2013-04-26 00:11:04 +02:00
Michael Sevakis
0f8aedbe94 Add a true waveform display to the oscilloscope plugin.
* Adds some additional niftyness like a floating popup display that
is implemented in an OSD library for use by other plugins.

* Speed changes are now gradual for both views and follow a curve
derived from some fiddling around to get a nice feel.

* Refined a few behavioral things overall.

It needs a bit of help from a direct PCM channel callback so it may
capture PCM for waveform display. Also need a few other core routines
to help out for the OSD.

Messes with some keymaps. Some targets need keymaps to access the
different views. Some devices can't support the additional view
because it requires a large buffer ( > 1 s) for samples.

If the plugin buffer is small, they can still use the popup display
since the plugin is also much smaller in that case.

Slow speed waveform needs some refining so it draws gradually like
a real oscilloscope but I'll stick with what it is, for the moment.

Change-Id: Ieb5b7922a2238264e9b19a58cb437739194eb036
Reviewed-on: http://gerrit.rockbox.org/245
Reviewed-by: Michael Sevakis <jethead71@rockbox.org>
Tested-by: Michael Sevakis <jethead71@rockbox.org>
2012-12-05 02:03:58 +01:00
Thomas Martitz
cf333a61c7 Move supprt-arm.S to separate library.
Core, codecs and plugins link it separately so this gets rid of SOURCES trickery.
Don't build it for hosted targets.

Change-Id: If15ef90e93cd218a4352ae8e89eea95d3122452f
2012-01-21 18:39:19 +01:00
Thomas Martitz
42f10e04df Remove buflib from the pluginlib and use the core one.
buflib_get_data() isn't inlined for plugins anymore, but can be if really needed.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30387 a1c6a512-1295-4272-9138-f99709370657
2011-08-30 16:48:36 +00:00
Thomas Martitz
cae4ae2c71 Second try: Introduce plugin_crt0.c that every plugin links.
It handles exit() properly, calling the handler also when the plugin returns
normally (also make exit() more standard compliant while at it).
It also holds PLUGIN_HEADER, so that it doesn't need to be in each plugin anymore.

To work better together with callbacks passed to rb->default_event_handler_ex() introduce exit_on_usb() which will call the exit handler before showing the usb screen and exit() after it.
In most cases rb->default_event_handler_ex() was passed a callback which was manually called at all other return points. This can now be done via atexit().

In future plugin_crt0.c could also handle clearing bss, initializing iram and more.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27873 a1c6a512-1295-4272-9138-f99709370657
2010-08-24 14:30:46 +00:00
Thomas Martitz
46454ac2a8 Move setjmp to lib and add setjmp for sh (imported from newlib) and compile it as separate library.
It's used by both, plugins and codecs, and sh/hwcodec doesn't compile codecs
so it doesn't fit into sources.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27869 a1c6a512-1295-4272-9138-f99709370657
2010-08-24 12:38:42 +00:00
Thomas Martitz
93cb949372 Revert "Introduce plugin_crt0.c that every plugin links."
Too much errors and no time to fix them now.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27863 a1c6a512-1295-4272-9138-f99709370657
2010-08-23 17:12:26 +00:00
Thomas Martitz
abdc5935be Introduce plugin_crt0.c that every plugin links.
It handles exit() properly, calling the handler also when the plugin returns
normally (also it makes exit() more standard compliant while at it).
It also holds PLUGIN_HEADER, so that it doesn't need to be in each plugin anymore.

To work better together with callbacks passed to rb->default_event_handler_ex introduce exit_on_usb() which will call the exit handler before showing the usb screen and exit() after it.
In most cases it was passed a callback which was manually called at all other return points. This can now be done via atexit().

In future plugin_crt0.c could also handle clearing bss, initializing iram and more.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27862 a1c6a512-1295-4272-9138-f99709370657
2010-08-23 16:56:49 +00:00
Thomas Martitz
35e8b1429a Rockbox as an application: Replace many occurences of #ifdef SIMULATOR with #if (CONFIG_PLATFORM & PLATFORM_HOSTED) (or equivalently).
The simulator defines PLATFORM_HOSTED, as RaaA will do (RaaA will not define SIMULATOR).
The new define is to (de-)select code to compile on hosted platforms generally.

Should be no functional change to targets or the simulator.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27019 a1c6a512-1295-4272-9138-f99709370657
2010-06-21 16:53:00 +00:00
Teruaki Kawashima
926aae8161 reorder apps/plugins/lib/SOURCES.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26919 a1c6a512-1295-4272-9138-f99709370657
2010-06-18 13:49:36 +00:00
Teruaki Kawashima
0c7eb41da8 add simple text viewer to pluginlib and use this for dict to show description.
now dict can scroll the description. it might not show full description if it is too long or memory is not enough.


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26687 a1c6a512-1295-4272-9138-f99709370657
2010-06-08 11:07:36 +00:00
Rafaël Carré
6e15b710c0 apps/plugins/lib/SOURCES: make it more readable (space, comments, order)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26143 a1c6a512-1295-4272-9138-f99709370657
2010-05-18 14:14:48 +00:00
Andrew Mahone
bff5a35c3c FS#10943, optimized division and clz routines to replace libgcc routines for ARM. Replaces libgcc support functions for unsigned and signed 32-bit division on ARMv4 and up, and leading-zero count on ARMv4.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24432 a1c6a512-1295-4272-9138-f99709370657
2010-02-01 01:36:46 +00:00
Karl Kurbjun
0131a3873e Pluginlib: Add support for general buttons. Add menu and quit buttons to Reversi. MRobe 500: Modify touch handler to return the previous data always rather than 0 when there is no touch.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22110 a1c6a512-1295-4272-9138-f99709370657
2009-08-02 07:05:30 +00:00
Nils Wallménius
3d4701a6e4 FS#10080
* Move strncpy() from core to the pluginlib
* Introduce strlcpy() and use that instead in most places (use memcpy in a few) in core and some plugins
* Drop strncpy() from the codec api as no codec used it
* Bump codec and plugin api versions


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21863 a1c6a512-1295-4272-9138-f99709370657
2009-07-14 13:57:45 +00:00
Maurus Cuelenaere
c3bc8fda80 Revert "Consolidate all fixed point math routines in one library (FS#10400) by Jeffrey Goode"
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21635 a1c6a512-1295-4272-9138-f99709370657
2009-07-04 13:17:58 +00:00
Maurus Cuelenaere
4710a32800 Consolidate all fixed point math routines in one library (FS#10400) by Jeffrey Goode
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21633 a1c6a512-1295-4272-9138-f99709370657
2009-07-04 12:26:45 +00:00
Johannes Schwarz
8a21372e5b FS#10099: new lib, which displays formatted text on every target; also supports viewport
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21537 a1c6a512-1295-4272-9138-f99709370657
2009-06-28 09:48:12 +00:00
Andrew Mahone
6a0d931f38 Core JPEG decoder improvements:
For >8-point vertical IDCT, transpose the coefficients while decoding them, so that the vertical IDCT can read in rows rather than columns. This improves speed a bit for this size even using the C IDCT.
Remove inline ARM asm, replacing it with an external file containing pure asm IDCT functions.
Add jpeg_ prefix to JPEG IDCT functions since some of them will now be visible globally.


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21345 a1c6a512-1295-4272-9138-f99709370657
2009-06-19 02:56:00 +00:00
Jonathan Gordon
af9f405651 Accept FS#10094 by Teruaki Kawashima:
Replace the old menu API with the "new" one (a very long time overdue so huge thanks for the work.)


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21306 a1c6a512-1295-4272-9138-f99709370657
2009-06-16 04:25:21 +00:00
Andrew Mahone
e0f4eafb68 Add Bob Jenkins' lookup3 32-bit and 64-bit hashes to pluginlib.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21155 a1c6a512-1295-4272-9138-f99709370657
2009-06-01 13:40:30 +00:00
Andrew Mahone
a75c72c169 Plugin JPEG decoder for data in memory, along with test_mem_jpeg.c and bench_mem_jpeg.c plugins to test and benchmark it, and a line-length clean up in jpeg_load.c.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20871 a1c6a512-1295-4272-9138-f99709370657
2009-05-08 03:46:48 +00:00
Andrew Mahone
16908adafe Fix red on Player
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20852 a1c6a512-1295-4272-9138-f99709370657
2009-05-04 16:02:21 +00:00
Andrew Mahone
20f76d61ae Make JPEG and BMP scaler optional with HAVE_JPEG and HAVE_BMP_SCALING, both defined for all targets that have HAVE_ALBUMART. Disable JPEG in PictureFlow and pluginlib album art search with 32KiB plugin buffer until PictureFlow
gets overlay support.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20851 a1c6a512-1295-4272-9138-f99709370657
2009-05-04 15:46:41 +00:00
Andrew Mahone
3d4c68bb06 Add read_<image>_fd functions to plugin API, add feature_wrappers.h handling for them, and add read_image.[ch] wrapper for reading image files with automatic type detection.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20840 a1c6a512-1295-4272-9138-f99709370657
2009-05-02 03:47:46 +00:00
Andrew Mahone
75f2629778 Add read_jpeg_* to feature_wrappers.h, add import-from-core for jpeg_load.c on mono targets.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20839 a1c6a512-1295-4272-9138-f99709370657
2009-05-02 02:39:13 +00:00
Maurus Cuelenaere
9f73a01619 Add exit() implementation for plugins
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20775 a1c6a512-1295-4272-9138-f99709370657
2009-04-22 14:31:23 +00:00
Andrew Mahone
b727de604d FS#9916 buflib plugin memory allocator
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20202 a1c6a512-1295-4272-9138-f99709370657
2009-03-04 21:11:12 +00:00
Andrew Mahone
499426caf9 remove MEM_FUNCTION_WRAPPERS, and private mem* implementations from plugins, and replace with pluginlib implementations in plugins/lib/gcc-support.c
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19847 a1c6a512-1295-4272-9138-f99709370657
2009-01-24 22:57:57 +00:00
Andrew Mahone
9b0b6584f8 fix yellow - don't build pluginlib_albumart.c on non-bitmap targets
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19840 a1c6a512-1295-4272-9138-f99709370657
2009-01-24 09:53:18 +00:00
Andrew Mahone
7215a67e64 albumart search in pluginlib when building without HAVE_ALBUMART (for later use by pictureflow)
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19835 a1c6a512-1295-4272-9138-f99709370657
2009-01-24 04:09:29 +00:00
Michael Sevakis
b0befadad1 Include divide-by-zero handling within plugins and codecs for ARM processors.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19834 a1c6a512-1295-4272-9138-f99709370657
2009-01-24 03:47:09 +00:00
Björn Stenberg
52320b83c0 Added missing dependencies for codeclib and pluginlib. This required renaming some files that have twins in other places.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19756 a1c6a512-1295-4272-9138-f99709370657
2009-01-12 21:56:46 +00:00
Andrew Mahone
32d9752dcc remove unneeded LCD_DEPTH test in lib/resize.h, add some comments explaining the core-file imports
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19715 a1c6a512-1295-4272-9138-f99709370657
2009-01-08 08:32:05 +00:00
Andrew Mahone
07e982df8a cleanup for core-file-in-pluginlib compilation:
wrapper C files in pluginlib renamed to the same name as the core files they
wrap

pluginlib-only init functions for resize and bmp moved into the wrapper files,
and declared in the associated header files

API() macro removed entirely, in favor of a core-only header file that
redefines core function names to use a plugin_api pointer

some unnecessary uses of PLUGIN in apps/recorder/bmp.c removed


git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19712 a1c6a512-1295-4272-9138-f99709370657
2009-01-08 02:49:23 +00:00
Andrew Mahone
4eedc93357 build a scaling-enabled bitmap loader in pluginlib for mono bitmap targets, and use it in the test greylib scaler plugin
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19671 a1c6a512-1295-4272-9138-f99709370657
2009-01-04 21:22:05 +00:00
Maurus Cuelenaere
1392dc2144 Commit FS#9308: differentiate between TOUCHPAD & TOUCHSCREEN
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@18338 a1c6a512-1295-4272-9138-f99709370657
2008-08-23 09:46:38 +00:00
Antoine Cellerier
34d4165f7b New md5sum plugin. Open a file, a directory or just launch it from the plugin menu to create an md5sum of the file, the directory's contents or the whole filesystem. If the file's extension is .md5 or .md5sum, it will check the md5 sums in the file instead. If the file's extension is .md5list it will compute md5 sums for all the files listed.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@17709 a1c6a512-1295-4272-9138-f99709370657
2008-06-10 13:20:05 +00:00