diff options
author | Michael Sevakis <jethead71@rockbox.org> | 2011-01-07 05:17:28 +0000 |
---|---|---|
committer | Michael Sevakis <jethead71@rockbox.org> | 2011-01-07 05:17:28 +0000 |
commit | 39107956ab680b37ade979e5379cf98a06604b13 (patch) | |
tree | 156c4197b5ad0d99c165e07d81da7a3e1d3671b1 /apps/plugins/mpegplayer/mpegplayer.h | |
parent | b1a1831a17b17574b8a201dfcb348714772068b8 (diff) | |
download | rockbox-39107956ab680b37ade979e5379cf98a06604b13.tar.gz rockbox-39107956ab680b37ade979e5379cf98a06604b13.zip |
MPEGPlyaer: A bit of audio mutation. Remove a useless thread state. Take some control over the buffer away from the audio thread itself. Some atomicity corrections.
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@28984 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'apps/plugins/mpegplayer/mpegplayer.h')
-rw-r--r-- | apps/plugins/mpegplayer/mpegplayer.h | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/apps/plugins/mpegplayer/mpegplayer.h b/apps/plugins/mpegplayer/mpegplayer.h index 79c25f6109..7333d87d6e 100644 --- a/apps/plugins/mpegplayer/mpegplayer.h +++ b/apps/plugins/mpegplayer/mpegplayer.h | |||
@@ -51,14 +51,13 @@ | |||
51 | /* Define this as "1" to have a test tone instead of silence clip */ | 51 | /* Define this as "1" to have a test tone instead of silence clip */ |
52 | #define SILENCE_TEST_TONE 0 | 52 | #define SILENCE_TEST_TONE 0 |
53 | 53 | ||
54 | /* NOTE: Sizes make no frame header allowance when considering duration */ | ||
54 | #define PCMOUT_BUFSIZE (CLOCK_RATE/2*4) /* 1/2s */ | 55 | #define PCMOUT_BUFSIZE (CLOCK_RATE/2*4) /* 1/2s */ |
55 | #define PCMOUT_GUARD_SAMPLES ((CLOCK_RATE*576+7999)/8000) /* Worst upsampling case */ | 56 | #define PCMOUT_GUARD_SIZE (PCMOUT_BUFSIZE) /* guarantee contiguous sizes */ |
56 | #define PCMOUT_GUARD_SIZE (PCMOUT_GUARD_SAMPLES*4 + sizeof (struct pcm_frame_header)) | ||
57 | #define PCMOUT_ALLOC_SIZE (PCMOUT_BUFSIZE + PCMOUT_GUARD_SIZE) | 57 | #define PCMOUT_ALLOC_SIZE (PCMOUT_BUFSIZE + PCMOUT_GUARD_SIZE) |
58 | /* Start pcm playback @ 25% full */ | 58 | /* Start pcm playback @ 25% full */ |
59 | #define PCMOUT_PLAY_WM (PCMOUT_BUFSIZE/4) | 59 | #define PCMOUT_PLAY_WM (PCMOUT_BUFSIZE/4) |
60 | /* No valid audio frame is smaller */ | 60 | #define PCMOUT_LOW_WM (0) |
61 | #define PCMOUT_LOW_WM (sizeof (struct pcm_frame_header)) | ||
62 | 61 | ||
63 | /** disk buffer **/ | 62 | /** disk buffer **/ |
64 | #define DISK_BUF_LOW_WATERMARK (1024*1024) | 63 | #define DISK_BUF_LOW_WATERMARK (1024*1024) |