- Synchronized with actual state of Vortex version in general.
- Playback resume has been moved to the Power button.
- Option button acts identically in most contexts: main menu on short
press and quickscreen on long press.
- Defined A-B repeat mode control buttons.
- Level change action in chessbox has been moved to the volume down button.
(Patch by Igor Poretsky)
Change-Id: I48046ff123d2bccdc0d0c4ed8b088e2053aefa5e
In newer builds line markers prevent lua helper scripts
from grabbing some inputs especially _bool
This patch adds the -P switch
Inhibit generation of linemarkers in the output from the preprocessor.
This might be useful when running the preprocessor on something that
is not C code, and will be sent to a program which might be confused
by the linemarkers.
Change-Id: I66c3b099729f6651300f9fcf4670533a20cc90c1
This brings the code to upstream commit 3ece3d6 (I've made my own Rockbox-
specific changes on top of that).
Changes include using C99 `bool' throughout, and minor logic fixes for some
puzzles.
Change-Id: Ie823e73ae49a8ee1de411d6d406df2ba835af541
dsoundfile.c used memcpy for overlapping memory regions switched to memmove
Suppress the 160+ warnings for cast-function-type
This plugin would require major work to fix these warnings
Change-Id: I309d914839c1e70126a05b387863fd21613497a9
This is a seemingly random bug that only affects (as far as I can tell)
arm devices it isn't actually random as code changes cause it to
appear/disappear based on alignment
Change-Id: I4cbc4370677959319f8589fe454e854c45623468
When loading a file, Lua may call the reader function again after it
returned end of input
https://www.lua.org/bugs.html#5.1.5-2
Change-Id: Ic2f4d727705a0b8f48ce792f6a9f7af25a503037
pixel-painter was depending on the old readline code that
returned nil for empty lines however empty lines should
have returned an empty string
Change-Id: Ic06ce920a7ab38e1fb8f7197d637e74ed9e35653
added a few more levels and increased difficulty based on level
Rliimage allows us to use circles in boomshine
Optimized some of the code to exceed the speed of the original
Change-Id: I68eb74f8b68fcdc8a9d022cd172374744425f15d
String constants were already expanded in the first macro
pcm functions were looking for stack position #1 when they needed stack pos #2
Change-Id: I7b4fb90953ab2395b77cbd550fdd257fafca6aae
The auto generated utf8/16 encode/decode functions did not work.
Upon implementing them correctly I found that lua handles the utf-8
form properly but I could not get utf-16 to work without crashing
maybe someone can come along later and implement utf-16 safe string
functions but for now utf-16 is removed.
Change-Id: I97a044e200dc27f683a45487cd93fce667c670c4
The way to call the pcm functions has changed
rb.pcm("option", var)
rb.pcm_set_frequency(freq) = becomes rb.pcm("pcmsetfrequency", freq)
added pcm.lua to the includes for conversion to old functions
if your script is broken by this change you simply add
`require("pcm")` to the top for the old functionality
added rb.pcm("calculatepeaks")
Change-Id: I092057b0c0b5575e567862661f122da1ca2680e8
Did not mean to wipe out these function when I consolidated audio
Made the regex for audio_ and playlist_ exact matches instead of fuzzy
Change-Id: I7537d1b494afb114c8b6333ea177b1e482f6b672
Adds %F -- %Y-%m-%d
Fixes possible buffer overflow when writing final \0
Frees a bit of code on NON-RTC targets
Change-Id: I1c2600a68ee88c6c99f411ae6646861578683f90
Rocklua was using the full fscanf implementation
to simply read %ld for the file:read("*n") function
wasting 1k on unneeded/unused functionality
Instead, I've implemented a filetol function to duplicate it
without the extra overhead using strtol which as an added bonus
ERANGE errors now resolve to LONG_MIN and LONGMAX instead of
integer overflow
filetol()
reads long int from an open file, skips preceding
whitespaces returns -1 if error, 1 on success.
*num set to LONG_MAX or LONG_MIN on overflow.
If number of digits is > than LUAI_MAXNUMBER2STR
filepointer will continue till the next non digit
but buffer will stop being filled with characters.
Preceding zero is ignored.
Change-Id: Ia42d0f73c63a894625bca4581e9b7e1cc7387fd2
Some of the lcd functions had support for multiple screens but this wasn't
very safe since the screen number wasn't bounded within the screens[] array
This adds support for all the lcd functions along with checking that screen#
is bounded properly, adds around 600 bytes to devices with a remote screen
devices without a remote screen lock to SCREEN_MAIN
Change-Id: I618bbc7b3919c7b0ff375fb2d71949d7cab43c87
rli_marshal and rli_copy allow the use of a custom lua function
instead of the built-ins, this custom function can signal to stop
before the whole image is iterated.
Originally it was checking for a return of 0
which was additional overhead for the built-in functions
(which never stop early) as well.
Now custom_transform sets the x & y deltas to 0 to indicate early
exit removing an extra 'if' per cycle and return from all of the
rli_transform functions
The lcd_xxx_bitmap functions all require x, y, w, h, screen these calls
have been consolidated into a single function get_bmp_bounds()
Change-Id: I88de3149c58d1bfb40e9d1a91341fb86cbd63b51
While luaL_addstring() works perfectly fine for the
final buffer once Lual_pushresult() is called
kbd_input doesn't display a previous input properly
since the buffer hasn't been finalized yet
Change-Id: Ic50acaa8b7b17077dec8750dd2b6382624e8a549
Removes unneeded functions from kbd_input
Consolidates message filling function for gui_syncyesno_run & do_menu
Change-Id: If3c3cea3cbf37a8dc52983c0db174de6d54b35f8
The way to call the playlist functions has changed
rb.playlist("option", var)
rb.playlist_add(filename) = becomes rb.playlist("add", filename)
added playlist.lua to the includes for conversion to old functions
if your script is broken by this change you simply add `require("playlist")`
to the top for the old functionality
added rb.playlist_tracks(dir, filename) to playlist.lua
this will allow you to add all tracks in a playlist.m3u8
to a lua table
Change-Id: I87fcc56be365d8495d214f069331b6ddbfbef1db
audio_play was removed from the rocklib I assume due to inconsistent
behavior I've readded it with a check for audio paused which instead
uses rewind/ff and then resumes audio
the way to call the audio functions has changed as well
rb.audio("option", var)
so rb.audio_play(0, 0) becomes rb.audio("play", 0, 0)
audio_audio_flush_and_reload_tracks becomes
rb.audio("flushandreloadtracks")
all functions except audio("getfilepos") return the previous (or still current)
status
added audio.lua to the includes for conversion to old functions
if your script is broken by this change you simply add `require("audio")`
to the top for the old functionality
Change-Id: I364adf0c85d9c12b98cde29c26fbe5ee05b9d331
Both of these functions modified the string in the lua stack
per lua manual:
'When a C function receives a string argument from Lua,
there are only two rules that it must observe: Not to pop the string
from the stack while accessing it and never to modify the string'
strip_extension will still work with old parameters
and is thus backwards compatible
strip_extension("filename")
create_numbered_filename has changed slightly and IS NOT backwards compatible
create_numbered_filename(path, prefix, suffix, [number])
(number defaults to -1)
Change-Id: I34cf7e2f6f691f33d5ac2b2e995855a171fb99b3
allows rocklib_img to be excluded if needed
stops rocklib_aux from generating redundant prototypes for
lcd_mono_bitmap[_part]
Change-Id: Ie208ad71ab5f9a7deb026dc01a5b0a0631a0d29c
rocklib_aux is auto generated from plugin.h
there are a few functions that get added automatically that
are unusable without their companion functions or duplicate
functionality already supplied by lua
Duplicated functionality:
rb->rand, rb->srand
-- see math.rand math.srand
rb->remove, rb->rename
-- see os.remove, os.rename
Unusable:
rb->open_utf8
-- this should be added to the lua file open routines (if at all)
rb->codec_run_proc, rb->codec_close
-- without rb->codec_load_file these are pointless
rb->timer_set_period, timer_unregister
-- even with timer_register implemented lua is not
-- reentrant and crashes the state when timer fires
Shouldn't be used!:
rb->strlcpy, rb->strlcat, rb->strcpy, rb->strcat
-- lua reuses strings by hashed values you break this contract if
-- you change strings behind its back plus lua provides a way to
-- do these functions safely within the strings api
Change-Id: I2f65704a90930378cbbceb254e52f61e8074471e
int is an incompatible type for targets that have 32bit fb_data
need to use FB_SCALARPACK for them
Change-Id: Ib3b5ff19c54d8d1bb76af33d0538a17a71301514
removes tslf allocations from do_menu and gui_syncyesno_run in favor of
lua_newuserdata
removes some luaL_opt functions in favor of equivalent lua_to functions
moves some definitions to the rocklib.h file
Change-Id: Iaacc3249b8f1af2c220ce59dead0050c66cb3b04
On Classic, IRAM1 (second 128Kb of a total of 256KB available IRAM) is
slower than DRAM. Codecs that actually are using regions of IRAM1 runs
faster when DRAM is used, so IRAM1 is disabled and only IRAM0 remains
enabled: 48KB for core and 80KB for codecs/plugins.
The next test_codec results shows how decode time is decreased:
file boosted unboosted
*.ra ~1.5% ~0.5%
*.mpc ~21% ~4.5%
*.ogg ~0.5% ~0%
nero_he*.m4a ~8% ~1%
nero*.m4a ~25% ~7%
wmapro*.wma ~4.5% ~0%
wma*.wma ~25% ~7%
In addition there is a small power save when IRAM1 HW is disabled.
Change-Id: I102adee11458e82037f23076d5d5956e23235de8
Cleaned up, rebased, and forward-ported from the xvortex fork.
(original credit to vsoftster@gmail.com)
Change-Id: Ibcc023a0271ea81e901450a88317708c2683236d
Signed-off-by: Solomon Peachy <pizza@shaftnet.org>
I previously noticed that manually clearing the framebuffer while scroll
function was active caused lua to crash
I could reproduce in sim and on device but I thought using the plugin
supplied rb->lcd_clear_screen was immune to this issue
Unfortunately some devices exhibit this behavior with the plugin function
as well
This patch adds rb->lcd_scroll_stop() before lcd_clear_screen at lua start-up
and to the supplied include file lcd.lua
Change-Id: I9800145e5c834ea27df5db5f1bca50b0d40faa49
Last commit was just a test to see if it work this one cleans it up
a bit and should be a bit faster
Change-Id: Ifdff5c5b78bcc6889506de607193246beccdde6b