~diwic/ubuntu/lucid/pulseaudio/bugfixes

« back to all changes in this revision

Viewing changes to src/pulse/def.h

  • Committer: Bazaar Package Importer
  • Author(s): Sjoerd Simons
  • Date: 2009-07-28 14:00:27 UTC
  • mfrom: (1.5.1 upstream)
  • mto: (1.4.2 experimental)
  • mto: This revision was merged to the branch mainline in revision 65.
  • Revision ID: james.westby@ubuntu.com-20090728140027-wts8ya37tyrh4ww5
Tags: upstream-0.9.16~test2~20090726git59659e1db
ImportĀ upstreamĀ versionĀ 0.9.16~test2~20090726git59659e1db

Show diffs side-by-side

added added

removed removed

Lines of Context:
71
71
    PA_STREAM_UNCONNECTED,  /**< The stream is not yet connected to any sink or source */
72
72
    PA_STREAM_CREATING,     /**< The stream is being created */
73
73
    PA_STREAM_READY,        /**< The stream is established, you may pass audio data to it now */
74
 
    PA_STREAM_FAILED,       /**< An error occured that made the stream invalid */
 
74
    PA_STREAM_FAILED,       /**< An error occurred that made the stream invalid */
75
75
    PA_STREAM_TERMINATED    /**< The stream has been terminated cleanly */
76
76
} pa_stream_state_t;
77
77
 
109
109
 
110
110
/** Some special flags for contexts. */
111
111
typedef enum pa_context_flags {
112
 
    PA_CONTEXT_NOAUTOSPAWN = 1
 
112
    PA_CONTEXT_NOAUTOSPAWN = 0x0001U,
113
113
    /**< Disabled autospawning of the PulseAudio daemon if required */
 
114
    PA_CONTEXT_NOFAIL = 0x0002U
 
115
    /**< Don't fail if the daemon is not available when pa_context_connect() is called, instead enter PA_CONTEXT_CONNECTING state and wait for the daemon to appear.  \since 0.9.15 */
114
116
} pa_context_flags_t;
115
117
 
116
118
/** \cond fulldocs */
117
119
/* Allow clients to check with #ifdef for those flags */
118
120
#define PA_CONTEXT_NOAUTOSPAWN PA_CONTEXT_NOAUTOSPAWN
 
121
#define PA_CONTEXT_NOFAIL PA_CONTEXT_NOFAIL
119
122
/** \endcond */
120
123
 
121
124
/** The direction of a pa_stream object */
213
216
     * sink/device. Useful if you use any of the PA_STREAM_FIX_ flags
214
217
     * and want to make sure that resampling never takes place --
215
218
     * which might happen if the stream is moved to another
216
 
     * sink/source whith a different sample spec/channel map. Only
 
219
     * sink/source with a different sample spec/channel map. Only
217
220
     * supported when the server is at least PA 0.9.8. It is ignored
218
221
     * on older servers. \since 0.9.8 */
219
222
 
247
250
     * asking for less new data than this value will be made to the
248
251
     * client it will also guarantee that requests are generated as
249
252
     * early as this limit is reached. This flag should only be set in
250
 
     * very few situations where compatiblity with a fragment-based
 
253
     * very few situations where compatibility with a fragment-based
251
254
     * playback model needs to be kept and the client applications
252
255
     * cannot deal with data requests that are delayed to the latest
253
256
     * moment possible. (Usually these are programs that use usleep()
323
326
     * plus the playback buffer size is configured to this value. Set
324
327
     * PA_STREAM_ADJUST_LATENCY if you are interested in adjusting the
325
328
     * overall latency. Don't set it if you are interested in
326
 
     * configuring the server-sider per-stream playback buffer
 
329
     * configuring the server-side per-stream playback buffer
327
330
     * size. */
328
331
 
329
332
    uint32_t prebuf;
330
333
    /**< Playback only: pre-buffering. The server does not start with
331
 
     * playback before at least prebug bytes are available in the
 
334
     * playback before at least prebuf bytes are available in the
332
335
     * buffer. It is recommended to set this to (uint32_t) -1, which
333
336
     * will initialize this to the same value as tlength, whatever
334
337
     * that may be. Initialize to 0 to enable manual start/stop
349
352
 
350
353
    uint32_t fragsize;
351
354
    /**< Recording only: fragment size. The server sends data in
352
 
     * blocks of fragsize bytes size. Large values deminish
 
355
     * blocks of fragsize bytes size. Large values diminish
353
356
     * interactivity with other operations on the connection context
354
357
     * but decrease control overhead. It is recommended to set this to
355
358
     * (uint32_t) -1, which will initialize this to a value that is
389
392
    PA_ERR_NOEXTENSION,            /**< Extension does not exist. \since 0.9.12 */
390
393
    PA_ERR_OBSOLETE,               /**< Obsolete functionality. \since 0.9.15 */
391
394
    PA_ERR_NOTIMPLEMENTED,         /**< Missing implementation. \since 0.9.15 */
392
 
    PA_ERR_FORKED,                 /**< The caler forked without calling execve() and tried to reuse the context. \since 0.9.15 */
 
395
    PA_ERR_FORKED,                 /**< The caller forked without calling execve() and tried to reuse the context. \since 0.9.15 */
 
396
    PA_ERR_IO,                     /**< An IO error happened. \since 0.9.16 */
393
397
    PA_ERR_MAX                     /**< Not really an error but the first invalid error code */
394
398
};
395
399
 
