summaryrefslogtreecommitdiff
path: root/apps/playback.c (follow)
Commit message (Collapse)AuthorAge
...
* No need to have \n here. panicf() won't output it anyway.Jens Arnold2008-03-08
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16570 a1c6a512-1295-4272-9138-f99709370657
* Simplified the playback engine more and removed unnecessary code.Miika Pekkarinen2008-03-08
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16552 a1c6a512-1295-4272-9138-f99709370657
* Rewritten playback event handling. Should fix runtime statistics gathering.Miika Pekkarinen2008-03-07
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16546 a1c6a512-1295-4272-9138-f99709370657
* Pragmatic fix for FS#8681 (logf breaks scrobbling). The correct fix is a ↵Nicolas Pennequin2008-03-04
| | | | | | better event mechanism but scrobbling is currently the only track_changed_event consumer so I'll wait til I have more time. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16520 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#8675: Last song in playlist ends prematurely.Magnus Holmgren2008-03-04
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16518 a1c6a512-1295-4272-9138-f99709370657
* Slightly simpler mechanism to avoid Q_AUDIO_FILL_BUFFER floods.Steve Bavin2008-03-03
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16497 a1c6a512-1295-4272-9138-f99709370657
* Fix odd behaviour when rebuffering occurs during playback. This is ↵Steve Bavin2008-02-29
| | | | | | hopefully the last nail in the coffins of FS#8455 and FS#8513, but I'll let some FLAC and Ogg users be the judge of that. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16459 a1c6a512-1295-4272-9138-f99709370657
* Use a safe way to get pcm buffer track change notifications to the audio thread.Michael Sevakis2008-02-28
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16450 a1c6a512-1295-4272-9138-f99709370657
* Fix bookmark resume when a track is playing.Magnus Holmgren2008-02-28
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16445 a1c6a512-1295-4272-9138-f99709370657
* Fix auto dir change happening one track too early (another followup of r16425).Nicolas Pennequin2008-02-26
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16430 a1c6a512-1295-4272-9138-f99709370657
* Fix not being able to skip to the last track in a playlist.Nicolas Pennequin2008-02-26
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16426 a1c6a512-1295-4272-9138-f99709370657
* Attempt to make manual track skips more responsive and more robustNicolas Pennequin2008-02-26
| | | | | | | | | | * Immediately update the playlist index on manual track skip * Try to minimise the number of calls to audio_fill_file_buffer Hopefully fixes FS#8320. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16425 a1c6a512-1295-4272-9138-f99709370657
* Factor out duplicate code from audio_prev and audio_nextNicolas Pennequin2008-02-26
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16424 a1c6a512-1295-4272-9138-f99709370657
* Make audio_next_track use the wps_offset value.Nicolas Pennequin2008-02-26
| | | | | | | This removes the delay between the current track title change and the next track title change in the WPS on a track skip. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16423 a1c6a512-1295-4272-9138-f99709370657
* When starting playback, prevent the codec from starting to decode too early, ↵Magnus Holmgren2008-02-23
| | | | | | which would cause rebuffering (slowing things down) and incorrect playlist index. Hopefully fixes a bunch of playback-related bugs, such as FS#8520, FS#8525, FS#8555 and possibly FS#8511. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16392 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#5797 (Codec failure with directory skip when in file browser, with ↵Nicolas Pennequin2008-01-09
| | | | | | | | | dircache enabled). Marking the tree context to be reloaded too early would cause the new playlist to contain files that don't exist (correct directory but wrong filenames), in turn causing the codec failures. The fix is to call reload_directory() after the playlist has been created. I also added a sanity check to avoid loading an unknown codec, which was happening as a consequence of this issue. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16039 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#6215 (player crashes after trying to resume deleted music file). As ↵Nicolas Pennequin2008-01-08
| | | | | | mentioned in the lastest comment, the problem was in trying to resume at an offset larger than the size of the file following the one that was deleted. This revealed a crash in the buffering code, which gets a fix, but we also need to intervene earlier in the track loading so that the track that gets played will be from its start. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16028 a1c6a512-1295-4272-9138-f99709370657
* Take out some no longer needed (and overly complicated) comments, thanks to ↵Brandon Low2008-01-08
| | | | | | Nico_P git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16027 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#2687 (Rewinding at end of song confuses playback) by making the codec ↵Nicolas Pennequin2008-01-08
| | | | | | skip back if the user seeks during the transition window. This also completely fixes the small glitch in the progressbar when a user skipped back to a buffered song. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16025 a1c6a512-1295-4272-9138-f99709370657
* Make the playlist index be incremented after the PCM track change. This ↵Nicolas Pennequin2008-01-07
| | | | | | fixes FS#8206. Special treatment is required to avoid breaking auto dir change. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@16019 a1c6a512-1295-4272-9138-f99709370657
* Fix FS8069, because Nico_P made it easyBrandon Low2007-11-28
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15840 a1c6a512-1295-4272-9138-f99709370657
* Buffering callbacks rework. There is now one callback for all the events ↵Nicolas Pennequin2007-11-26
| | | | | | | | | that can occur. Callbacks are now registred only once instead of being removed after having been called. Fix FS#8092 by flushing the audio when a rebuffer is needed. Also add some comments here and there. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15816 a1c6a512-1295-4272-9138-f99709370657
* Commit FS#7440. The iPod Video doesn't actually have a hardware equalizer. ↵Dan Everton2007-11-24
| | | | | | It does have hardware bass/treble settings with configurable cutoff. So make the bass/treble settings use the hardware and remove the hardware equalizer configuration. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15782 a1c6a512-1295-4272-9138-f99709370657
* revise commit r15463 - we still get the immediate display of runtime data in ↵Robert Kukla2007-11-23
| | | | | | the wps, but avoid unnecessary calls while initialising/updating the database. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15781 a1c6a512-1295-4272-9138-f99709370657
* Save runtime info for last track in playlist as well (FS#8040)Robert Kukla2007-11-23
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15767 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#8201 and correct fix for FS#8040 by making the track unbuffer ↵Nicolas Pennequin2007-11-22
| | | | | | callback be called from where it should be: clear_track_info, and writing track metadata back to the main buffer *before* the callback is called and the track erased. This simplifies audio_clear_track_entries. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15748 a1c6a512-1295-4272-9138-f99709370657
* Hopefully the last word on getting rid of yield_codecs loops (cut read chunk ↵Michael Sevakis2007-11-20
| | | | | | to 16kB). Sansa ata driver also didn't yield enough so buffering would starve other threads. Bump priority of audio thread to keep UI more responsive. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15724 a1c6a512-1295-4272-9138-f99709370657
* Make threads responsible for explicit cancellation of their own boosted ↵Michael Sevakis2007-11-20
| | | | | | status. Sleeping and timeouts will no longer cancel it. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15709 a1c6a512-1295-4272-9138-f99709370657
* Fix FS#8040 (Gather Runtime Data not working) the right way. Also a few ↵Nicolas Pennequin2007-11-19
| | | | | | cosmetic changes and comments. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15696 a1c6a512-1295-4272-9138-f99709370657
* Second part of FS#8104 by Bertrik Sikken: Simplification of ↵Nicolas Pennequin2007-11-19
| | | | | | audio_track_count, audio_have_tracks and audio_have_free_tracks. This hopefully won't affect anything, but the semantics of the functions have changed slightly. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15693 a1c6a512-1295-4272-9138-f99709370657
* First part of FS#8104 by Bertrik Sikken: Simplification and consistency ↵Nicolas Pennequin2007-11-19
| | | | | | improvement for the track index incrementations. There should be no functional change. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15688 a1c6a512-1295-4272-9138-f99709370657
* Do the wait for the audio thread init in such a way to avoid an unlikely but ↵Michael Sevakis2007-11-19
| | | | | | possible roundabout deadlock. Not pretty but will suffice for the moment. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15686 a1c6a512-1295-4272-9138-f99709370657
* Make sure initial menu item is voiced at startup. Voice thread must wait for ↵Michael Sevakis2007-11-19
| | | | | | the audio thread to finish initializing hardware. A known issue at speex commit time (perhaps only by myself ;). The behavioral refinement time begins. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15682 a1c6a512-1295-4272-9138-f99709370657
* Make speex the new voice format for SWCODEC targets (non-Archos). Remove ↵Michael Sevakis2007-11-18
| | | | | | 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
* Erase lasttrack_id3 when end-of-playlist is reached. Fixes FS#8148.Nicolas Pennequin2007-11-18
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15659 a1c6a512-1295-4272-9138-f99709370657
* I'm a retard, this is definitely more correctBrandon Low2007-11-14
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15627 a1c6a512-1295-4272-9138-f99709370657
* Might fix FS#8158, I was unable to reproduce so no guarantee.Brandon Low2007-11-14
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15626 a1c6a512-1295-4272-9138-f99709370657
* Fix another NULL pointer dereference crash.Nicolas Pennequin2007-11-12
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15591 a1c6a512-1295-4272-9138-f99709370657
* Fix an issue that appeared in r15577, where skipping back to a track that ↵Nicolas Pennequin2007-11-11
| | | | | | | | has no audio data left, but still has its metadata and album art, would fail. The fix is to also clear the filesize member (as it should have been previously) to force a rebuffer when skipping back. To prevent the album art bitmap from flashing on the back skip, the whole track info struct is cleared when the track isn't needed anymore, i.e. after the PCM track change. Also a slightly unrelated but trivial change: only load album art if it's not already loaded. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15588 a1c6a512-1295-4272-9138-f99709370657
* Load the album art before the codec because find_albumart would yield to the ↵Nicolas Pennequin2007-11-11
| | | | | | codec, which would start requesting data before the audio handle is ready. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15584 a1c6a512-1295-4272-9138-f99709370657
* * Make the album art be updated on PCM track change, not codec track change ↵Nicolas Pennequin2007-11-11
| | | | | | | | | | (changes in audio_current_aa_hid). * On codec track change, if not all the audio data is present, only get rid of the audio data and not all the track's handles. This will prevent alum art from disappearing on codec track change after resuming playback (changes in audio_check_new_track). * Add audio_finalise_track_change() to handle what happens after the PCM track change (no functional change here). * Add some comments about how the track transition works. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15577 a1c6a512-1295-4272-9138-f99709370657
* Fix red.Nicolas Pennequin2007-11-11
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15573 a1c6a512-1295-4272-9138-f99709370657
* Album art support. Based on FS#3045, but heavily modified to adapt to MoB ↵Nicolas Pennequin2007-11-11
| | | | | | | | | | | | and for cleanness. The cover pictures are loaded from external bitmaps. JPEG and embedded art are not supported. The pictures will only be drawn on the main display. There is no resizing but it is possible to specify the WPS bitmap size in the bitmap names (e.g. cover.100x100.bmp). The bitmaps are stored in the main buffer and read directly from there. Currently, duplicate bitmaps will simply be present several times in the buffer, but this will be improved. To enable for a target, #define HAVE_ALBUMART in its config file. For more information, see the wiki page: http://www.rockbox.org/wiki/AlbumArt. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15572 a1c6a512-1295-4272-9138-f99709370657
* Fix a possible NULL pointer dereference I introduced in r15503 by making an ↵Nicolas Pennequin2007-11-10
| | | | | | unwise assumption. This would cause crashes on track skip in certain (very unlikely, I think) situations. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15557 a1c6a512-1295-4272-9138-f99709370657
* Remove nexttrack_id3 and instead use the metadata present on the buffer.Nicolas Pennequin2007-11-08
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15540 a1c6a512-1295-4272-9138-f99709370657
* Store the metadata of the first unbuffered track in a static struct so that ↵Nicolas Pennequin2007-11-08
| | | | | | it gets displayed in the next track info while playing the last buffered track. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15539 a1c6a512-1295-4272-9138-f99709370657
* Fix warning.Nicolas Pennequin2007-11-07
| | | | git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15504 a1c6a512-1295-4272-9138-f99709370657
* Fix tracks always being cleared on skip (reported by dionoea). The problem ↵Nicolas Pennequin2007-11-07
| | | | | | was that skipping the ID3 info from the beginning caused the offset to always be nonzero. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15503 a1c6a512-1295-4272-9138-f99709370657
* Don't keep resetting to default watermark during buffering, only do it once ↵Brandon Low2007-11-05
| | | | | | at play start git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15485 a1c6a512-1295-4272-9138-f99709370657
* Set all track handles to -1 on audio init to avoid calling bufclose(0) on ↵Nicolas Pennequin2007-11-05
| | | | | | all of them on the first playback stop. This also revealed a bug in audio_release_tracks where it wouldn't release all the tracks because the wrong #define value was used. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@15484 a1c6a512-1295-4272-9138-f99709370657