Max Kellermann
e726e2a004
music_pipe: removed music_pipe_append()
...
The function is unused, since decoder_api() uses music_pipe_write() /
music_pipe_expand() now.
2009-01-17 13:11:11 +01:00
Max Kellermann
fd948571f8
music_pipe: added functions music_pipe_write() and music_pipe_expand()
...
This new API gives the caller a writable buffer to the music pipe
chunk. This may allow the caller to eliminate several buffer copies,
because it may manipulate the returned buffer, until it calls
music_pipe_expand().
2009-01-17 13:09:29 +01:00
Max Kellermann
63272d6888
music_pipe: narrowed assertion on chunk index
...
The chunk index passed to successor() must be valid, i.e. it must be
smaller than num_chunks.
2008-11-18 19:54:39 +01:00
Max Kellermann
709640422c
player: chop the tail of the music pipe after CANCEL
...
When a CANCEL command is received, the player should drop all chunks
of the next song. Added new funciton music_pipe_chop() which is used
for that.
2008-11-13 02:09:33 +01:00
Max Kellermann
66ce1495f0
music_pipe: continuously check the sample format of all chunks
...
Provide a debug function which asserts on the sample format of all
chunks. Call this function in each iteration of the player main loop.
2008-11-13 02:06:58 +01:00
Max Kellermann
1178e485cb
music_pipe: check for partial frames in appended chunk
...
Added an additional assertion which checks partial frames in the
existing tail chunk.
2008-11-13 02:06:52 +01:00
Max Kellermann
c7a374bdcb
music_pipe: add tag pointer to the music_chunk struct
...
Each music chunk can now carry a tag object. Decoder plugins which
support it (e.g. oggvorbis) may use this to inject decoded tags into
their output.
2008-11-02 17:01:00 +01:00
Max Kellermann
fcc11bc9d8
music_pipe: added functions chunk_init() and chunk_free()
...
These two functions will care about memory allocation and deallocation
in the future.
2008-11-02 16:58:49 +01:00
Max Kellermann
39bf84aa9f
music_pipe: renamed "size" to "num_chunks"
...
The name "num_chunks" expresses the meaning of the variable better.
2008-11-02 16:57:37 +01:00
Max Kellermann
5347cca29d
music_pipe: no CamelCase
...
Rename all variables and struct members.
2008-11-02 16:57:16 +01:00
Max Kellermann
8490c1b4cf
music_pipe: set bit_rate and time in music_pipe_append()
...
Don't bother to pass these values as parameters to tail_chunk().
2008-11-02 16:57:15 +01:00
Max Kellermann
cd61f6570f
music_pipe: moved code to music_chunk_append()
2008-11-02 16:56:49 +01:00
Max Kellermann
e9e9d2bc2d
music_pipe: renamed "ob" to "music_pipe"
...
Last music_pipe rename patch: renamed the global variable (singleton).
2008-11-02 16:56:09 +01:00
Max Kellermann
260a0cc33c
music_pipe: use GLib instead of utils.h
...
Eliminate the deprecated utils.h memory allocation functions.
2008-11-02 16:55:48 +01:00
Max Kellermann
8b1f6ff3c8
decoder: replaced music_pipe.audioFormat with dc.out_audio_format
...
.. and rename dc.audioFormat to dc.in_audio_format. The music pipe
does not need to know the audio format, and its former "audioFormat"
property indicated the format of the most recently added chunk, which
might be confusing when you are reading the oldest chunks.
2008-11-02 16:55:43 +01:00
Max Kellermann
30fca5e5a9
music_pipe: pass frame size to tail_chunk()
...
Don't make tail_chunk() calculate the frame size again.
2008-11-02 14:18:34 +01:00
Max Kellermann
fd0f195bb7
music_pipe: renamed ob_* functions to music_pipe_*
...
Rename all functions to the new prefix.
2008-11-02 14:18:34 +01:00
Max Kellermann
8964c69a64
music_pipe: renamed struct output_buffer to struct music_pipe
...
.. and rename ob_chunk to struct music_chunk.
2008-11-02 14:15:47 +01:00
Max Kellermann
767b4c95bd
renamed outputBuffer.[ch] to pipe.[ch]
...
No CamelCase in the file name. The output_buffer struct is going to
be renamed to music_pipe. There are so many buffer levels in MPD, and
calling this one "output buffer" is wrong, because it's not the last
buffer before the music reaches the output devices.
2008-11-02 14:12:52 +01:00