summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)AuthorFilesLines
2013-06-30Update software recording engine to latest codec interface.Michael Sevakis16-2787/+2659
Basically, just give it a good rewrite. Software codec recording can be implemented in a more straightforward and simple manner and made more robust through the better codec control now available. Encoded audio buffer uses a packed format instead of fixed-size chunks and uses smaller data headers leading to more efficient usage. The greatest benefit is with a VBR format like wavpack which needs to request a maximum size but only actually ends up committing part of that request. No guard buffers are used for either PCM or encoded audio. PCM is read into the codec's provided buffer and mono conversion done at that time in the core if required. Any highly-specialized sample conversion is still done within the codec itself, such as 32-bit (wavpack) or interleaved mono (mp3). There is no longer a separate filename array. All metadata goes onto the main encoded audio buffer, eliminating any predermined file limit on the buffer as well as not wasting the space for unused path queue slots. The core and codec interface is less awkward and a bit more sensible. Some less useful interface features were removed. Threads are kept on narrow code paths ie. the audio thread never calls encoding functions and the codec thread never calls file functions as before. Codecs no longer call file functions directly. Writes are buffered in the core and data written to storage in larger chunks to speed up flushing of data. In fact, codecs are no longer aware of the stream being a file at all and have no access to the fd. SPDIF frequency detection no longer requires a restart of recording or plugging the source before entering the screen. It will poll for changes and update when stopped or prerecording (which does discard now-invalid prerecorded data). I've seen to it that writing a proper header on full disk works when the format makes it reasonably practical to do so. Other cases may have incorrect data sizes but sample info will be in tact. File left that way may play anyway. mp3_enc.codec acquires the ability to write 'Info' headers with LAME tags to make it gapless (bonus). Change-Id: I670685166d5eb32ef58ef317f50b8af766ceb653 Reviewed-on: http://gerrit.rockbox.org/493 Reviewed-by: Michael Sevakis <jethead71@rockbox.org> Tested-by: Michael Sevakis <jethead71@rockbox.org>
2011-07-17AAC: Another gapless fix, this one for the end of the file. The real size of ↵Magnus Holmgren1-9/+31
the last frame was lost in r29727, as indicated by Yusaku Inui in FS#12185, so bring it back. Now the decoded length of test1_nero.m4a (in FS#12185) only differs by one sample compared to Foobar2000 (Rockbox has one more leading sample, for some reason). Also moved a few lines to a better place. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30149 a1c6a512-1295-4272-9138-f99709370657
2011-06-18FS#12161: Correct the gapless processing for AAC, so that it doesn't remove ↵Magnus Holmgren1-7/+28
too much from the start of a track. Also simplify the logic a bit. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30012 a1c6a512-1295-4272-9138-f99709370657
2011-05-19Add a codec featureset overview (for now 'seek', 'resume' and 'gapless') to ↵Andree Buschmann1-3/+38
the manual. Additionally change table formatting and add a note to the SID format. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29899 a1c6a512-1295-4272-9138-f99709370657
2011-04-13Fix the Xing header parser to have reliable gapless playback. Closes FS#12062.Andree Buschmann1-2/+2
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29708 a1c6a512-1295-4272-9138-f99709370657
2009-10-17Add a option to skip length which lets you skip 5s before the end of a song, ↵Thomas Martitz3-10/+40
which can be useful on gapless albums. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23229 a1c6a512-1295-4272-9138-f99709370657
2009-10-06add gapless playback for Nero encoded AAC filesMarcoen Hirschberg3-0/+38
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22984 a1c6a512-1295-4272-9138-f99709370657
2009-10-02add gapless support for MP3 files encoded with iTunesMarcoen Hirschberg1-12/+38
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@22872 a1c6a512-1295-4272-9138-f99709370657
2008-03-30Fixes FS #8389 (wv error). For WavPack files that don't have the length ↵Dave Bryant1-3/+21
stored in the header, guess a length on the high-side as an interim fix. This plays fine (even gapless), but the progress bar is off and seeking is a little weird (but usable). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16893 a1c6a512-1295-4272-9138-f99709370657
2007-08-12ignore comments containing iTunes 7 gapless data; should solve issues ↵Robert Kukla1-2/+5
reported in http://forums.rockbox.org/index.php?topic=12048.0 and http://forums.rockbox.org/index.php?topic=12053.0 git-svn-id: svn://svn.rockbox.org/rockbox/trunk@14294 a1c6a512-1295-4272-9138-f99709370657
2007-06-16AAC: Add support for iTunes-style gapless playback.Magnus Holmgren2-2/+102
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13636 a1c6a512-1295-4272-9138-f99709370657
2006-11-14Strip APE tags during buffering so they do not break MP3 gapless playback.Mark Arigo1-3/+36
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@11525 a1c6a512-1295-4272-9138-f99709370657
2006-05-20Patch from bug report #5200 by Mark Arigo - attempt to fix gapless playback ↵Dave Chapman1-88/+75
after seeking in an MP3 file. It works for me, but needs more testing with a wider range of files before we can close the bug report - please post feedback on the tracker. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9962 a1c6a512-1295-4272-9138-f99709370657
2006-05-01Tweak MP3 seeking a little, and don't do gapless trim if a seek has been done.Magnus Holmgren1-4/+10
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9848 a1c6a512-1295-4272-9138-f99709370657
2006-04-29Fix the first-frame memmove from pretending the data is interleaved, which ↵Thom Johansen1-2/+6
it isn't anymore. This should fix all remaining gapless problems with Musepack. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@9827 a1c6a512-1295-4272-9138-f99709370657
2006-02-05Added a cache for playlist control commands. On non-dircache systems, ↵Hardeep Sidhu3-188/+281
behaviour should be the same as before (all commands except shuffle flushed immediately). On dircache systems, commands are only flushed when disk is accessed or during shutdown. This especially reduces disk accesses when playing queued files and should fix the problem with gapless playback. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8584 a1c6a512-1295-4272-9138-f99709370657
2006-01-20Fixed a few iriver playback quirks and issues with previous fixes.Miika Pekkarinen4-40/+91
Also fixed "TST.." bug when seeking and possible an enhancement to mp3 gapless playback also. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8402 a1c6a512-1295-4272-9138-f99709370657
2005-12-01iRiver: re-add an end of file check, to see if it helps the reported ↵Magnus Holmgren1-0/+1
problems with gapless MP3 playback. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@8119 a1c6a512-1295-4272-9138-f99709370657
2005-08-15One more gapless fix for LAME MP3 files.Magnus Holmgren1-3/+3
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7331 a1c6a512-1295-4272-9138-f99709370657
2005-08-13More complete gapless playback implementation in the MP3 codec (using LAME ↵Magnus Holmgren1-14/+27
header values). Some cleanups as well. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7312 a1c6a512-1295-4272-9138-f99709370657
2005-07-17Fixed the gapless playback.Miika Pekkarinen1-6/+11
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@7180 a1c6a512-1295-4272-9138-f99709370657
2005-06-12First attempt at gapless MP3 support using LAME header info.Thom Johansen1-9/+40
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@6690 a1c6a512-1295-4272-9138-f99709370657
2005-06-12Added support for reading LAME header delay and padding fields for proper ↵Thom Johansen2-5/+29
gapless MP3 support. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@6689 a1c6a512-1295-4272-9138-f99709370657