summaryrefslogtreecommitdiff
path: root/apps/codecs.c
AgeCommit message (Collapse)Author
2007-11-30Move encoder CPU boost control to the core. Allow CPU to sleep a bit when ↵Michael Sevakis
PCM buffer is empty and save some power. Codec API becomes incompatible so full updates! :) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15854 a1c6a512-1295-4272-9138-f99709370657
2007-11-18SPC Codec: Run SPC emulation on COP and audio sample processing on CPU on ↵Michael Sevakis
dual-core PortalPlayer targets. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15673 a1c6a512-1295-4272-9138-f99709370657
2007-11-18Make speex the new voice format for SWCODEC targets (non-Archos). Remove ↵Michael Sevakis
codec swapping and build speex voice decoding directly into the core binary. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15668 a1c6a512-1295-4272-9138-f99709370657
2007-11-03Misc. buffering related playback tweaksBrandon Low
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15435 a1c6a512-1295-4272-9138-f99709370657
2007-11-02Make bufread and bufgetdata blocking. They now return when enough data is ↵Nicolas Pennequin
available or when EOF is reached. This improves the API and removes the need for several duplicate waiting loops. Also fix a few logfqueue messages. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15412 a1c6a512-1295-4272-9138-f99709370657
2007-11-02Fix yellowBrandon Low
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15409 a1c6a512-1295-4272-9138-f99709370657
2007-11-02Improve upon my hackity hack from before by separating audio into two types: ↵Brandon Low
that which may be large and can be streamed and that which is small and cannot be streamed. While modifying types, allow codecs to split across the buffer wrap and dig out/move around the code that reads a codec off of the buffer to facilitate that simple sounding change. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15408 a1c6a512-1295-4272-9138-f99709370657
2007-10-24logf changes:Nicolas Pennequin
* Disable logf by default and allow per-file enabling with "#define LOGF_ENABLE". To enable globally add that define in the config.h file. * Transform logf calls into DEBUGF calls when ROCKBOX_HAS_LOGF isn't defined, so that they get printed to the console in the sim. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15291 a1c6a512-1295-4272-9138-f99709370657
2007-09-28Commit a subset of the dual core changes that have to do with cache ↵Michael Sevakis
handling, stacks, firmware startup and thread startup. Tested on e200, H10-20GB, iPod Color and 5.5G. Thread function return implemented for all targets. Some changes to plugins to follow shortly. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14879 a1c6a512-1295-4272-9138-f99709370657
2007-05-07Clean up the codec API - remove all unused (and in many cases inappropriate) ↵Dave Chapman
functions, move functions used only by encoders into the HAVE_RECORDING part of the API and document the reasons for the more unexpected functions being present. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13343 a1c6a512-1295-4272-9138-f99709370657
2007-04-21General housekeeping: Make plugin buffer functions take size_t * instead of ↵Michael Sevakis
int * to match the parameter type of the buffer functions called in the core. Get rid of unsafe int * <==> size_t * casting. Use ssize_t where int was used and size_t where unsigned int was used in the buffer calls to not alter signedness in the plugins. No API version change since it should only be an issue for 64-bit sim builds. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13233 a1c6a512-1295-4272-9138-f99709370657
2007-03-16Get rid of the 'center' parameter for splashes. There were only 2 of almost ↵Jens Arnold
500 splashes which were not centered. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12807 a1c6a512-1295-4272-9138-f99709370657
2007-03-04Dual core support for PP502x players (iPod G4 and later, iriver h10, Sansa - ↵Daniel Ankers
iPod G3 will be coming soon.) This allows threads to be run on either core provided that all communications between the cores is done using uncached memory. There should be no significant change in battery life from doing this. Documentation (on the RockboxKernel wiki page) will follow shortly. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12601 a1c6a512-1295-4272-9138-f99709370657
2007-03-04SWCODEC Recording Codecs: Fix problems with hanging recording screen ↵Michael Sevakis
(chiefly on x5) when no voice file present and source is not FMRadio. Caused by extra audio stops causing encoder to unload prematurely. Fix is to have separate stop flags for each codec type to prevent collisions. Also now safe to plug into USB when recording and encoder will stay loaded and not be stopped by the call to audio_stop_playback. Additional discovery: playback will not be able to restart after a USB plug during recording. Probably an old bug. I recommend in the future that recording have higher priority on system resources than playback and playback be denied access explicitly if recording requires them. Codec API becomes incompatible so do full updates. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12579 a1c6a512-1295-4272-9138-f99709370657
2007-02-07Fix resampling clicking as much as possible at the moment. 1) Upsampling ↵Michael Sevakis
clicked because of size inaccuracies returned by DSP. Fix by simplifying audio system to use per-channel sample count from codec to pcm buffer. 2) Downsampling affected by 1) and was often starting passed the end of the data when not enough was available to generate an output sample. Fix by clamping input range to last sample in buffer and using the last sample value in the buffer. A perfect fix will require a double buffering scheme on the resampler to sufficient data during small data transients on both ends at all times of the down ratio on input and the up ratio on output. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12218 a1c6a512-1295-4272-9138-f99709370657
2007-01-22Simple cpu boost tracker for LOGF builds. Shows the last 64 cpu_boost() ↵Jonathan Gordon
calls from the debug menu git-svn-id: svn://svn.rockbox.org/rockbox/trunk@12087 a1c6a512-1295-4272-9138-f99709370657
2006-12-111) Delete unused files from old database and old gui files 2) Remove ↵Nils Wallménius
unneccesary includes of the old database header 3) Delete the deprecated databox plugin git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11715 a1c6a512-1295-4272-9138-f99709370657
2006-11-26FS#6357, patch 1: let iramcopy and bss share the same space in codecs andTomasz Malesinski
plugins. Currently, in case of plugins using IRAM bss is cleared twice, once in the loader, once in PLUGIN_IRAM_INIT. For codecs, bss is cleared only during codec initialization. Also, removed double variables in codecs storing a pointer to codec_api. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11606 a1c6a512-1295-4272-9138-f99709370657
2006-11-06Big Patch adds primarily: Samplerate and format selection to recording for ↵Michael Sevakis
SWCODEC. Supprort for samplerates changing in playback (just goes with the recording part inseparably). Samplerates to all encoders. Encoders can be configured individually on a menu specific to the encoder in the recording menu. File creation is delayed until flush time to reduce spinups when splitting. Misc: statusbar icons for numbers are individual digits to display any number. Audio buffer was rearranged to maximize memory available to recording and properly reinitialized when trashed. ColdFire PCM stuff moved to target tree to avoid a complicated mess when adding samplerate switching. Some needed API changes and to neaten up growing gap between hardware and software codecs. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11452 a1c6a512-1295-4272-9138-f99709370657
2006-10-03add some consistancy to the path #definesJonathan Gordon
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11114 a1c6a512-1295-4272-9138-f99709370657
2006-09-26OopsLinus Nielsen Feltzing
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11058 a1c6a512-1295-4272-9138-f99709370657
2006-09-26Patch #4899 by Robert Keevil - Automatic pause on iPod when removing the ↵Linus Nielsen Feltzing
headphones git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11057 a1c6a512-1295-4272-9138-f99709370657
2006-09-16New scheduler, with priorities for swcodec platforms. Frequent taskMiika Pekkarinen
switching should be more efficient and tasks are stored in linked lists to eliminate unnecessary task switching to improve performance. Audio should no longer skip on swcodec targets caused by too CPU hungry UI thread or background threads. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10958 a1c6a512-1295-4272-9138-f99709370657
2006-08-28Added FS#2939 Encoder Codec Interface + Codecs by Antonius Hellmann with ↵Michael Sevakis
additional FM Recording support and my modifications git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10789 a1c6a512-1295-4272-9138-f99709370657
2006-06-21Added discard_codec to simulator code.Tomasz Malesinski
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@10144 a1c6a512-1295-4272-9138-f99709370657
2006-04-15Put new_track on the codec_api, and use it instead of the reload_codec ↵Brandon Low
variable in most places. Should help with problems people have had with GUI vs. playback sync. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9670 a1c6a512-1295-4272-9138-f99709370657
2006-04-11Rework track skipping. Full playback stop is no longer involved in track ↵Brandon Low
skipping. Further simplification of the play related functions can be achieved with this in place, but that's for later. Known skip related bug, high pitched noise sometimes, otherwise stuff is better git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9601 a1c6a512-1295-4272-9138-f99709370657
2006-03-26Initial version of tagcache! There are still some bugs in the engineMiika Pekkarinen
and much more problems with the UI. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9256 a1c6a512-1295-4272-9138-f99709370657
2006-03-24Convert playback.c to use unsigned byte counters, and _minor_ refactoring of ↵Brandon Low
buffer callbacks git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9227 a1c6a512-1295-4272-9138-f99709370657
2006-03-02Simulators: Fix pointer size vs. int size problems (64bit hosts) in plugin ↵Jens Arnold
loader and codec loader. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8880 a1c6a512-1295-4272-9138-f99709370657
2006-02-06Added memmove() to codec API & plugin API, and changed codeclib and plugin ↵Jens Arnold
libs to use it. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8602 a1c6a512-1295-4272-9138-f99709370657
2006-02-03Remove exported pcm functions. Codecs should never be allowed to accessBrandon Low
the pcm directly. Only through the callbacks in playback.c. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8544 a1c6a512-1295-4272-9138-f99709370657
2006-01-21Fixed the codec loader bug.Miika Pekkarinen
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8403 a1c6a512-1295-4272-9138-f99709370657
2006-01-18Profiling support, tools and documentation.Brandon Low
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8375 a1c6a512-1295-4272-9138-f99709370657
2006-01-18More consistent error checking.Jens Arnold
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8364 a1c6a512-1295-4272-9138-f99709370657
2006-01-18New codec loader, using the same mechanism as the new plugin loader. API ↵Jens Arnold
version numbering restarted for the new system. Uses the target ID from configure, so don't change that too often. * Fixed sim_plugin_load_ram() to truncate the tempfile. * Reduced plugin buffer size to 512KB for iriver and iPod. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8362 a1c6a512-1295-4272-9138-f99709370657
2005-12-12iPod: current_tick is now a variable, so we can export it via the plugin and ↵Dave Chapman
codec APIs git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8225 a1c6a512-1295-4272-9138-f99709370657
2005-11-16replaced all the splash calls by gui_sync_splash, added some missing remote ↵Kevin Ferrare
key in the playlist viewer git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7909 a1c6a512-1295-4272-9138-f99709370657
2005-11-12iPod: current_tick is (currently) a macro - so we exclude it from the plugin ↵Dave Chapman
and codec APIs git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7826 a1c6a512-1295-4272-9138-f99709370657
2005-08-29Renamed CONFIG_HWCODEC and MASNONE to the more appropriate CONFIG_CODEC and ↵Jens Arnold
SWCODEC, respectively. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7416 a1c6a512-1295-4272-9138-f99709370657
2005-08-21Now codecs will do the buffer flushing after seeking as they find itMiika Pekkarinen
necessary. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7369 a1c6a512-1295-4272-9138-f99709370657
2005-08-20Initial voice ui support for software codec platforms. Added also aMiika Pekkarinen
beep when changing tracks. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7360 a1c6a512-1295-4272-9138-f99709370657
2005-07-12Resume now starts playback at the point it was stopped, not 2-7 seconds later.Ryan Jackson
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7125 a1c6a512-1295-4272-9138-f99709370657
2005-07-10Fixed a simulator crash while trying to play a song. Fixed crossfadeMiika Pekkarinen
when selecting a new track to play. Most likely fixed a bug which caused playback to stop on track change. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7094 a1c6a512-1295-4272-9138-f99709370657
2005-07-07PCM buffering fixes. Made a temporary workaround for playback glitchMiika Pekkarinen
bug (see the patch). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7049 a1c6a512-1295-4272-9138-f99709370657
2005-07-05Applied patch "[ 1232957 ] MP3 metadata fixes for software codec".Miika Pekkarinen
Thanks to Magnus Holmgren. Now metadata reading is better with improved performance for mp3 files. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7030 a1c6a512-1295-4272-9138-f99709370657
2005-07-05Patch #1232549 by Ryan Jackson, adds seeking and comments to Vorbis playbackLinus Nielsen Feltzing
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7025 a1c6a512-1295-4272-9138-f99709370657
2005-06-27Moved the codec and plugin buffer sizes to the config-*.h files instead ofDaniel Stenberg
having it repeated in numerous files where they all had to be updated to the same value if ever changed. This allows specific models to actually have its own buffer sizes. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@6901 a1c6a512-1295-4272-9138-f99709370657
2005-06-26Initial DSP implementation. DSP supports resampling audio stream fromMiika Pekkarinen
codecs (currently works corrently only with mp3's, somebody should fix that). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@6877 a1c6a512-1295-4272-9138-f99709370657
2005-06-22this is not constDaniel Stenberg
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@6824 a1c6a512-1295-4272-9138-f99709370657