summaryrefslogtreecommitdiff
path: root/apps/playback.c (follow)
Commit message (Collapse)AuthorAge
...
* Reload the current playlist after reboot even if it has ended. (FS#11644)Frank Gevaerts2011-07-31
| | | | | | | This is done to make reboot more transparent. If a playlist has ended, there should be no difference between the player doing nothing for ten minutes and the player shutting down after the idle timeout and being restarted. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30226 a1c6a512-1295-4272-9138-f99709370657
* The voice PCM buffer has nothing to do with the playback PCM buffer any ↵Michael Sevakis2011-07-09
| | | | | | longer. Allocate it independently from the playback engine's PCM buffer and only when voice is required. Additionally, allocate actual space for the crossfade buffer only when using crossfade. Will save 18.3KB when neither is needed (10.3KB for voice and 8.0KB for crossfade). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30133 a1c6a512-1295-4272-9138-f99709370657
* Have mpegplayer use the mixer (the playback channel, since it's mutually ↵Michael Sevakis2011-07-08
| | | | | | exclusive to audio playback) so the clicks and skip beep can be used according to user settings. Introduce some system sound functions to make easier playing event sounds from various places and convert files calling 'beep_play' to use 'system_sound_play' and 'keyclick_click'. Event sound could be become themeable. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30130 a1c6a512-1295-4272-9138-f99709370657
* Commit FS#12150 - Fully-functional audio mixer - and finally whip old ↵Michael Sevakis2011-06-29
| | | | | | limitations about playback of voice and other sounds when paused. Channels are independent in state and amplitude. Fade on stop/pause is handled by the channel's volume control rather than global volume which means it now works from anywhere. Opens up the possibility of plugin sounds during music playback by merely adding an additional channel enum. If any PCM drivers were not properly modified, see one of the last comments in the task for a description of the simple change that is expected. Some params are tunable in firmware/export/pcm-mixer.h as well. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30097 a1c6a512-1295-4272-9138-f99709370657
* Workaround an occasional problem where album art or cuesheets might not be ↵Michael Sevakis2011-05-25
| | | | | | ready by the time the track change event is send which can result in the WPS not immediately being aware that the handles are ready. A better solution will be sought that hopefully doesn't require the additional event. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29923 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#12118 - Voice UI has issues talking various issues in menus and in ↵Michael Sevakis2011-05-20
| | | | | | the file browswer. audio_pcmbuf_may_play should check play_status for !=PLAY_PAUSED, not ==PLAY_PLAYING so that PCM may auto-start when voicing out playback state. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29904 a1c6a512-1295-4272-9138-f99709370657
* Fix whitespace and some comment typosJeffrey Goode2011-05-09
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29850 a1c6a512-1295-4272-9138-f99709370657
* Hopefully fix red from r29785 - an #ifdef AB_REPEAT_ENABLE was left out.Michael Sevakis2011-04-27
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29786 a1c6a512-1295-4272-9138-f99709370657
* Commit FS#12069 - Playback rework - first stages. Gives as thorough as ↵Michael Sevakis2011-04-27
| | | | | | 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
* Fix red and yellow. Move resume_index from mp3entry to playlist_info struct. ↵Andree Buschmann2011-04-07
| | | | | | Bump codec api. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29691 a1c6a512-1295-4272-9138-f99709370657
* Fix regressions of r29682. Update playlist index resume position when ↵Andree Buschmann2011-04-07
| | | | | | playlist changes (e.g. shuffling, inserting, removing, ...). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29690 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#12043. Next track was resumed when pausing and shutting down the ↵Andree Buschmann2011-04-06
| | | | | | player in the last seconds of a track. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29682 a1c6a512-1295-4272-9138-f99709370657
* Fixed a typo. (Thanks Jeff!)Björn Stenberg2011-03-14
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29587 a1c6a512-1295-4272-9138-f99709370657
* Listen to and follow external Android volume changes. (Based on FS#11914 by ↵Björn Stenberg2011-03-14
| | | | | | Maurus Cuelenaere) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29586 a1c6a512-1295-4272-9138-f99709370657
* Remove malloc_buf references from playback.c since it's no longer used for ↵Michael Sevakis2011-03-06
| | | | | | anything and align the codec slack space buffer that is now use as the malloc buffer. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29533 a1c6a512-1295-4272-9138-f99709370657
* autoresume: Optimize playlist resume (manual, bookmark, or after power-on)Michael Hohmuth2011-02-28
| | | | | | | | | The resume position coming from these sources takes precedence over autoresume. If we have such a resume offset, we don't have to wait for the database to produce a resume offset before we can start the codec. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29470 a1c6a512-1295-4272-9138-f99709370657
* Give playback engine better control over the codec. Codec simply follows ↵Michael Sevakis2011-02-23
| | | | | | 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
* FS#11933: Check for external album art if embedded album art fails to load.Magnus Holmgren2011-02-16
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29319 a1c6a512-1295-4272-9138-f99709370657
* Always do proper mp3entry copying instead of using bufread directly. Add ↵Michael Sevakis2011-02-10
| | | | | | bufreadid3() helper. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29279 a1c6a512-1295-4272-9138-f99709370657
* audio_peek_track should copy the struct mp3entry instead of pointing ↵Michael Sevakis2011-02-10
| | | | | | directly into the buffer. Despite the dire warning, caller does in fact yield/sleep and its usage is too nonlocalized to control that reliably. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29275 a1c6a512-1295-4272-9138-f99709370657
* Disable buffering codecs (and code generally) on RaaA.Thomas Martitz2011-02-09
| | | | | | | It's not useful to do it since you need to write back the code to disk to be able to load it from memory, it also requires writing to an executable directory. Keep it for the simulator for the sake of simulating. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29261 a1c6a512-1295-4272-9138-f99709370657
* Embedded album art support in MP3/ID3v2 tags.Thomas Martitz2011-02-09
| | | | | | | | | | | - Support is limited to non-desync jpeg in id3v2 tags. Other formats (hopefully) follow in the future. - Embedded album art takes precedence over files in album art files. - No additional buffers are used, the jpeg is read directly from the audio file. Flyspray: FS#11216 Author: Yoshihisa Uchida and I git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29259 a1c6a512-1295-4272-9138-f99709370657
* Add option to resume next track on automatic track changeMichael Hohmuth2011-02-08
| | | | | | | | | Move autoresume setting into its own menu. Add option to customize which tracks should be resumed on automatic track change. Tracks can be selected based on their their file location or genre tag (comma-separated list of filename / genre substrings). git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29251 a1c6a512-1295-4272-9138-f99709370657
* Do not update resume information and do not log statistics when aMichael Hohmuth2011-02-08
| | | | | | | | | | | | | | | | | | | | | | | | | | track is interrupted within the first 15 seconds. Regard a rewind to 0:00 as a track restart (updating resume position / playback statistics before the rewind and starting the 15 s delay). This allows skipping forward across an unplayed track without changing its resume offset. Also, it is possible to skip backward to the previous track after rewinding to the current track to 0:00 (pressing Left twice) without losing the current track's resume position. Initially contributed by Dave Slusher Caveats: * Works only for SWCODEC * Skipping forward without altering the resume position does not work when skip to outro has been turned on. * The 15-second window in which the resume offset will not be updated should start at the initial resume position, not at 0:00. This would allow skipping over partially played tracks without altering the resume position. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@29250 a1c6a512-1295-4272-9138-f99709370657
* Commit part of FS#11748 by Michael Hohmuth. Adds support for automatically ↵Michael Giacomelli2011-01-02
| | | | | | resuming any song that is not played to completion at any point later in time, regardless of how many intermediate tracks are played. This is accomplished by expanding the database to record incompletely played tracks. Currently, the feature is simply on or off, in which case all tracks automatically resume, or they do not. The remainder of patches in the task expand this feature by allowing only certain file to automatically resume, only resuming in certain circumstances, etc but are not included until we reach agreement on what should be included. Additionally, the manual will need to be updated once we agree on the available settings. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28942 a1c6a512-1295-4272-9138-f99709370657
* Accept FS#11721 by Michael HohmuthJonathan Gordon2010-11-23
| | | | | | | Fix Runtime statistics data not gathered when playback stops git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28644 a1c6a512-1295-4272-9138-f99709370657
* don't cast to int when not neededRafaël Carré2010-08-30
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27954 a1c6a512-1295-4272-9138-f99709370657
* panicf() is declared in panic.hRafaël Carré2010-08-30
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27952 a1c6a512-1295-4272-9138-f99709370657
* audio_reset_buffer: check audiobuffer size not only in DEBUG buildsRafaël Carré2010-08-30
| | | | | | | (DEBUG builds do not work/build anyway) Also use a shorter message git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27951 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#11175. playlist_peek() wasn't thread safe (due to a static filename ↵Magnus Holmgren2010-08-11
| | | | | | buffer), so frequent calls from the main thread would cause the audio thread to buffer the wrong track. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27773 a1c6a512-1295-4272-9138-f99709370657
* playback.c: don't assume cacheline size is 16 bytesRafaël Carré2010-06-23
| | | | | | | | | | ideally all targets should define CACHEALIGN_BITS, for now we default it to 16 bytes if it's not specified Since the buffer is already aligned in playback.c no need to align it again in buffering.c git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27073 a1c6a512-1295-4272-9138-f99709370657
* Rockbox as an application: Replace many occurences of #ifdef SIMULATOR with ↵Thomas Martitz2010-06-21
| | | | | | | | | | | #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
* Change cuesheet handling so the id3 info is not spoofed anymore. If ↵Jonathan Gordon2010-06-06
| | | | | | something wants the subtracks info it is easy to get to. This makes next track display in the skins show the next subtrack if we are in a cuesheet git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26611 a1c6a512-1295-4272-9138-f99709370657
* FS#11263 - Radio Art support! %C and %Cl tags work in the radio screen and ↵Jonathan Gordon2010-05-16
| | | | | | | | | Base Skin when the radio is running. put your station images in .rockbox/fmpresets/<preset name>.bmp or .jpg. Must be in preset mode and the preset name must match the filename git-svn-id: svn://svn.rockbox.org/rockbox/trunk@26078 a1c6a512-1295-4272-9138-f99709370657
* FS#10853 - Skin support in the radio screen! Check CustomWPS for the new tagsJonathan Gordon2010-05-12
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25964 a1c6a512-1295-4272-9138-f99709370657
* FS#11099 - Rewind before resumeMagnus Holmgren2010-04-24
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25706 a1c6a512-1295-4272-9138-f99709370657
* drop the playlist viewer stack usage by reading straiught off the buffer ↵Jonathan Gordon2010-04-17
| | | | | | instead of copying it. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25661 a1c6a512-1295-4272-9138-f99709370657
* Minor clean up in playback.cAndree Buschmann2010-03-14
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25178 a1c6a512-1295-4272-9138-f99709370657
* Implement resume for alac codec.Andree Buschmann2010-03-14
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25169 a1c6a512-1295-4272-9138-f99709370657
* Make the buffer low-level watermark (and the related anti-skip setting) work ↵Magnus Holmgren2010-02-28
| | | | | | again. Update the buffering 'base handle' as new tracks start playing, since this is needed to determine how much playable data is left in the buffer. Should fix the buffering problem reported in the forums (http://forums.rockbox.org/index.php?topic=24014.0), and also makes the usefl line in the buffering thread debug screen useful again. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24968 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#11004 - Buffering crashes when skipping back from end of song.Thomas Martitz2010-02-18
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24755 a1c6a512-1295-4272-9138-f99709370657
* Get rid of those horrible macros to protect against NULL reference when ↵Jonathan Gordon2010-01-15
| | | | | | | | | looking up the id3 info for tokens. Change the way the wps playlist viewer gets the token values. All %i tokens are now supported (and a few others, experiment :) ) git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24233 a1c6a512-1295-4272-9138-f99709370657
* FS#10898 - Add a playlist viewer to the WPS. ↵Jonathan Gordon2010-01-13
| | | | | | http://www.rockbox.org/wiki/CustomWPS#Playlist_viewer for an exaplanation how to use it. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@24220 a1c6a512-1295-4272-9138-f99709370657
* Commit FS#10605 - stable playback on low memory swcodec targets by Matthias ↵Michael Giacomelli2009-11-21
| | | | | | Schneider. Should allow stable playback on targets with less then 4MB of RAM and sofware decoding such as the Sandisk Clip, c200v2, m200v4 and probably others. Fixes several problems in buffering that occured when the files to be buffered weren't much smaller then the ring buffer size. Fixes a bug where move_handle would corrupt the audio buffer when trying to copy a handle that both wrapped around the highest address in the ring buffer and overlapped part of the source and desination ranges. Moves the decision in playback.c about when to update the current track handle from audio_check_new_track to after the metadata has been buffered. Corrects several other minor pieces of code. I've logged about 100 hours without a crash on various players with this patch but its possible it breaks some combination of players and features I haven't thought to test. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23680 a1c6a512-1295-4272-9138-f99709370657
* Cleanup audio.h, related functionsJeffrey Goode2009-11-16
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23651 a1c6a512-1295-4272-9138-f99709370657
* pcmbuf cleanupJeffrey Goode2009-11-16
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23649 a1c6a512-1295-4272-9138-f99709370657
* Crossfade: added a new option, rewrote decision logic, updated manual and ↵Jeffrey Goode2009-11-11
| | | | | | menus. Translators please note that updated translations may be required for some crossfade menu items! git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23605 a1c6a512-1295-4272-9138-f99709370657
* Crossfade: carved out crossfade related code with lots of HAVE_CORSSFADE ↵Jeffrey Goode2009-11-10
| | | | | | conditionals, eliminated fade buffer on low memory targets git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23597 a1c6a512-1295-4272-9138-f99709370657
* Playback: removed duplicate functionsJeffrey Goode2009-11-09
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23576 a1c6a512-1295-4272-9138-f99709370657
* pcmbuf: clarify and simplify crossfade code, etc.Jeffrey Goode2009-11-05
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@23538 a1c6a512-1295-4272-9138-f99709370657