aboutsummaryrefslogtreecommitdiffstats
path: root/src/audioOutputs/audioOutput_pulse.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* audio_format: renamed sampleRate to sample_rateMax Kellermann2008-10-101-2/+2
| | | | | The last bit of CamelCase in audio_format.h. Additionally, rename a bunch of local variables.
* use C99 struct initializersMax Kellermann2008-09-291-9/+8
| | | | | | The old struct initializers are error prone and don't allow moving elements around. Since we are going to overhaul some of the APIs soon, it's easier to have all implementations use C99 initializers.
* output: make "struct audio_output" opaque for output pluginsMax Kellermann2008-09-241-26/+32
| | | | | | | | | | | We have eliminated direct accesses to the audio_output struct from the all output plugins. Make it opaque for them, and move its real declaration to output_internal.h, similar to decoder_internal.h. Pass the opaque structure to plugin.init() only, which will return the plugin's data pointer on success, and NULL on failure. This data pointer will be passed to all other methods instead of the audio_output struct.
* output: set audio_output->open=1 in audio_output_task()Max Kellermann2008-09-241-3/+0
| | | | | Since the output plugin returns a value indicating success or error, we can have the output core code assign the "open" flag.
* output: pass audio_format to plugin.init() and plugin.open()Max Kellermann2008-09-241-3/+3
| | | | | | | Pass the globally configured audio_format as a const pointer to plugin.init(). plugin.open() gets a writable pointer which contains the audio_format requested by the plugin. Its initial value is either the configured audio_format or the input file's audio_format.
* output: const plugin structuresMax Kellermann2008-09-081-1/+1
| | | | | Since the plugin struct is never modified, we should store it in constant locations.
* output: renamed typedef AudioOutput to struct audio_outputMax Kellermann2008-09-071-7/+8
| | | | | Also rename AudioOutputPlugin to struct audio_output_plugin, and use forward declarations to reduce include dependencies.
* output: added output_api.hMax Kellermann2008-09-071-3/+2
| | | | | Just like decoder_api.h, output_api.h provides the audio output API which is used by the plugins.
* audio_format: converted typedef AudioFormat to struct audio_formatMax Kellermann2008-09-071-1/+1
| | | | | Get rid of CamelCase, and don't use a typedef, so we can forward-declare it, and unclutter the include dependencies.
* use size_t and constant pointer in ao pluginsMax Kellermann2008-04-121-1/+2
| | | | | | | The audio output plugins should get a constant pointer, because they must not modify the buffer. Since the size is a non-negative buffer size in bytes, we should change its type to size_t. git-svn-id: https://svn.musicpd.org/mpd/trunk@7293 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Cleanup #includes of standard system headers and put them in one placeEric Wong2008-01-031-5/+1
| | | | | | | | | | | | | This will make refactoring features easier, especially now that pthreads support and larger refactorings are on the horizon. Hopefully, this will make porting to other platforms (even non-UNIX-like ones for masochists) easier, too. os_compat.h will house all the #includes for system headers considered to be the "core" of MPD. Headers for optional features will be left to individual source files. git-svn-id: https://svn.musicpd.org/mpd/trunk@7130 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* The massive copyright updateAvuton Olrich2007-04-051-1/+1
| | | git-svn-id: https://svn.musicpd.org/mpd/trunk@5834 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Replace strdup and {c,re,m}alloc with x* variants to check for OOM errorsEric Wong2006-08-261-3/+3
| | | | | | | | | | | | | | | | | | | I'm checking for zero-size allocations and assert()-ing them, so we can more easily get backtraces and debug problems, but we'll also allow -DNDEBUG people to live on the edge if they wish. We do not rely on errno when checking for OOM errors because some implementations of malloc do not set it, and malloc is commonly overridden by userspace wrappers. I've spent some time looking through the source and didn't find any obvious places where we would explicitly allocate 0 bytes, so we shouldn't trip any of those assertions. We also avoid allocating zero bytes because C libraries don't handle this consistently (some return NULL, some not); and it's dangerous either way. git-svn-id: https://svn.musicpd.org/mpd/trunk@4690 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* audioOutput_pulse: ansi-fy function declarations (sparse)Eric Wong2006-08-081-2/+2
| | | git-svn-id: https://svn.musicpd.org/mpd/trunk@4599 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* #include <string.h> in PulseAudio output for correctnessJ. Alexander Treuman2006-07-201-0/+1
| | | git-svn-id: https://svn.musicpd.org/mpd/trunk@4412 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Add mpd-indent.shAvuton Olrich2006-07-201-3/+3
| | | | | | Add a few new options for indent to try to make things a bit cleaner git-svn-id: https://svn.musicpd.org/mpd/trunk@4411 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Add mpd-indent.shAvuton Olrich2006-07-201-33/+34
| | | | | | Indent the entire tree, hopefully we can keep it indented. git-svn-id: https://svn.musicpd.org/mpd/trunk@4410 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* s/ad/pd/ in the PluseAudio plugin (I forgot to rename when copying from alsa)J. Alexander Treuman2006-07-191-31/+31
| | | git-svn-id: https://svn.musicpd.org/mpd/trunk@4404 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Throttle PuleAudio connection attempts so we don't spam the error logJ. Alexander Treuman2006-07-191-5/+24
| | | git-svn-id: https://svn.musicpd.org/mpd/trunk@4403 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Use audio_output { name } for the stream name in PulseAudio, but do it The ↵J. Alexander Treuman2006-07-141-7/+2
| | | | | Right Way git-svn-id: https://svn.musicpd.org/mpd/trunk@4342 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Use audio_output { name } for the stream name in PulseAudioJ. Alexander Treuman2006-07-141-4/+8
| | | git-svn-id: https://svn.musicpd.org/mpd/trunk@4340 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Change shank's email addressJ. Alexander Treuman2006-07-141-1/+1
| | | git-svn-id: https://svn.musicpd.org/mpd/trunk@4333 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Use a macro to declare disabled audio output pluginsJ. Alexander Treuman2006-07-141-11/+1
| | | git-svn-id: https://svn.musicpd.org/mpd/trunk@4321 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Huge header update, update the copyright and addAvuton Olrich2006-07-131-0/+18
| | | | | the GPL header where necessary git-svn-id: https://svn.musicpd.org/mpd/trunk@4317 09075e82-0dd4-0310-85a5-a0d7c8717e4f
* Add PulseAudio supportJ. Alexander Treuman2006-07-131-0/+193
git-svn-id: https://svn.musicpd.org/mpd/trunk@4316 09075e82-0dd4-0310-85a5-a0d7c8717e4f