487
491
    /**< Event type: Sample cache item */
488
492
 
489
493
    PA_SUBSCRIPTION_EVENT_SERVER = 0x0007U,
490
 
    /**< Event type: Global server change, only occuring with PA_SUBSCRIPTION_EVENT_CHANGE. */
 
494
    /**< Event type: Global server change, only occurring with PA_SUBSCRIPTION_EVENT_CHANGE. */
491
495
 
492
496
/** \cond fulldocs */
493
497
    PA_SUBSCRIPTION_EVENT_AUTOLOAD = 0x0008U,
573
577
    /**< Non-zero if the local and the remote machine have
574
578
     * synchronized clocks. If synchronized clocks are detected
575
579
     * transport_usec becomes much more reliable. However, the code
576
 
     * that detects synchronized clocks is very limited und unreliable
 
580
     * that detects synchronized clocks is very limited and unreliable
577
581
     * itself. */
578
582
 
579
583
    pa_usec_t sink_usec;
624
628
    /**< The configured latency for the sink. \since 0.9.11 */
625
629
 
626
630
    pa_usec_t configured_source_usec;
627
 
    /**< The configured latency for * the source. \since 0.9.11 */
 
631
    /**< The configured latency for the source. \since 0.9.11 */
628
632
 
629
633
    int64_t since_underrun;
630
634
    /**< Bytes that were handed to the sink since the last underrun
702
706
    /**< Volume can be translated to dB with pa_sw_volume_to_dB()
703
707
     * \since 0.9.11 */
704
708
 
705
 
    PA_SINK_FLAT_VOLUME = 0x0040U
 
709
    PA_SINK_FLAT_VOLUME = 0x0040U,
706
710
    /**< This sink is in flat volume mode, i.e. always the maximum of
707
711
     * the volume of all connected inputs. \since 0.9.15 */
 
712
 
 
713
    PA_SINK_DYNAMIC_LATENCY = 0x0080U
 
714
    /**< The latency can be adjusted dynamically depending on the
 
715
     * needs of the connected streams. \since 0.9.15 */
708
716
} pa_sink_flags_t;
709
717
 
710
718
/** \cond fulldocs */
715
723
#define PA_SINK_HW_MUTE_CTRL PA_SINK_HW_MUTE_CTRL
716
724
#define PA_SINK_DECIBEL_VOLUME PA_SINK_DECIBEL_VOLUME
717
725
#define PA_SINK_FLAT_VOLUME PA_SINK_FLAT_VOLUME
 
726
#define PA_SINK_DYNAMIC_LATENCY PA_SINK_DYNAMIC_LATENCY
718
727
/** \endcond */
719
728
 
720
729
/** Sink state. \since 0.9.15 */
780
789
    PA_SOURCE_HW_MUTE_CTRL = 0x0010U,
781
790
    /**< Supports hardware mute control \since 0.9.11 */
782
791
 
783
 
    PA_SOURCE_DECIBEL_VOLUME = 0x0020U
 
792
    PA_SOURCE_DECIBEL_VOLUME = 0x0020U,
784
793
    /**< Volume can be translated to dB with pa_sw_volume_to_dB()
785
794
     * \since 0.9.11 */
 
795
 
 
796
    PA_SOURCE_DYNAMIC_LATENCY = 0x0040U
 
797
    /**< The latency can be adjusted dynamically depending on the
 
798
     * needs of the connected streams. \since 0.9.15 */
786
799
} pa_source_flags_t;
787
800
 
788
801
/** \cond fulldocs */
792
805
#define PA_SOURCE_NETWORK PA_SOURCE_NETWORK
793
806
#define PA_SOURCE_HW_MUTE_CTRL PA_SOURCE_HW_MUTE_CTRL
794
807
#define PA_SOURCE_DECIBEL_VOLUME PA_SOURCE_DECIBEL_VOLUME
 
808
#define PA_SOURCE_DYNAMIC_LATENCY PA_SOURCE_DYNAMIC_LATENCY
795
809
/** \endcond */
796
810
 
797
811
/** Source state. \since 0.9.15 */