summaryrefslogtreecommitdiff
path: root/apps/plugins/test_codec.c
AgeCommit message (Collapse)Author
2017-12-08Get test_codec synced with changes in 6c868ddMichael Sevakis
Change-Id: I47c5ae09ff620b46e42463654e1a073b59fb2191
2016-05-14Manually unboost if not using boost in test_codecMichael Giacomelli
Right now GUI boost interfers with test_codec running unboosted by varying the CPU frequency. This at least makes it more consistent if run without user input. Change-Id: I121615098d6bd72ccd13c4e665cc2e4d45d7b58c
2013-07-06Enable setting of global output samplerate on certain targets.Michael Sevakis
Replaces the NATIVE_FREQUENCY constant with a configurable frequency. The user may select 48000Hz if the hardware supports it. The default is still 44100Hz and the minimum is 44100Hz. The setting is located in the playback settings, under "Frequency". "Frequency" was duplicated in english.lang for now to avoid having to fix every .lang file for the moment and throwing everything out of sync because of the new play_frequency feature in features.txt. The next cleanup should combine it with the one included for recording and generalize the ID label. If the hardware doesn't support 48000Hz, no setting will be available. On particular hardware where very high rates are practical and desireable, the upper bound can be extended by patching. The PCM mixer can be configured to play at the full hardware frequency range. The DSP core can configure to the hardware minimum up to the maximum playback setting (some buffers must be reserved according to the maximum rate). If only 44100Hz is supported or possible on a given target for playback, using the DSP and mixer at other samperates is possible if the hardware offers them. Change-Id: I6023cf0c0baa8bc6292b6919b4dd3618a6a25622 Reviewed-on: http://gerrit.rockbox.org/479 Reviewed-by: Michael Sevakis <jethead71@rockbox.org> Tested-by: Michael Sevakis <jethead71@rockbox.org>
2013-05-21Fix CPU boosting in test_codec.Michael Sevakis
Boost only for tests and unboost immediately afterwards. It was leaving the CPU boosted after exiting. Change-Id: I010c4b975bd27e8990dc057ddd244dab233411ca
2012-04-29Fundamentally rewrite much of the audio DSP.Michael Sevakis
Creates a standard buffer passing, local data passing and messaging system for processing stages. Stages can be moved to their own source files to reduce clutter and ease assimilation of new ones. dsp.c becomes dsp_core.c which supports an engine and framework for effects. Formats and change notifications are passed along with the buffer so that they arrive at the correct time at each stage in the chain regardless of the internal delays of a particular one. Removes restrictions on the number of samples that can be processed at a time and it pays attention to destination buffer size restrictions without having to limit input count, which also allows pcmbuf to remain fuller and safely set its own buffer limits as it sees fit. There is no longer a need to query input/output counts given a certain number of input samples; just give it the sizes of the source and destination buffers. Works in harmony with stages that are not deterministic in terms of sample input/output ratio (like both resamplers but most notably the timestretch). As a result it fixes quirks with timestretch hanging up with certain settings and it now operates properly throughout its full settings range. Change-Id: Ib206ec78f6f6c79259c5af9009fe021d68be9734 Reviewed-on: http://gerrit.rockbox.org/200 Reviewed-by: Michael Sevakis <jethead71@rockbox.org> Tested-by: Michael Sevakis <jethead71@rockbox.org>
2012-04-26test_codec: Fix some problems with writing WAV with DSPMichael Sevakis
On big-endian architecture, DSP output must be coverted to little- endian first. DSP output is also always interleaved stereo, 16 bit, NATIVE_FREQUENCY and wavinfo should be correct for this. Also, use standard clip_sample_16 already available. Change-Id: Ifa7b9fc77f0573070c7e79f059dc3000c437c42e
2012-03-22Don't hardcode cpu frequency in test_codecMarcin Bukat
Change-Id: Idcd7b024edb7a550b42b935fadfb3d869bab14c6
2012-03-03test_X plugins PLA integrationJean-Louis Biasini
1) change all keymaps to PLA 2) add alternative exit keymaps Change-Id: I5cb8b1fcc515d2b6f9934482e72b80767b2c2fb0 Reviewed-on: http://gerrit.rockbox.org/158 Reviewed-by: Thomas Martitz <kugel@rockbox.org>
2012-01-29Fix building test plugins on non-touch targets, for real.Thomas Martitz
Change-Id: I8f2105fe3357f00d9e085444cd867bec0e2a7143
2012-01-29Revert "Fix building test plugins on non-touch targets."Thomas Martitz
This reverts commit 84c77d40f512b5052edec1b9c283b0bea0b68b27. The commit used an unrelated define which doesn't actually work.
2012-01-28Fix building test plugins on non-touch targets.Magnus Holmgren
Change-Id: I6d058099ebb4c9d0aa5b21cb8b2e01bb4a5965d4
2012-01-27test_codec/test_fps: Use pluginlib_touchscreen API to make them fit for ↵Thomas Martitz
touchscreen including point mode. Enable test_fps on RaaA also. Change-Id: Ifeb60d5ad30bde1f8a645cd9e9d5d5ae34f4425d
2011-12-25rbpaths: Add new special dir HOME_DIR for RaaA.Thomas Martitz
HOME_DIR is intended for not-so-advanced files which shall be user visible, and thus not in /.rockbox. Therefore HOME_DIR is translated to $HOME on RaaA, /sdcard on android, the internal memory on ypr0 and "/" on native targets. ROCKBOX_DIR ("/.rockbox") already existed as special and is translated to whatever the real rockbox dir is on the target (e.g. /sdcard/rockbox on android), but it's not suitable for some files we generate (e.g. battery-bench.txt). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31430 a1c6a512-1295-4272-9138-f99709370657
2011-12-24Initial commit of the Samsung YP-R0 port.Thomas Martitz
This port is a hybrid native/RaaA port. It runs on a embedded linux system, but is the only application. It therefore can implement lots of stuff that native targets also implement, while leveraging the underlying linux kernel. The port is quite advanced. User interface, audio playback, plugins work mostly fine. Missing is e.g. power mangement and USB (see SamsungYPR0 wiki page). Included in utils/ypr0tools are scripts and programs required to generate a patched firmware. The patched firmware has the rootfs modified to load Rockbox. It includes a early/safe USB mode. This port needs a new toolchain, one that includes glibc headers and libraries. rockboxdev.sh can generate it, but e.g. codesourcey and distro packages may also work. Most of the initial effort is done by Lorenzo Miori and others (on ABI), including reverse engineering and patching of the original firmware, initial drivers, and more. Big thanks to you. Flyspray: FS#12348 Author: Lorenzo Miori, myself Merry christmas to ypr0 owners! :) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31415 a1c6a512-1295-4272-9138-f99709370657
2011-12-17Fix building of test_codecNils Wallménius
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@31343 a1c6a512-1295-4272-9138-f99709370657
2011-09-06rk27xx - enable a few test pluginsMarcin Bukat
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30459 a1c6a512-1295-4272-9138-f99709370657
2011-08-30Submit parts of FS#12189 regarding codec API. Replaces access to global ↵Andree Buschmann
settings with a dedicated function to determine if the current track shall be looped. Used by several synthesizer codecs. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30391 a1c6a512-1295-4272-9138-f99709370657
2011-08-29Final commit to get test_codec working properly for both freq-scaling and ↵Andree Buschmann
non-freq-scaling targets. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30375 a1c6a512-1295-4272-9138-f99709370657
2011-08-29Fix logic of test_codec for targets with HAVE_ADJUSTABLE_CPU_FREQ.Andree Buschmann
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30374 a1c6a512-1295-4272-9138-f99709370657
2011-05-15test_codec: Allow user to abort tests using target-defined TESTCODEC_EXITBUTTON.Michael Sevakis
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29881 a1c6a512-1295-4272-9138-f99709370657
2011-04-27Commit FS#12069 - Playback rework - first stages. Gives as thorough as ↵Michael Sevakis
possible a treatment of codec management, track change and metadata logic as possible while maintaining fairly narrow focus and not rewriting everything all at once. Please see the rockbox-dev mail archive on 2011-04-25 (Playback engine rework) for a more thorough manifest of what was addressed. Plugins and codecs become incompatible. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29785 a1c6a512-1295-4272-9138-f99709370657
2011-03-16Sync test_codec to r29595.Michael Sevakis
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29596 a1c6a512-1295-4272-9138-f99709370657
2011-02-23Give playback engine better control over the codec. Codec simply follows ↵Michael Sevakis
commands and doesn't concern itself with audio state. Get track change notification in on the actual last buffer insert of the track because now audio simply waits for a track change notify from PCM on the last track and it must be sent reliably. This is still at an intermediate stage but works. Codecs and plugins become incompatible. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29387 a1c6a512-1295-4272-9138-f99709370657
2011-02-15Undo unwanted commit r29310.Andree Buschmann
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29311 a1c6a512-1295-4272-9138-f99709370657
2011-02-15All AAC-HE files will double the frame sample count, not only AAC-HE files ↵Andree Buschmann
with SBR upsampling. This change fixes issues with some m4a files reported in the forums. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29310 a1c6a512-1295-4272-9138-f99709370657
2010-12-02HDD6330: add missing button for test_codec.Szymon Dziok
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28721 a1c6a512-1295-4272-9138-f99709370657
2010-11-30HD300 - plugins keymapsMarcin Bukat
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28712 a1c6a512-1295-4272-9138-f99709370657
2010-11-24test_codec: fix menu broken in r28637Nils Wallménius
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28659 a1c6a512-1295-4272-9138-f99709370657
2010-11-22Fix mistake on targets without frequency scaling.Michael Giacomelli
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28638 a1c6a512-1295-4272-9138-f99709370657
2010-11-22Add option to run test_codec unboosted on players with boosting.Michael Giacomelli
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28637 a1c6a512-1295-4272-9138-f99709370657
2010-10-27test_codec: Align the codec buffer to pointer size, since tlsf wants that. ↵Nils Wallménius
Fixes a crash when running tremor in test_codec on 64 bit sim. (The tlsf init bailed out but tremor doesn't check the return and went on to alloc memory anyway) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28365 a1c6a512-1295-4272-9138-f99709370657
2010-10-16Remove some inconsistent guarding around cpucache_* functions to fix a ↵Nils Wallménius
test_codec crash on coldfire, breaks plugin api compatibility so sorted and bumped version numbers. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28287 a1c6a512-1295-4272-9138-f99709370657
2010-10-10Fix a few div0 cases forgotten in r27684 to enable enabling asm ↵Thomas Martitz
optimizations for android builds. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28235 a1c6a512-1295-4272-9138-f99709370657
2010-09-02fix test_codec broken after r27968Rafaël Carré
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27985 a1c6a512-1295-4272-9138-f99709370657
2010-08-24Second try: Introduce plugin_crt0.c that every plugin links.Thomas Martitz
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-23Revert "Introduce plugin_crt0.c that every plugin links."Thomas Martitz
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-23Introduce plugin_crt0.c that every plugin links.Thomas Martitz
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-07-06Commit FS#11458 by me. Fixes test_codec to work on files larger then the ↵Michael Giacomelli
available audio buffer. Allows test_codec to work normally on the AMS Sansas as well as D2, etc. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27303 a1c6a512-1295-4272-9138-f99709370657
2010-06-22test_codec: allocate wavbuffer/dspbuffer dynamicallyRafaël Carré
It'll build on targets with small plugin buffer, the buffer for each of them will be a little smaller than 32kB. "should be enough" git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27050 a1c6a512-1295-4272-9138-f99709370657
2010-06-22test_codec: remove 2 static string buffers and put them on the stackRafaël Carré
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27049 a1c6a512-1295-4272-9138-f99709370657
2010-06-22test_codec: fix DEBUGF pointer format specifierRafaël Carré
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27040 a1c6a512-1295-4272-9138-f99709370657
2010-06-21Rockbox as an application: Replace many occurences of #ifdef SIMULATOR with ↵Thomas Martitz
#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-17test_codec: print crc's that start with 0 properly.Nils Wallménius
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26890 a1c6a512-1295-4272-9138-f99709370657
2010-05-31test_codec: close the log file before attempting to open a new one, and ↵Rob Purchase
clear the button queue before displaying the menu a second time. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26437 a1c6a512-1295-4272-9138-f99709370657
2010-05-06Make open() posix compliant api-wise. A few calls (those with O_CREAT) need ↵Thomas Martitz
the additional optional mode parameter so add it. Impact for the core is almost zero, as open() is a wrapper macro for the real open function which doesn't take the variable parameter. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25844 a1c6a512-1295-4272-9138-f99709370657
2010-05-06Make creat() posix compliant API-wise. Shouldn't affect the core as it's ↵Thomas Martitz
wrapped via a static inline. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25843 a1c6a512-1295-4272-9138-f99709370657
2010-03-08Use the same output func for wav writing and checksum calculation, ↵Nils Wallménius
simplifying the code and possibly speeding up checksum calculation slightly git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25068 a1c6a512-1295-4272-9138-f99709370657
2010-02-14Packard Bell Vibe 500: Finish plugin keymaps. Rockbox compiles clean now for ↵Szymon Dziok
the target. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24658 a1c6a512-1295-4272-9138-f99709370657
2009-12-15Cowon D2: Rename COWOND2_PAD -> COWON_D2_PAD to match macro used in manual, andTomer Shalev
to target naming conventions in general git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24010 a1c6a512-1295-4272-9138-f99709370657
2009-11-22Give test_codec the ability to checksum files or folders of files, usefull ↵Nils Wallménius
to verify output integrity. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23711 a1c6a512-1295-4272-9138-f99709370657