summaryrefslogtreecommitdiffstats
path: root/src/pulse/def.h
diff options
context:
space:
mode:
authorJyri Sarha <jyri.sarha@nokia.com>2010-10-15 13:05:14 +0300
committerColin Guthrie <cguthrie@mandriva.org>2010-10-16 11:53:38 +0100
commit5391daf8dfcae45c6abb74c0a5ff9b7c50e3c000 (patch)
tree15c43282a7b2be2d4fc2a73b251d5ec90926236c /src/pulse/def.h
parent179b291b18b9a7366955948ce0ddfb2e65a6b66e (diff)
core: Add infrastructure for synchronizing HW and SW volume changes
To make concurrent use of SW and HW volume glitchles their application needs to be synchronized. For accurate synchronization the HW volume needs to be applied in IO thread. This patch adds infrastructure to delay the applying of HW volume to match with SW volume timing. To avoid synchronization problems this patch moves many of the volume and mute related functions from main thread to IO thread. All these changes become active only if the sync volume flag for a sink has been set. So, for this patch to have any effect it needs to be taken into use by sink implementor. Signed-off-by: Jyri Sarha <jyri.sarha@nokia.com> Reviewed-by: Tanu Kaskinen <tanu.kaskinen@digia.com> Reviewd-by: Colin Guthrie <cguthrie@mandriva.org>
Diffstat (limited to 'src/pulse/def.h')
-rw-r--r--src/pulse/def.h7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/pulse/def.h b/src/pulse/def.h
index 80d2a508..a73e93e0 100644
--- a/src/pulse/def.h
+++ b/src/pulse/def.h
@@ -740,11 +740,15 @@ typedef enum pa_sink_flags {
/**< The latency can be adjusted dynamically depending on the
* needs of the connected streams. \since 0.9.15 */
- PA_SINK_PASSTHROUGH = 0x0100U
+ PA_SINK_PASSTHROUGH = 0x0100U,
/**< This sink has support for passthrough mode. The data will be left
* as is and not reformatted, resampled, mixed.
* \since 0.9.22*/
+ PA_SINK_SYNC_VOLUME = 0x0200U,
+ /**< The HW volume changes are syncronized with SW volume.
+ * \since 0.9.22 */
+
} pa_sink_flags_t;
/** \cond fulldocs */
@@ -757,6 +761,7 @@ typedef enum pa_sink_flags {
#define PA_SINK_FLAT_VOLUME PA_SINK_FLAT_VOLUME
#define PA_SINK_DYNAMIC_LATENCY PA_SINK_DYNAMIC_LATENCY
#define PA_SINK_PASSTHROUGH PA_SINK_PASSTHROUGH
+#define PA_SINK_SYNC_VOLUME PA_SINK_SYNC_VOLUME
/** \endcond */